From 50092ec9fdaf32115fb9c17a8a4afd2fe32086aa Mon Sep 17 00:00:00 2001
From: Jonathan Cornaz <jonathan.cornaz@gmail.com>
Date: Fri, 1 Nov 2024 11:51:48 +0100
Subject: [PATCH] relax dependency constraints

---
 .github/workflows/check.yml |  11 +--
 .gitignore                  |   1 -
 Cargo.lock                  | 165 ++++++++++++++++++++++++++++++++++++
 Cargo.toml                  |   6 +-
 justfile                    |  26 +-----
 5 files changed, 178 insertions(+), 31 deletions(-)
 create mode 100644 Cargo.lock

diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml
index 7219839..0608ca6 100644
--- a/.github/workflows/check.yml
+++ b/.github/workflows/check.yml
@@ -18,14 +18,11 @@ jobs:
       - uses: Swatinem/rust-cache@v2
       - uses: taiki-e/install-action@v2
         with:
-          tool: cargo-hack@0.6,just@1,cargo-msrv@0.15,cargo-deny@0.14
+          tool: cargo-hack@0.6,just@1,cargo-msrv@0.16,cargo-deny@0.16
       - run: just verify
   lint:
     runs-on: ubuntu-latest
     timeout-minutes: 10
-    env:
-      RUSTFLAGS: "-D warnings"
-      RUSTDOCFLAGS: "-D warnings"
     steps:
       - uses: actions/checkout@v4
       - uses: dtolnay/rust-toolchain@stable
@@ -35,5 +32,9 @@ jobs:
       - uses: taiki-e/install-action@v2
         with:
           tool: cargo-hack,just,cargo-deny
-      - run: just lint doc
+      - run: cargo update
+      - run: just test lint doc
+        env:
+          RUSTFLAGS: "-D warnings"
+          RUSTDOCFLAGS: "-D warnings"
       - run: cargo deny check
diff --git a/.gitignore b/.gitignore
index 4c33504..abdc56d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,7 +1,6 @@
 # Rust
 /target
 /.cargo/*.toml
-/Cargo.lock
 
 # Nodes tools
 /node_modules
diff --git a/Cargo.lock b/Cargo.lock
new file mode 100644
index 0000000..e68ca79
--- /dev/null
+++ b/Cargo.lock
@@ -0,0 +1,165 @@
+# This file is automatically @generated by Cargo.
+# It is not intended for manual editing.
+version = 3
+
+[[package]]
+name = "aho-corasick"
+version = "1.1.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916"
+dependencies = [
+ "memchr",
+]
+
+[[package]]
+name = "cfg-if"
+version = "1.0.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"
+
+[[package]]
+name = "fun-html"
+version = "0.0.0"
+dependencies = [
+ "html-escape",
+ "rstest",
+]
+
+[[package]]
+name = "glob"
+version = "0.3.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b"
+
+[[package]]
+name = "html-escape"
+version = "0.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "91053e52cecbe9eda96beef183addccac11a25dcd1cb7362be3e1d27496c1bed"
+dependencies = [
+ "utf8-width",
+]
+
+[[package]]
+name = "memchr"
+version = "2.7.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3"
+
+[[package]]
+name = "proc-macro2"
+version = "1.0.89"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "f139b0662de085916d1fb67d2b4169d1addddda1919e696f3252b740b629986e"
+dependencies = [
+ "unicode-ident",
+]
+
+[[package]]
+name = "quote"
+version = "1.0.37"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b5b9d34b8991d19d98081b46eacdd8eb58c6f2b201139f7c5f643cc155a633af"
+dependencies = [
+ "proc-macro2",
+]
+
+[[package]]
+name = "regex"
+version = "1.11.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b544ef1b4eac5dc2db33ea63606ae9ffcfac26c1416a2806ae0bf5f56b201191"
+dependencies = [
+ "aho-corasick",
+ "memchr",
+ "regex-automata",
+ "regex-syntax",
+]
+
+[[package]]
+name = "regex-automata"
+version = "0.4.8"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "368758f23274712b504848e9d5a6f010445cc8b87a7cdb4d7cbee666c1288da3"
+dependencies = [
+ "aho-corasick",
+ "memchr",
+ "regex-syntax",
+]
+
+[[package]]
+name = "regex-syntax"
+version = "0.8.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c"
+
+[[package]]
+name = "relative-path"
+version = "1.9.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ba39f3699c378cd8970968dcbff9c43159ea4cfbd88d43c00b22f2ef10a435d2"
+
+[[package]]
+name = "rstest"
+version = "0.23.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0a2c585be59b6b5dd66a9d2084aa1d8bd52fbdb806eafdeffb52791147862035"
+dependencies = [
+ "rstest_macros",
+ "rustc_version",
+]
+
+[[package]]
+name = "rstest_macros"
+version = "0.23.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "825ea780781b15345a146be27eaefb05085e337e869bff01b4306a4fd4a9ad5a"
+dependencies = [
+ "cfg-if",
+ "glob",
+ "proc-macro2",
+ "quote",
+ "regex",
+ "relative-path",
+ "rustc_version",
+ "syn",
+ "unicode-ident",
+]
+
+[[package]]
+name = "rustc_version"
+version = "0.4.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92"
+dependencies = [
+ "semver",
+]
+
+[[package]]
+name = "semver"
+version = "1.0.23"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b"
+
+[[package]]
+name = "syn"
+version = "2.0.86"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e89275301d38033efb81a6e60e3497e734dfcc62571f2854bf4b16690398824c"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "unicode-ident",
+]
+
+[[package]]
+name = "unicode-ident"
+version = "1.0.13"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e91b56cd4cadaeb79bbf1a5645f6b4f8dc5bde8834ad5894a8db35fda9efa1fe"
+
+[[package]]
+name = "utf8-width"
+version = "0.1.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1da899495cceb4e2300e6c16aa3fc345cf75fb2dd647fb0ed8de416d395c4247"
diff --git a/Cargo.toml b/Cargo.toml
index 8c41e35..748aa34 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -3,7 +3,7 @@ name = "fun-html"
 version = "0.0.0"
 authors = ["Jonathan Cornaz"]
 edition = "2021"
-rust-version = "1.60.0"
+rust-version = "1.60"
 repository = "https://github.com/jcornaz/fun-html"
 description = "HTML as a rust function!"
 publish = false
@@ -13,7 +13,7 @@ all-features = true
 rustdoc-args = ["--cfg", "docsrs"]
 
 [dependencies]
-html-escape = { version = "0.2.13", default-features = false }
+html-escape = { version = "0.2", default-features = false }
 
 [dev-dependencies]
-rstest = { version = "0.23.0", default-features = false }
+rstest = { version = "0.23", default-features = false }
diff --git a/justfile b/justfile
index 3f8aa65..ebdd6b2 100644
--- a/justfile
+++ b/justfile
@@ -10,14 +10,14 @@ watch:
 
 # Run the tests
 test:
-	cargo hack test --tests --feature-powerset 
-	cargo test --examples --all-features
-	cargo test --doc --all-features
+	cargo hack test --tests --feature-powerset --locked
+	cargo test --examples --all-features --locked
+	cargo test --doc --all-features --locked
 
 # Run the static code analysis
 lint:
 	cargo fmt -- --check
-	cargo hack clippy --each-feature --all-targets
+	cargo hack clippy --each-feature --all-targets --locked
 
 # Build the documentation
 doc *args:
@@ -30,24 +30,6 @@ doc-open: (doc "--open")
 check-msrv:
 	cargo msrv verify
 
-# Clean up compilation output
-clean:
-	rm -rf target
-	rm -f Cargo.lock
-	rm -rf node_modules
-
-# Install cargo dev-tools used by the `verify` recipe (requires rustup to be already installed)
-install-dev-tools:
-	rustup install stable
-	rustup override set stable
-	cargo install cargo-hack cargo-watch cargo-msrv
-
-# Install a git hook to run tests before every commits
-install-git-hooks:
-	echo '#!/usr/bin/env sh' > .git/hooks/pre-push
-	echo 'just verify' >> .git/hooks/pre-push
-	chmod +x .git/hooks/pre-push
-
 release *args: verify
     test $GITHUB_TOKEN
     test $CARGO_REGISTRY_TOKEN