Skip to content

Commit

Permalink
chore: upgrade edition to 2021
Browse files Browse the repository at this point in the history
  • Loading branch information
ana committed Oct 29, 2021
1 parent 5e52712 commit 359f81d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name = "rustlings"
version = "4.6.0"
authors = ["anastasie <ana@ana.st>", "Carol (Nichols || Goulding) <carol.nichols@gmail.com>"]
edition = "2018"
edition = "2021"

[dependencies]
argh = "0.1.4"
Expand Down

4 comments on commit 359f81d

@sumit4iit
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems to have broken integration with the replit, I see following error

 [ -x ~/.cargo/bin/rustlings ] && ~/.cargo/bin/rustlings watch || ./install.sh
Let's get you set up with Rustlings!
Checking requirements...
SUCCESS: Git is installed
SUCCESS: Rust is installed
SUCCESS: Cargo is installed
SUCCESS: Rust is up to date
Cloning Rustlings at rustlings/...
fatal: destination path 'rustlings' already exists and is not an empty directory.
Checking out version tags/4.6.0...
Installing the 'rustlings' executable...
error: failed to parse manifest at `/home/runner/rustlings/Cargo.toml`

Caused by:
  failed to parse the `edition` key

Caused by:
  supported edition values are `2015` or `2018`, but `2021` is unknown
WARNING: Please check that you have '/home/runner/.cargo/bin' in your PATH environment variable!
./install.sh: line 140: rustup: command not found
Installing the 'cargo-clippy' executable...
./install.sh: line 144: rustup: command not found
All done! Run 'rustlings' to get started.

@shadows-withal
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why would it do this when it's checking out 4.6.0, where the edition is still 2018... 🤔 For now, you can manually check out 4.6.0 and run cargo install --path .

@sumit4iit
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand rust, but did we intend to increase the version-number? to other than version = "4.6.0"

name = "rustlings"
version = "4.6.0"
authors = ["anastasie <ana@ana.st>", "Carol (Nichols || Goulding) <carol.nichols@gmail.com>"]
edition = "2021"

@shadows-withal
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's supposed to check out a git tag which is locked to a commit about 2 months ago, where the edition was still set to 2018. The version only serves a semantic purpose.

Please sign in to comment.