Compare commits

...

58 Commits

Author SHA1 Message Date
f4895d8c3b Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-03 09:07:14 +02:00
0d9be14496 Downgrade yanked tracing 0.1.38 to 0.1.37
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-03 09:06:00 +02:00
ef769c9d5a Merge pull request #608 from vbrandl/dependabot/cargo/vergen-8.1.3
chore(deps): Bump vergen from 8.1.1 to 8.1.3
2023-04-28 18:18:08 +02:00
bcf21906c8 Update changelog 2023-04-28 18:10:29 +02:00
abe637f878 chore(deps): Bump vergen from 8.1.1 to 8.1.3
Bumps [vergen](https://github.com/rustyhorde/vergen) from 8.1.1 to 8.1.3.
- [Release notes](https://github.com/rustyhorde/vergen/releases)
- [Commits](https://github.com/rustyhorde/vergen/compare/8.1.1...8.1.3)

---
updated-dependencies:
- dependency-name: vergen
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-28 16:09:20 +00:00
bcc9d77622 Merge pull request #607 from vbrandl/dependabot/cargo/tracing-0.1.38
chore(deps): Bump tracing from 0.1.37 to 0.1.38
2023-04-28 18:08:33 +02:00
ac88f591b0 Update changelog 2023-04-28 18:02:29 +02:00
38cf6cbf6b chore(deps): Bump tracing from 0.1.37 to 0.1.38
Bumps [tracing](https://github.com/tokio-rs/tracing) from 0.1.37 to 0.1.38.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-0.1.37...tracing-0.1.38)

---
updated-dependencies:
- dependency-name: tracing
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-28 16:00:19 +00:00
1b06818a66 Merge pull request #605 from vbrandl/dependabot/cargo/tokio-1.28.0
chore(deps): Bump tokio from 1.27.0 to 1.28.0
2023-04-28 17:59:36 +02:00
7de5a420d2 Update changelog 2023-04-28 17:54:34 +02:00
b546ee6682 chore(deps): Bump tokio from 1.27.0 to 1.28.0
Bumps [tokio](https://github.com/tokio-rs/tokio) from 1.27.0 to 1.28.0.
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.27.0...tokio-1.28.0)

---
updated-dependencies:
- dependency-name: tokio
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-28 15:53:00 +00:00
19fb89b5a2 Merge pull request #604 from vbrandl/dependabot/cargo/tracing-subscriber-0.3.17
chore(deps): Bump tracing-subscriber from 0.3.16 to 0.3.17
2023-04-28 17:52:23 +02:00
90bb04386e Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-27 11:23:54 +02:00
eb35e745de chore(deps): Bump tracing-subscriber from 0.3.16 to 0.3.17
Bumps [tracing-subscriber](https://github.com/tokio-rs/tracing) from 0.3.16 to 0.3.17.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-subscriber-0.3.16...tracing-subscriber-0.3.17)

---
updated-dependencies:
- dependency-name: tracing-subscriber
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-24 05:01:10 +00:00
41ecaa8ac9 Merge pull request #603 from vbrandl/dependabot/cargo/git2-0.17.1
Some checks failed
continuous-integration/drone/push Build is passing
Security audit / security_audit (push) Failing after 39s
/ Test Suite (ubuntu-latest) (push) Failing after 4s
/ Clippy (push) Failing after 39s
/ Rustfmt (push) Successful in 36s
chore(deps): Bump git2 from 0.17.0 to 0.17.1
2023-04-17 09:17:12 +02:00
6f23f4c13d Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-17 09:12:13 +02:00
f1640fdc36 chore(deps): Bump git2 from 0.17.0 to 0.17.1
Bumps [git2](https://github.com/rust-lang/git2-rs) from 0.17.0 to 0.17.1.
- [Release notes](https://github.com/rust-lang/git2-rs/releases)
- [Changelog](https://github.com/rust-lang/git2-rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/git2-rs/compare/git2-curl-0.17.0...0.17.1)

---
updated-dependencies:
- dependency-name: git2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-17 05:00:31 +00:00
3f6fb6bac9 Merge pull request #602 from vbrandl/dependabot/cargo/git2-0.17.0
All checks were successful
continuous-integration/drone/push Build is passing
chore(deps): Bump git2 from 0.16.1 to 0.17.0
2023-04-14 12:53:39 +02:00
3b51b2c7df Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-14 12:48:39 +02:00
d0ce2c7f89 chore(deps): Bump git2 from 0.16.1 to 0.17.0
Bumps [git2](https://github.com/rust-lang/git2-rs) from 0.16.1 to 0.17.0.
- [Release notes](https://github.com/rust-lang/git2-rs/releases)
- [Changelog](https://github.com/rust-lang/git2-rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/git2-rs/compare/0.16.1...git2-curl-0.17.0)

---
updated-dependencies:
- dependency-name: git2
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-14 04:59:18 +00:00
b14e6cbf71 Merge pull request #601 from vbrandl/revert-600-feature/version-from-git-describe
All checks were successful
continuous-integration/drone/push Build is passing
Revert "Use version from git-describe to better identify builds"
2023-04-14 00:51:17 +02:00
a9b7368847 Revert "Use version from git-describe to better identify builds" 2023-04-14 00:50:35 +02:00
b3cc22af6c Merge pull request #600 from vbrandl/feature/version-from-git-describe
All checks were successful
continuous-integration/drone/push Build is passing
Use version from git-describe to better identify builds
2023-04-14 00:43:13 +02:00
037e520beb Use version from git-describe to better identify builds
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-14 00:39:47 +02:00
119dcd4cff Merge pull request #599 from vbrandl/dependabot/cargo/h2-0.3.17
chore(deps): Bump h2 from 0.3.16 to 0.3.17
2023-04-14 00:33:37 +02:00
081ca836bc Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-14 00:30:11 +02:00
62114219e2 Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-14 00:26:53 +02:00
38b86aa490 chore(deps): Bump h2 from 0.3.16 to 0.3.17
Bumps [h2](https://github.com/hyperium/h2) from 0.3.16 to 0.3.17.
- [Release notes](https://github.com/hyperium/h2/releases)
- [Changelog](https://github.com/hyperium/h2/blob/master/CHANGELOG.md)
- [Commits](https://github.com/hyperium/h2/compare/v0.3.16...v0.3.17)

---
updated-dependencies:
- dependency-name: h2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-13 17:09:49 +00:00
88eab864b1 Merge pull request #598 from vbrandl/fix/docker-build
All checks were successful
continuous-integration/drone/push Build is passing
Fix docker build with moved `build.rs` script
2023-04-13 13:09:08 +02:00
864cbe1c73 Fix docker build with moved build.rs script
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-13 13:06:31 +02:00
ced16e2e6b Merge pull request #597 from vbrandl/release/v0.34.0
Some checks failed
continuous-integration/drone/push Build is failing
Release v0.34.0
2023-04-13 12:44:30 +02:00
834085df92 Bump version
Some checks failed
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is failing
2023-04-13 12:19:38 +02:00
fd3746e781 Merge pull request #592 from vbrandl/dependabot/cargo/vergen-8.1.1
chore(deps): Bump vergen from 7.5.1 to 8.1.1
2023-04-13 12:08:51 +02:00
45b45eebc2 Apply cargo fmt
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-13 11:56:41 +02:00
914ee4b637 Update to vergen 8
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-13 11:55:52 +02:00
e57294ff4c chore(deps): Bump vergen from 7.5.1 to 8.1.1
Bumps [vergen](https://github.com/rustyhorde/vergen) from 7.5.1 to 8.1.1.
- [Release notes](https://github.com/rustyhorde/vergen/releases)
- [Commits](https://github.com/rustyhorde/vergen/compare/7.5.1...8.1.1)

---
updated-dependencies:
- dependency-name: vergen
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-13 09:47:29 +00:00
7129c8f9c4 Merge pull request #590 from vbrandl/dependabot/cargo/tempfile-3.5.0
chore(deps): Bump tempfile from 3.4.0 to 3.5.0
2023-04-13 11:46:53 +02:00
80235319b8 Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-13 11:39:25 +02:00
68b31cbcdb chore(deps): Bump tempfile from 3.4.0 to 3.5.0
Bumps [tempfile](https://github.com/Stebalien/tempfile) from 3.4.0 to 3.5.0.
- [Release notes](https://github.com/Stebalien/tempfile/releases)
- [Changelog](https://github.com/Stebalien/tempfile/blob/master/NEWS)
- [Commits](https://github.com/Stebalien/tempfile/commits)

---
updated-dependencies:
- dependency-name: tempfile
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-13 09:37:12 +00:00
1fabfdc27c Merge pull request #588 from vbrandl/dependabot/cargo/tokio-1.27.0
chore(deps): Bump tokio from 1.26.0 to 1.27.0
2023-04-13 11:36:35 +02:00
02c6a7ccc8 Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-13 11:23:19 +02:00
5652f46e2f chore(deps): Bump tokio from 1.26.0 to 1.27.0
Bumps [tokio](https://github.com/tokio-rs/tokio) from 1.26.0 to 1.27.0.
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.26.0...tokio-1.27.0)

---
updated-dependencies:
- dependency-name: tokio
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-13 09:21:30 +00:00
140074171b Merge pull request #586 from vbrandl/dependabot/cargo/reqwest-0.11.16
chore(deps): Bump reqwest from 0.11.14 to 0.11.16
2023-04-13 11:20:54 +02:00
519925762a Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-13 11:17:17 +02:00
e669499a6f chore(deps): Bump reqwest from 0.11.14 to 0.11.16
Bumps [reqwest](https://github.com/seanmonstar/reqwest) from 0.11.14 to 0.11.16.
- [Release notes](https://github.com/seanmonstar/reqwest/releases)
- [Changelog](https://github.com/seanmonstar/reqwest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/seanmonstar/reqwest/compare/v0.11.14...v0.11.16)

---
updated-dependencies:
- dependency-name: reqwest
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-13 09:14:26 +00:00
7ef2f8f87c Merge pull request #583 from vbrandl/dependabot/cargo/dotenvy-0.15.7
chore(deps): Bump dotenvy from 0.15.6 to 0.15.7
2023-04-13 11:13:48 +02:00
30ef5cf41f Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-13 11:07:24 +02:00
5c5b848177 chore(deps): Bump dotenvy from 0.15.6 to 0.15.7
Bumps [dotenvy](https://github.com/allan2/dotenvy) from 0.15.6 to 0.15.7.
- [Release notes](https://github.com/allan2/dotenvy/releases)
- [Changelog](https://github.com/allan2/dotenvy/blob/master/CHANGELOG.md)
- [Commits](https://github.com/allan2/dotenvy/compare/v0.15.6...v0.15.7)

---
updated-dependencies:
- dependency-name: dotenvy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-13 09:06:00 +00:00
ba72053fa1 Merge pull request #582 from vbrandl/dependabot/cargo/mime-0.3.17
chore(deps): Bump mime from 0.3.16 to 0.3.17
2023-04-13 11:05:11 +02:00
79c94f964f Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-13 10:50:05 +02:00
36c0b08067 chore(deps): Bump mime from 0.3.16 to 0.3.17
Bumps [mime](https://github.com/hyperium/mime) from 0.3.16 to 0.3.17.
- [Release notes](https://github.com/hyperium/mime/releases)
- [Commits](https://github.com/hyperium/mime/compare/v0.3.16...v0.3.17)

---
updated-dependencies:
- dependency-name: mime
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-21 05:02:57 +00:00
78383c291b Merge pull request #580 from vbrandl/dependabot/cargo/serde-1.0.158
All checks were successful
continuous-integration/drone/push Build is passing
chore(deps): Bump serde from 1.0.156 to 1.0.158
2023-03-20 15:15:11 +01:00
fe271c764e Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-20 13:21:11 +01:00
29f9765254 chore(deps): Bump serde from 1.0.156 to 1.0.158
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.156 to 1.0.158.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.156...v1.0.158)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-20 12:19:56 +00:00
70d21bd0db Merge pull request #578 from vbrandl/dependabot/cargo/tracing-actix-web-0.7.3
chore(deps): Bump tracing-actix-web from 0.7.2 to 0.7.3
2023-03-20 13:18:30 +01:00
fdd2883f3b Update changelog
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-20 13:10:46 +01:00
aff5ba2e0b chore(deps): Bump tracing-actix-web from 0.7.2 to 0.7.3
Bumps [tracing-actix-web](https://github.com/LukeMathWalker/tracing-actix-web) from 0.7.2 to 0.7.3.
- [Release notes](https://github.com/LukeMathWalker/tracing-actix-web/releases)
- [Commits](https://github.com/LukeMathWalker/tracing-actix-web/compare/v0.7.2...v0.7.3)

---
updated-dependencies:
- dependency-name: tracing-actix-web
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-20 05:01:41 +00:00
5b2d1e9016 Merge pull request #577 from vbrandl/release/v0.33.0
All checks were successful
continuous-integration/drone/push Build is passing
release/v0.33.0
2023-03-16 15:29:23 +01:00
7 changed files with 1275 additions and 575 deletions

View File

@ -5,6 +5,57 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased]
* Updated [`h2`](https://github.com/hyperium/h2) from 0.3.16 to 0.3.17, fixes [SEC#11] ([#599])
* Updated [`git2`](https://github.com/rust-lang/git2-rs) from 0.16.1 to 0.17.0 ([#602])
* Updated [`git2`](https://github.com/rust-lang/git2-rs) from 0.17.0 to 0.17.1 ([#603])
* Updated [`tracing-subscriber`](https://github.com/tokio-rs/tracing) from 0.3.16 to 0.3.17 ([#604])
* Updated [`tokio`](https://github.com/tokio-rs/tokio) from 1.27.0 to 1.28.0 ([#605])
* Updated [`tracing`](https://github.com/tokio-rs/tracing) from 0.1.37 to 0.1.38 ([#607])
* Updated [`vergen`](https://github.com/rustyhorde/vergen) from 8.1.1 to 8.1.3 ([#608])
* Downgrade yanked [`tracing`](https://github.com/tokio-rs/tracing) 0.1.38 to 0.1.37 ([#611])
[#599]: https://github.com/vbrandl/hoc/pull/599
[#602]: https://github.com/vbrandl/hoc/pull/602
[#603]: https://github.com/vbrandl/hoc/pull/603
[#604]: https://github.com/vbrandl/hoc/pull/604
[#605]: https://github.com/vbrandl/hoc/pull/605
[#607]: https://github.com/vbrandl/hoc/pull/607
[#608]: https://github.com/vbrandl/hoc/pull/608
[#611]: https://github.com/vbrandl/hoc/pull/611
[SEC#11]: https://github.com/vbrandl/hoc/security/dependabot/11
## [0.34.0] 2023-04-13
* Updated [`tracing-actix-web`](https://github.com/LukeMathWalker/tracing-actix-web) from 0.7.2 to 0.7.3 ([#578])
* Updated [`serde`](https://github.com/serde-rs/serde) from 1.0.156 to 1.0.158 ([#580])
* Updated [`mime`](https://github.com/hyperium/mime) from 0.3.16 to 0.3.17 ([#582])
* Updated [`dotenvy`](https://github.com/allan2/dotenvy) from 0.15.6 to 0.15.7 ([#583])
* Updated [`reqwest`](https://github.com/seanmonstar/reqwest) from 0.11.14 to 0.11.16 ([#586])
* Updated [`tokio`](https://github.com/tokio-rs/tokio) from 1.26.0 to 1.27.0 ([#588])
* Updated [`tempfile`](https://github.com/Stebalien/tempfile) from 3.4.0 to 3.5.0 ([#590])
* Updated [`tracing-bunyan-formatter`](https://github.com/LukeMathWalker/tracing-bunyan-formatter) from 0.3.6 to 0.3.7 ([#593])
* Updated [`serde`](https://github.com/serde-rs/serde) from 1.0.158 to 1.0.160 ([#594])
* Updated [`serde_json`](https://github.com/serde-rs/json) from 1.0.94 to 1.0.96 ([#595])
* Updated [`openssl`](https://github.com/sfackler/rust-openssl) from 0.10.40 to 0.10.50, fixes [SEC#6], [SEC#7], and [SEC#8] ([#596])
[#578]: https://github.com/vbrandl/hoc/pull/578
[#580]: https://github.com/vbrandl/hoc/pull/580
[#582]: https://github.com/vbrandl/hoc/pull/582
[#583]: https://github.com/vbrandl/hoc/pull/583
[#586]: https://github.com/vbrandl/hoc/pull/586
[#588]: https://github.com/vbrandl/hoc/pull/588
[#590]: https://github.com/vbrandl/hoc/pull/590
[#593]: https://github.com/vbrandl/hoc/pull/593
[#594]: https://github.com/vbrandl/hoc/pull/594
[#595]: https://github.com/vbrandl/hoc/pull/595
[#596]: https://github.com/vbrandl/hoc/pull/596
[SEC#6]: https://github.com/vbrandl/hoc/security/dependabot/6
[SEC#7]: https://github.com/vbrandl/hoc/security/dependabot/7
[SEC#8]: https://github.com/vbrandl/hoc/security/dependabot/8
## [0.33.0] 2023-03-16

1744
Cargo.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -1,9 +1,9 @@
[package]
name = "hoc"
version = "0.33.0"
version = "0.34.0"
authors = ["Valentin Brandl <vbrandl@riseup.net>"]
edition = "2021"
build = "build.rs"
build = "src/build.rs"
[lib]
path = "src/lib.rs"
@ -18,30 +18,31 @@ actix-web = "4.3.1"
badgers = "1.2.0"
bytes = "1.4.0"
config = { version = "0.13.3", features = ["toml"] }
dotenvy = "0.15.6"
dotenvy = "0.15.7"
futures = "0.3.27"
git2 = "0.16.1"
git2 = "0.17.1"
lazy_static = "1.4.0"
mime = "0.3"
number_prefix = "0.4.0"
openssl-probe = "0.1.5"
reqwest = "0.11.14"
serde = "1.0.156"
reqwest = "0.11.16"
serde = "1.0.158"
serde_derive = "1.0.137"
serde_json = "1.0.94"
tracing = "0.1.37"
tracing-actix-web = "0.7.2"
tracing-actix-web = "0.7.3"
tracing-bunyan-formatter = "0.3.6"
tracing-futures = "0.2.5"
tracing-log = "0.1.3"
tracing-subscriber = { version = "0.3.16", features = ["registry", "env-filter"] }
tracing-subscriber = { version = "0.3.17", features = ["registry", "env-filter"] }
[build-dependencies]
anyhow = "1.0.70"
ructe = { version = "0.16.1", features = ["mime03"] }
vergen = { version = "7.5.1", default-features = false, features = ["git"] }
vergen = { version = "8.1.3", default-features = false, features = ["git", "gitoxide"] }
[dev-dependencies]
awc = "3.1.1"
ructe = "0.16.1"
tempfile = "3.4.0"
tokio = "1.26.0"
tempfile = "3.5.0"
tokio = "1.28.0"

View File

@ -10,7 +10,7 @@ RUN echo 'fn main() { println!("Hello, world!"); }' >> src/main.rs
COPY ./Cargo.lock ./Cargo.lock
COPY ./Cargo.toml ./Cargo.toml
# HACK: remove build-dependencies so we have at least some caching
RUN head -n $(($(grep -n "\[build-dependencies\]" Cargo.toml | cut -f1 -d:) - 1)) Cargo.toml | sed '/build.rs/d' > \
RUN head -n $(($(grep -n "\[build-dependencies\]" Cargo.toml | cut -f1 -d:) - 1)) Cargo.toml | sed '/src\/build.rs/d' > \
Cargo.toml2 && rm Cargo.toml && mv Cargo.toml2 Cargo.toml
# build to cache dependencies
RUN cargo build --release
@ -24,7 +24,6 @@ COPY ./.git ./.git
# copy source code
COPY ./static ./static
COPY ./templates ./templates
COPY ./build.rs ./build.rs
COPY ./src ./src
# build source code
RUN cargo build --release

View File

@ -1,15 +0,0 @@
extern crate ructe;
extern crate vergen;
use ructe::{Ructe, RucteError};
use vergen::{vergen, Config, ShaKind};
fn main() -> Result<(), RucteError> {
let mut config = Config::default();
*config.git_mut().sha_kind_mut() = ShaKind::Short;
vergen(config).expect("Unable to generate static repo info");
let mut ructe = Ructe::from_env()?;
let mut statics = ructe.statics()?;
statics.add_files("static")?;
ructe.compile_templates("templates")
}

12
src/build.rs Normal file
View File

@ -0,0 +1,12 @@
use anyhow::Result;
use ructe::Ructe;
use vergen::EmitBuilder;
fn main() -> Result<()> {
EmitBuilder::builder().git_sha(true).emit()?;
let mut ructe = Ructe::from_env()?;
let mut statics = ructe.statics()?;
statics.add_files("static")?;
Ok(ructe.compile_templates("templates")?)
}

View File

@ -4,7 +4,7 @@ pub struct VersionInfo<'a> {
}
pub(crate) const VERSION_INFO: VersionInfo = VersionInfo {
commit: env!("VERGEN_GIT_SHA_SHORT"),
commit: env!("VERGEN_GIT_SHA"),
version: env!("CARGO_PKG_VERSION"),
};