Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
1006 commits
Select commit Hold shift + click to select a range
8fcad1f
Update windows-bindgen to 0.53
pitdicker Feb 26, 2024
b882f58
Simplify error value of `parse_internal`
pitdicker Feb 25, 2024
9efa85d
Return `IMPOSSIBLE` if year fields don't match
pitdicker Feb 8, 2024
a8908b4
Expand `Parsed` documentation
pitdicker Feb 8, 2024
e9e9adf
Improve documentation of `Parsed::set_*`
pitdicker Feb 14, 2024
48f0549
Return correct error in `Parsed::to_fixed_offset`
pitdicker Feb 26, 2024
85c70ff
Improve documentation of `Parset::to_*`
pitdicker Feb 6, 2024
0b68d19
Move `serde_from` and `SerdeError` to `crate::serde` inline module
pitdicker Feb 27, 2024
bbdc332
Simplify `SerdeError`
pitdicker Feb 24, 2024
a6c0c64
Check for invalid cast
pitdicker Feb 24, 2024
e292d9b
Simplify `from_isoywd` a bit
pitdicker Feb 26, 2024
dd20164
Use `overflowing_naive_local` in `checked_(add|sub)_months`
pitdicker Sep 28, 2023
06bd82c
Extend fast path in `NaiveDate::add_days`
pitdicker Sep 26, 2023
43675f1
Use `overflowing_naive_local` in `checked_(add|sub)_days`
pitdicker Sep 28, 2023
ca51f69
Make `with_year` return `Some` if it is a no-op
pitdicker Sep 28, 2023
774951f
Add `DateTime::{from_timestamp_micros, from_timestamp_nanos}`
pitdicker Feb 29, 2024
1c1feca
Use `UNIX_EPOCH` in `NaiveDateTime::default()`
pitdicker Feb 28, 2024
0c23fd4
Move implementation of `timestamp*` to `DateTime`
pitdicker Feb 28, 2024
27a1ee4
Move implementation of `from_timestamp*` to `DateTime`
pitdicker Feb 28, 2024
39f9a97
Translate timestamp tests to `DateTime`
pitdicker Feb 28, 2024
392e0dd
Don't use timestamp methods from `NaiveDateTime`
pitdicker Feb 29, 2024
585d48b
Don't use timestamp methods from `NaiveDateTime` in `serde` module
pitdicker Feb 29, 2024
83573a8
Deprecate timestamp methods on `NaiveDateTime`
pitdicker Feb 28, 2024
1d3da21
Add comment to calculate `UNIX_EPOCH_DAY`
pitdicker Feb 29, 2024
0aa46dd
Sync `Datelike` docs
pitdicker Mar 1, 2024
f4adc28
Update windows-bindgen requirement from 0.53 to 0.54
dependabot[bot] Mar 4, 2024
4072400
Add range checks to the `Parsed::set_*` methods
pitdicker Feb 19, 2024
ba4e50c
Add getters to `Parsed`
pitdicker Feb 6, 2024
90dbd75
Hide fields on `Parsed` in preparation of making them private with 0.5
pitdicker Feb 27, 2024
5caa640
Documentation fixes
pitdicker Feb 21, 2024
d7e5853
Use `checked_add_days` in `NaiveDateWeeksIterator`
pitdicker Feb 19, 2024
383fcff
Use simplified `resolve_week_date`
pitdicker May 27, 2023
073c3c3
Replace `TimeDelta::days` with `try_days`
pitdicker Feb 19, 2024
4251bd1
Replace `TimeDelta::seconds` with `try_seconds`
pitdicker Feb 19, 2024
51a1aa2
Tests: use `Days` type when it is more appropriate than `TimeDelta`
pitdicker Feb 19, 2024
e8f9b5e
Tests: replace `TimeDelta::weeks` with `try_weeks`
pitdicker Feb 19, 2024
9f23c08
Tests: replace `TimeDelta::days` with `try_days`
pitdicker Feb 19, 2024
9fc931a
Tests: replace `TimeDelta::hours` with `try_hours`
pitdicker Feb 20, 2024
f93508f
Tests: replace `TimeDelta::minutes` with `try_minutes`
pitdicker Feb 21, 2024
2bf3302
Tests: replace `TimeDelta::seconds` with `try_seconds`
pitdicker Feb 21, 2024
2c1b0be
Tests: replace `TimeDelta::milliseconds` with `try_milliseconds`
pitdicker Feb 22, 2024
9e667b6
Deprecate panicking `TimeDelta` constructors
pitdicker Feb 19, 2024
9fdb596
Prepare 0.4.35
pitdicker Mar 6, 2024
2d2f1a9
Correct timestamp deprecation notes
pitdicker Mar 6, 2024
3114597
CI: Lint benchmarks
pitdicker Mar 6, 2024
e79fe21
Remove unnessary Copy and Send impls
erickt Mar 7, 2024
bcb5386
Remove duplicate test
djc Mar 7, 2024
d40417f
Improve error checking in `naive_date_time_from_system_time`
pitdicker Feb 26, 2024
db1c8ef
Guard against integer overflow in `TzInfo::for_year`
pitdicker Feb 27, 2024
4ac0615
Streamline `test_date_(add/sub)_days`
Zomtir Mar 8, 2024
50c0e6b
Streamline `test_date_signed_duration_since`
Zomtir Mar 9, 2024
c1cb936
Streamline `test_date_checked_add_signed`
Zomtir Mar 9, 2024
1aabe84
Update windows-bindgen to 0.55
pitdicker Mar 11, 2024
2486833
Avoid duplicate imports
pitdicker Mar 11, 2024
920e73b
chore: fix some typos
avoidalone Mar 11, 2024
9511dd2
Rename `LocalResult` to `MappedLocalTime`, add alias
pitdicker Mar 9, 2024
1789183
Extend documentation for `MappedLocalTime`
pitdicker Mar 9, 2024
236b7ad
Add `DateTime::with_time()`
pitdicker Mar 12, 2024
d91b7d4
Add extra assertions to `NaiveDate::from_yof`
pitdicker Mar 15, 2024
c21b359
Turn `expect` macro into a function
pitdicker Mar 18, 2024
04eb6d3
Slightly improve serde documentation
pitdicker Mar 15, 2024
9664494
Simplify `DateTime::date_naive`
pitdicker Mar 18, 2024
c370ef6
Simplify `NaiveDate::diff_months`
pitdicker Mar 20, 2024
28a46c9
Remove 'This can fail' documentation from `NaiveDateTime::and_local_t…
pitdicker Mar 20, 2024
18328a8
Replace `.and_local_timezone(Utc)` with `.and_utc()`
pitdicker Mar 18, 2024
61d54b5
Remove unnecessary "```ignore"
pitdicker Mar 21, 2024
6f2c7cc
Use different method to run feature-dependent doctests
pitdicker Mar 21, 2024
1b57859
Run doctests with `alloc` feature if possible
pitdicker Mar 21, 2024
1e8df65
Rustfmt doc comments
pitdicker Mar 21, 2024
3adfd88
Main documentation: simplify links and reflow text
pitdicker Mar 21, 2024
e05ba8b
Add `MappedLocalTime::and_then`
pitdicker Mar 21, 2024
1850198
Revert `TimeDelta` deprecations
pitdicker Mar 26, 2024
ca3c3b6
Prepare 0.4.36
pitdicker Mar 26, 2024
9e22e48
Swap `MappedLocalTime` and `LocalResult` type alias
pitdicker Mar 27, 2024
6857d00
Hide re-export of `LocalResult` in docs
pitdicker Mar 27, 2024
7d62045
Prepare 0.4.37
pitdicker Mar 27, 2024
6c86cd1
Remove rustc-serialize from library
workingjubilee Mar 30, 2024
be62a7f
Remove rustc-serialize feature
workingjubilee Mar 28, 2024
6c4e735
Justify not using --all-features with rkyv
workingjubilee Mar 30, 2024
cfe7b74
Merge `naive::date::test_*_json` into their tests
pitdicker Mar 30, 2024
cba4baa
Merge `naive::time::test_*_json` into their tests
pitdicker Mar 30, 2024
e9849ed
Merge `naive::datetime::test_*_json` into their tests
pitdicker Mar 30, 2024
ffe2745
Merge `datetime::test_*_json` into their tests
pitdicker Mar 30, 2024
a36a45a
Factor out `Numeric` formatting
pitdicker Oct 1, 2023
080d623
Factor out `Fixed` formatting
pitdicker Oct 1, 2023
5c1c87c
Pass date and time by value
pitdicker Oct 1, 2023
4947c90
Factor out `DelayedFormat::format`
pitdicker Oct 1, 2023
cc01399
Inline `format_inner`
pitdicker Oct 1, 2023
06a6b01
Make `format_numeric` a method
pitdicker Oct 1, 2023
fe43396
Make `format_fixed` a method
pitdicker Oct 1, 2023
0b9b160
CI: Skip oldtime, rkyv and wasmbind in `cargo hack check`
pitdicker Apr 4, 2024
8b1364f
CI: Treat some features as mutually exclusive in `cargo hack check`
pitdicker Apr 4, 2024
838b9dd
Only package files needed for building and testing
pitdicker Apr 4, 2024
7f57dde
Remove `appveyor.yml`
pitdicker Apr 4, 2024
6302158
Always have a `locale` field
pitdicker Oct 1, 2023
8df4ad2
Inline `weeks_from_*`
pitdicker Oct 1, 2023
f3d76c7
Match on tuples in `format_numeric`
pitdicker Oct 1, 2023
78e79db
Match on tuples in `format_fixed`
pitdicker Oct 1, 2023
74ba83b
Take `pad` by value
pitdicker Apr 6, 2024
0cfc405
Optimize number formatting
pitdicker Jul 1, 2023
f8cecbe
Make `Weekday::num_days_from public`, rename to `days_since`.
Jan 29, 2018
ffc75e5
Add `TimeDelta::checked_mul` and `TimeDelta::checked_div`
Zomtir Apr 8, 2024
391187f
Return error when rounding with zero duration
Dav1dde Apr 9, 2024
760eb66
Update windows-bindgen requirement from 0.55 to 0.56
dependabot[bot] Apr 15, 2024
46d44d6
Manually implement `Copy` for `DateTime` if offset is `Copy`
pitdicker Apr 15, 2024
352a352
Prepare 0.4.38
pitdicker Apr 15, 2024
7e25ffb
#1577: Changed years_since documentation to match its implementation
Taxalo Apr 29, 2024
ce38386
Remove obsolete weird feature guard
djc May 23, 2024
0a058ea
Fix format::strftime docs link
frederikhors May 20, 2024
f129a8b
Update mod.rs
frederikhors May 20, 2024
865b0ad
Fix micros (optional) limit in and_hms_micro_opt
qrilka May 30, 2024
2085627
Update windows-bindgen requirement from 0.56 to 0.57
dependabot[bot] Jun 10, 2024
de2f1f4
native/date: Improve DelayedFormat doc re Panics
Jun 10, 2024
51c2d4b
Fix typo in rustdoc of from_timestamp_nanos()
sgoll Jun 12, 2024
e6f5d51
Apply clippy suggestions from Rust 1.79
djc Jul 8, 2024
2cec1d3
Add TimeDelta::{MIN, MAX} const values
djc Jul 8, 2024
4401f39
Use environment secrets for Codecov token
djc Jul 8, 2024
c46b18d
Update windows-bindgen requirement from 0.57 to 0.58
dependabot[bot] Jul 8, 2024
1eb3174
docs: document century cutoff for %y
MarcoGorelli Jul 16, 2024
b18c1c1
Fix line continuation in Parsed::to_datetime()
djc Jul 25, 2024
fb9eebc
benches: add feature unstable-locales
djc Jul 25, 2024
50938ab
deny: update config for 0.16
djc Aug 5, 2024
37ec019
Bump EmbarkStudios/cargo-deny-action from 1 to 2
dependabot[bot] Aug 5, 2024
68afd5b
Add `checked_first_day`
bragov4ik Jul 22, 2024
ccb04bc
Add `checked_last_day`
bragov4ik Jul 22, 2024
f765936
Add `checked_days`
bragov4ik Aug 8, 2024
081c648
Test that `NaiveWeek` checked functions don't panic
bragov4ik Jul 22, 2024
c8defc7
impl serde::Serialize and serde::Deserialize for TimeDelta (#1599)
Awpteamoose Sep 16, 2024
05a6ce6
Derive `PartialEq`,`Eq`,`Hash`,`Copy` and `Clone` on `NaiveWeek`
DSeeLP Sep 30, 2024
d8a177e
Support ohos tzdata since oh35
MirageLyu Sep 12, 2024
771c047
Use Formatter::pad (instead of write_str) for Weekdays
horazont Oct 14, 2024
77d50b1
Fix typos
szepeviktor Oct 20, 2024
7974c60
Fix comment.
khuey Oct 24, 2024
f9ffd6f
add `#[inline]` to `num_days`
CommanderStorm Nov 9, 2024
1c7567b
Bump codecov/codecov-action from 4 to 5
dependabot[bot] Nov 18, 2024
1456fa0
Apply suggestions from clippy 1.83
djc Nov 29, 2024
ca8232f
Update licenses for unicode-ident 1.0.14
djc Nov 29, 2024
65c47f3
Update CHANGELOG.md
futreall Nov 29, 2024
33aaebf
Update mod.rs
Noisyxl Dec 5, 2024
8b86349
Bump version to 0.4.39
djc Dec 3, 2024
07a42f9
Add Month::num_days()
djc Jan 6, 2025
97f758f
Update Windows dependencies
kennykerr Jan 7, 2025
12a814f
Add weekly scheduled CI runs
djc Jan 10, 2025
82bacb8
wasm32-wasi was renamed to wasm32-wasip1
djc Jan 10, 2025
5f2f5a8
Feature/round_up method on DurationRound trait (#1651)
MagnumTrader Jan 20, 2025
4c42ee5
Expose `write_to` for `DelayedFormat`
Jan 21, 2025
7cdca4b
Update LICENSE.txt
maximevtush Jan 29, 2025
8317e7c
docs: fix minor typo
samfolo Feb 15, 2025
15e287b
Use NaiveDateTime for internal tz_info methods. (#1658)
AVee Feb 18, 2025
11d227a
Apply suggestions from clippy 1.85
djc Feb 21, 2025
7f6cf5e
Switch to 2024 style
djc Feb 21, 2025
1f345fd
Switch to 2024 idiom
djc Feb 21, 2025
d0f8b59
Restrict MSRV to check --lib
djc Feb 24, 2025
bf1973c
Use similar-asserts to show bindgen diff
djc Feb 24, 2025
07216ae
Upgrade to windows-bindgen 0.60
djc Feb 24, 2025
6d29c8a
Add quarter (%q) date string specifier
drinkcat Feb 24, 2025
2b7a28e
Bump version to 0.4.40
djc Feb 26, 2025
f0f807d
Improve documentation for subsec_nanos() and add a test for the method.
ggoetz Feb 26, 2025
042109f
Add subsec_millis and subsec_micros methods for TimeDelta.
ggoetz Feb 26, 2025
2115206
Deprecate NaiveDateTime::UNIX_EPOCH
robertbastian Feb 27, 2025
cc6801d
Group subsec duration methods with their corresponding whole methods.
ggoetz Feb 28, 2025
fa957cc
Implement utility functions for converting TimeDelta to fractional se…
ggoetz Feb 28, 2025
7ebf64c
chore: fix some comments
jimmycathy Mar 16, 2025
39fb201
Add `num_days_in_month` method to `Datelike` trait
aslilac Mar 9, 2025
4f4e95b
add WeekdaySet - a collection of Weekday
Kinrany Mar 15, 2025
cac71f3
Rename weekdays module to weekday_set
djc Mar 23, 2025
cac4e8c
Move WeekdaySet constructors to the top
djc Mar 23, 2025
4094865
Remove Not impls for WeekdaySet and Weekday
djc Mar 23, 2025
64c65a9
Rename WeekdaySet::iter_from() to iter()
djc Mar 23, 2025
97d6c63
Privatize WeekdaySetIter fields
djc Mar 23, 2025
57567b3
Tweak WeekdaySet docs
djc Mar 23, 2025
265c79b
Tweak WeekdaySet method order
djc Mar 23, 2025
6a85301
Upgrade to windows-bindgen 0.61
djc Mar 24, 2025
104cdc7
Bump MSRV to 1.62
djc Apr 3, 2025
7c0bd13
Apply suggestions from clippy 1.86
djc Apr 3, 2025
b267a4f
Implemented consistent Hash and Eq trait for NaiveWeek
Splashling1789 Apr 4, 2025
dc068f0
Tweak style on NaiveWeek fixes
djc Apr 4, 2025
ebeef99
TimeZone::from_posix_tz: Treat empty TZ variable as UTC
drinkcat Apr 5, 2025
2c95b0a
Tweak expression to avoid repetition
djc Apr 9, 2025
e2bd1d1
Add support for lenient format strings (#1693)
Qelxiros Apr 11, 2025
d1de1d9
Bump version to 0.4.41
djc Apr 29, 2025
361b9fc
Add fuzzer for DateTime::parse_from_str
tyler92 Apr 29, 2025
c5c22a3
Fix wrong amount of micro/milliseconds
nmlt May 8, 2025
3b4af71
Add warning about MappedLocalTime and wasm
lutzky May 5, 2025
2e1cd2f
Fix incorrect parsing of fixed-length second fractions (#1705)
chris-leach Jun 3, 2025
1762c71
Fix cfgs for `wasm32-linux` support
arjunr2 Jun 4, 2025
bab9790
Upgrade to windows-bindgen 0.62
djc Jun 16, 2025
9245a8f
Apply suggestions from clippy 1.88
djc Jun 27, 2025
23c132f
Fix OpenHarmony's local timezone fetching and `tzdata` parsing
ldm0 Jul 8, 2025
68fd4b6
Fix typo in a comment
findepi Jul 18, 2025
d43108c
Convert NaiveDate to/from days since unix epoch
findepi Jul 18, 2025
b4b9aa5
Apply suggestions from clippy 1.89
djc Aug 8, 2025
59d5f46
Add `?Sized` bound to related methods of `DelayedFormat::write_to`
Huliiiiii Aug 12, 2025
6aeea3f
Add `from_timestamp_secs` method to `DateTime`
jasonaowen Aug 8, 2025
0f22fbd
Bump actions/checkout from 4 to 5
dependabot[bot] Aug 18, 2025
0813b2c
Bump actions/setup-node from 4 to 5
dependabot[bot] Sep 8, 2025
78c0fbc
Migrate to core::error::Error
benbrittain May 20, 2025
757a8b0
Upgrade to windows-bindgen 0.63
djc Sep 8, 2025
0ee2172
strftime: re-order items to keep impls together
djc Sep 8, 2025
d516c27
strftime: merge impl blocks
djc Sep 8, 2025
e5f6be7
strftime: move error() method below caller
djc Sep 8, 2025
9d5dfe1
strftime: outline constants
djc Sep 8, 2025
7f413c3
strftime: yield None early
djc Sep 8, 2025
36fbfb1
strftime: move specifier handling out of match to reduce rightward drift
djc Sep 8, 2025
a623170
strftime: simplify error handling
djc Sep 8, 2025
5cf5603
strftime: add regression test case
djc Sep 8, 2025
f3fd15f
Bump version to 0.4.42
djc Sep 8, 2025
0f01684
Install extra components for lint workflow
djc Sep 26, 2025
113777a
Upgrade windows-bindgen to 0.64
djc Sep 26, 2025
58f4667
Allow windows-bindgen codegen on any host target
djc Oct 1, 2025
09ab208
Inline bindings specification
djc Oct 1, 2025
0061d86
Drop stabilized feature doc_auto_cfg
djc Oct 1, 2025
728822e
test: a couple more tests for strict rfc3339 parsing
sby1ce Sep 27, 2025
e0dd9c5
refactor: scan::nanosecond to return u32
sby1ce Sep 27, 2025
ebc808e
feat: faster RFC 3339 parsing without Parsed
djc Oct 3, 2025
e632ffd
Update windows-bindgen requirement from 0.64 to 0.65
dependabot[bot] Oct 13, 2025
c34e4c5
add Datelike::days_between
Kinrany Oct 13, 2025
334565c
replace Datelike::days_between with NaiveDate::abs_diff
Kinrany Oct 13, 2025
35f9f2d
Add feature gated defmt support.
pebender Oct 2, 2025
ea1f11b
Drop deny lints, eager Debug impls are a mixed blessing
djc Oct 19, 2025
8c82711
Bump actions/setup-node from 5 to 6
dependabot[bot] Oct 20, 2025
34b5f49
chore: minor improvement for docs
spuradage Oct 22, 2025
db12973
Added doctest for the NaiveDate years_since function (#1755)
LucasBou Oct 26, 2025
f4b7bbd
Bump actions/checkout from 5 to 6
dependabot[bot] Nov 24, 2025
4fedaba
Ignore bincode advisory
djc Jan 9, 2026
a03e43b
Upgrade windows-bindgen to 0.66
djc Jan 9, 2026
1c0b8f0
Bump version to 0.4.43
djc Jan 9, 2026
45caaa9
Update copyright year to 2026 in LICENSE.txt
taozui472 Jan 13, 2026
f8900b5
docs: match MSRV with `Cargo.toml` contents
coryan Feb 8, 2026
cfae889
Fix panic message in to_rfc2822
svix-jplatte Feb 12, 2026
ea832c5
Add track_caller to non-deprecated functions
svix-jplatte Feb 12, 2026
c14b459
Bump version to 0.4.44
svix-jplatte Feb 13, 2026
120686c
Bump codecov/codecov-action from 5 to 6
dependabot[bot] Mar 30, 2026
c6063e6
Update similar-asserts requirement from 1.6.1 to 2.0.0
dependabot[bot] Apr 6, 2026
f14ead4
fix(tz): reject TZ offset hour of 24 to avoid FixedOffset overflow
SAY-5 May 24, 2026
881f9ab
tz_data: fix tzdata locations on Android
caruschalalamove Jun 4, 2026
1703382
Prepare 0.4.45 release
djc Jun 4, 2026
0cadfb4
Ignore advisory for proc-macro-error2
djc Jun 12, 2026
bf76cb9
ci: drop Taplo linting
djc Jun 12, 2026
2c8426a
Accept longer time zone designations and '_' in TZif files
W4HO-ham Jun 12, 2026
75926fc
fix(tz): avoid i64 overflow in find_local_time_type_from_local
nvxbug Jun 16, 2026
a71c212
fix(tz): avoid out-of-bounds slice on partial tzdata index entry
nvxbug Jun 17, 2026
bcfa377
Bump actions/checkout from 6 to 7
dependabot[bot] Jun 22, 2026
3ffcd1b
fix: clamp offset minute rounding to avoid invalid +24:00
nvxbug Jun 18, 2026
b04c42f
Replace `target_arch = "wasm32"` with `target_family = "wasm"`
SuchAFuriousDeath Jun 28, 2026
4537921
Apply suggestions from Clippy 1.97
djc Jul 10, 2026
6442832
Drop scheduled CI runs
djc Jul 10, 2026
7fa24ea
Bump actions/setup-node from 6 to 7
dependabot[bot] Jul 20, 2026
7b6436f
Fix reversed `NaiveDate` day and week iterators
n0liu Jul 29, 2026
6adaa52
Return None from from_isoywd_opt for out-of-range years
n0liu Aug 2, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
coverage:
status:
project:
default:
threshold: 1%
17 changes: 17 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
version: 2
updates:
- package-ecosystem: "cargo"
directory: "/"
schedule:
interval: "weekly"
target-branch: "main"
- package-ecosystem: "cargo"
directory: "/fuzz/"
schedule:
interval: "weekly"
target-branch: "main"
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
target-branch: "main"
8 changes: 3 additions & 5 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
### Thanks for contributing to chrono!

- [ ] Have you added yourself and the change to the [changelog]? (Don't worry
about adding the PR number)
- [ ] If this pull request fixes a bug, does it add a test that verifies that
we can't reintroduce it?
If your feature is semver-compatible, please target the main branch;
for semver-incompatible changes, please target the `0.5.x` branch.

[changelog]: ../CHANGELOG.md
Please consider adding a test to ensure your bug fix/feature will not break in the future.
36 changes: 36 additions & 0 deletions .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: codecov

env:
# It's really `--all-features`, but not adding the mutually exclusive features from rkyv
ALL_NON_EXCLUSIVE_FEATURES: --features "default unstable-locales rkyv-64 rkyv-validation serde arbitrary"

on:
push:
branches: [main, 0.5.x]
pull_request:
jobs:
# Run code coverage using cargo-llvm-cov then upload to codecov.io
job_code_coverage:
name: llvm-cov
runs-on: ubuntu-latest
environment: Coverage
env:
CARGO_TERM_COLOR: always
steps:
- uses: actions/checkout@v7
# nightly is required for --doctests, see cargo-llvm-cov#2
- uses: dtolnay/rust-toolchain@master
with:
toolchain: nightly
components: rustfmt
- name: Install cargo-llvm-cov
uses: taiki-e/install-action@cargo-llvm-cov
- name: Generate code coverage
run: cargo +nightly llvm-cov ${{ env.ALL_NON_EXCLUSIVE_FEATURES }} --workspace --lcov --doctests --output-path lcov.info
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v6
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
files: lcov.info
fail_ci_if_error: true
66 changes: 53 additions & 13 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -1,26 +1,66 @@
name: lint

env:
# It's really `--all-features`, but not adding the mutually exclusive features from rkyv
ALL_NON_EXCLUSIVE_FEATURES: --features "default unstable-locales rkyv-64 rkyv-validation serde arbitrary"

on:
push:
branches: [main, master]
branches: [main, 0.5.x]
pull_request:
branches: [main, master]

jobs:
lint:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Install rust
uses: actions-rs/toolchain@v1
- uses: actions/checkout@v7
- uses: dtolnay/rust-toolchain@stable
with:
targets: x86_64-unknown-linux-gnu, x86_64-pc-windows-msvc
components: clippy, rustfmt
- uses: Swatinem/rust-cache@v2
- run: cargo fmt --check -- --color=always
- run: cargo fmt --check --manifest-path fuzz/Cargo.toml
- run: cargo fmt --check --manifest-path bench/Cargo.toml
- run: |
cargo clippy ${{ env.ALL_NON_EXCLUSIVE_FEATURES }} --all-targets --color=always \
-- -D warnings
- run: |
cargo clippy --target=x86_64-pc-windows-msvc --all-targets --color=always \
-- -D warnings
- run: |
cargo clippy --manifest-path fuzz/Cargo.toml --all-targets --color=always \
-- -D warnings
- run: |
cargo clippy --manifest-path bench/Cargo.toml --all-targets --color=always \
-- -D warnings
env:
RUSTFLAGS: "-Dwarnings"

cargo-deny:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: EmbarkStudios/cargo-deny-action@v2

check-doc:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: dtolnay/rust-toolchain@stable
- run: cargo install cargo-deadlinks
- run: cargo deadlinks -- ${{ env.ALL_NON_EXCLUSIVE_FEATURES }}
- run: cargo doc ${{ env.ALL_NON_EXCLUSIVE_FEATURES }} --no-deps
env:
RUSTDOCFLAGS: -Dwarnings

cffconvert:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
with:
toolchain: stable
override: true
- uses: Swatinem/rust-cache@v1
- name: Lint
run: bash ci/lint.sh
- name: Run ShellCheck
uses: ludeeus/action-shellcheck@0.3.0
persist-credentials: false
- uses: citation-file-format/cffconvert-github-action@2.0.0
with:
check_together: 'y'
args: --validate
112 changes: 0 additions & 112 deletions .github/workflows/test-release.yml

This file was deleted.

Loading