foriequal0 / git-trim

Automatically trims your branches whose tracking remote refs are merged or stray
MIT License
490 stars 14 forks source link

replace toolchain.toml with rust-version in Cargo.toml #196

Closed Sherlock-Holo closed 1 year ago

Sherlock-Holo commented 1 year ago

https://github.com/rust-lang/cargo/issues/8072 has supported rust-version in Cargo.toml, replace the toolchain.toml should avoid downloading old version toolchain when user have a new version toolchain, but also limit the newer api usage

Sherlock-Holo commented 1 year ago

and the current stable version

rustc 1.65.0 (897e37553 2022-11-02)

can build the PR https://github.com/foriequal0/git-trim/pull/195, however the toolchain.toml version report failed

error[E0658]: trait bounds other than Sized on const fn parameters are unstable --> /home/sherlock/.cargo/registry/src/github.com-1ecc6299db9ec823/enum-iterator-1.1.3/src/lib.rs:82:26 82 pub const fn cardinality() -> usize { ^

= note: see issue #93706 https://github.com/rust-lang/rust/issues/93706 for more information

For more information about this error, try rustc --explain E0658. error: could not compile enum-iterator due to previous error warning: build failed, waiting for other jobs to finish... error: build failed

maybe git-trim can update the rust toolchain version to latest?