kegesch / gitmoji-cli

A gitmoji-cli written in rust to be independent of Node.js
MIT License
10 stars 1 forks source link

error[E0554]: `#![feature]` may not be used on the stable release channel #5

Open vhscom opened 2 years ago

vhscom commented 2 years ago

Ran cargo install gitmoji and got an error:

error[E0554]: `#![feature]` may not be used on the stable release channel
  --> /home/user/.cargo/registry/src/github.com-1ecc6299db9ec823/gitmoji-1.0.0/src/main.rs:21:12
   |
21 | #![feature(with_options)]
   |   

I don't want to run the Node one because I don't trust NPM where my command line is concerned.

vhscom commented 2 years ago

I read here the above error may be caused because I'm not building using rust nightly. After installing and rebuilding with rust nightly I saw the following error:

error[E0599]: no function or associated item named `with_options` found for struct `File` in the current scope
   --> /home/user/.cargo/registry/src/github.com-1ecc6299db9ec823/gitmoji-1.0.0/src/main.rs:253:11
    |
253 |     File::with_options().create(true).write(true).open(GITMOJI_CACHE.clone())?.write_all(emojis.dump().as_bytes())?;
    |           ^^^^^^^^^^^^ function or associated item not found in `File`

error[E0599]: no function or associated item named `with_options` found for struct `File` in the current scope
   --> /home/user/.cargo/registry/src/github.com-1ecc6299db9ec823/gitmoji-1.0.0/src/main.rs:260:11
    |
260 |     File::with_options().read(true).open(GITMOJI_CACHE.clone())?.read_to_string(&mut string)?;
    |           ^^^^^^^^^^^^ function or associated item not found in `File`

Should this software build without using rust nightly? The README seems to imply so.