use CARGO_MANIFEST_DIR instead of PWD
Some checks failed
continuous-integration/drone/push Build is passing
continuous-integration/drone/pr Build is failing

This commit is contained in:
shimun 2020-10-18 20:01:36 +02:00
parent be2639d9fe
commit 8e2948fbb9
Signed by: shimun
GPG Key ID: E81D8382DC2F971B

View File

@ -19,6 +19,10 @@ use structopt::StructOpt;
fn main() { fn main() {
// generate completion scripts, zsh does panic for some reason // generate completion scripts, zsh does panic for some reason
for shell in Shell::variants().iter().filter(|shell| **shell != "zsh") { for shell in Shell::variants().iter().filter(|shell| **shell != "zsh") {
Args::clap().gen_completions(env!("CARGO_PKG_NAME"), Shell::from_str(shell).unwrap(), "."); Args::clap().gen_completions(
env!("CARGO_PKG_NAME"),
Shell::from_str(shell).unwrap(),
env!("CARGO_MANIFEST_DIR"),
);
} }
} }