Oughie / clock-rs

clock-rs - A clock for your terminal!
Apache License 2.0
29 stars 1 forks source link

clock-rs doesn't run #4

Closed Victinijr closed 2 months ago

Victinijr commented 2 months ago

running arch with openbox on a surface pro 7. installed clock-rs but when i ran it, it said zsh: command not found: clock-rs.

Oughie commented 2 months ago

Have you installed clock-rs via $ cargo install clock-rs or did you compile the repository from source? If so, did you run $ cargo build --release which places the executable in the ./target/release) directory?

Victinijr commented 2 months ago

i installed via $ cargo install clock-rs

Oughie commented 2 months ago

Is the binary located inside the $HOME/.cargo/bin directory? If it's not, could you perhaps try compiling it by source? After you clone the repo, build it using $ cargo build --release and then run $ ./target/release/clock-rs

Victinijr commented 2 months ago

when i ran $ cargo build --release it gave an error saying error: could not find 'Cargo.toml' in 'home/<me>' or any other parent directory

Oughie commented 2 months ago

You need to first use the cd command to change into the cloned directory where the Cargo.toml file is located.

Victinijr commented 2 months ago

Is the binary located inside the $HOME/.cargo/bin directory? If it's not, could you perhaps try compiling it by source? After you clone the repo, build it using $ cargo build --release and then run $ ./target/release/clock-rs

the binary is in '$HOME/.cargo/bin' sorry i just noticed

Oughie commented 2 months ago

Is $HOME/.cargo/bin added to $PATH? Find out if it is by running echo $PATH or tr ':' '\n' <<< "$PATH" for an easy-to-read output.

Victinijr commented 2 months ago

No

Oughie commented 2 months ago

You should be able to do so by adding export PATH="$HOME/.cargo/bin:$PATH" to your .zshrc and then restarting your terminal.

Victinijr commented 2 months ago

You should be able to do so by adding export PATH="$HOME/.cargo/bin:$PATH" to your .zshrc and then restarting your terminal.

so i just run the command?

Edit: nvm it works thank you.

Oughie commented 2 months ago

Awesome :). Since the beginning, I'm still unsure whether you are trolling, since you use Arch and also have zero activity on your profile. But I'm glad this issue is resolved.