diff --git a/teller-cli/src/cli.rs b/teller-cli/src/cli.rs index 1c85f380..84bb49bc 100644 --- a/teller-cli/src/cli.rs +++ b/teller-cli/src/cli.rs @@ -183,7 +183,7 @@ pub struct NewArgs { } async fn load_teller(config: Option) -> eyre::Result { - let config_arg = config.unwrap_or_else(|| "teller.yml".to_string()); + let config_arg = config.unwrap_or_else(|| DEFAULT_FILE_PATH.to_string()); let config_path = Path::new(&config_arg); let teller = Teller::from_yaml(config_path).await?; Ok(teller) diff --git a/teller-cli/tests/cmd/copy.in/teller.yml b/teller-cli/tests/cmd/copy.in/.teller.yml similarity index 100% rename from teller-cli/tests/cmd/copy.in/teller.yml rename to teller-cli/tests/cmd/copy.in/.teller.yml diff --git a/teller-cli/tests/cmd/delete.in/teller.yml b/teller-cli/tests/cmd/delete.in/.teller.yml similarity index 100% rename from teller-cli/tests/cmd/delete.in/teller.yml rename to teller-cli/tests/cmd/delete.in/.teller.yml diff --git a/teller-cli/tests/cmd/export.in/teller.yml b/teller-cli/tests/cmd/export.in/.teller.yml similarity index 100% rename from teller-cli/tests/cmd/export.in/teller.yml rename to teller-cli/tests/cmd/export.in/.teller.yml diff --git a/teller-cli/tests/cmd/export.trycmd b/teller-cli/tests/cmd/export.trycmd index 6190e5b6..02e53d3c 100644 --- a/teller-cli/tests/cmd/export.trycmd +++ b/teller-cli/tests/cmd/export.trycmd @@ -1,29 +1,29 @@ ```console -$ teller -c teller.yml export yaml +$ teller export yaml FOO_BAR: foo FOO_BAZ: baz PRINT_MOOD: happy PRINT_NAME: linus -$ teller -c teller.yml export csv +$ teller export csv FOO_BAR,foo PRINT_NAME,linus FOO_BAZ,baz PRINT_MOOD,happy -$ teller -c teller.yml export json +$ teller export json {"FOO_BAR":"foo","FOO_BAZ":"baz","PRINT_MOOD":"happy","PRINT_NAME":"linus"} -$ teller -c teller.yml export env +$ teller export env FOO_BAR=foo PRINT_NAME=linus FOO_BAZ=baz PRINT_MOOD=happy -$ teller -c teller.yml sh +$ teller sh #!/bin/sh export FOO_BAR='foo' export PRINT_NAME='linus' @@ -31,7 +31,7 @@ export FOO_BAZ='baz' export PRINT_MOOD='happy' -$ teller -c teller.yml env +$ teller env FOO_BAR=foo PRINT_NAME=linus FOO_BAZ=baz diff --git a/teller-cli/tests/cmd/put.in/teller.yml b/teller-cli/tests/cmd/put.in/.teller.yml similarity index 100% rename from teller-cli/tests/cmd/put.in/teller.yml rename to teller-cli/tests/cmd/put.in/.teller.yml diff --git a/teller-cli/tests/cmd/run.in/teller.yml b/teller-cli/tests/cmd/run.in/.teller.yml similarity index 100% rename from teller-cli/tests/cmd/run.in/teller.yml rename to teller-cli/tests/cmd/run.in/.teller.yml diff --git a/teller-cli/tests/cmd/run.trycmd b/teller-cli/tests/cmd/run.trycmd index cbfabddb..26499184 100644 --- a/teller-cli/tests/cmd/run.trycmd +++ b/teller-cli/tests/cmd/run.trycmd @@ -1,5 +1,5 @@ ```console -$ teller -c teller.yml run --reset --shell -- node index.js +$ teller run --reset --shell -- node index.js hello from nodejs linus happy diff --git a/teller-cli/tests/cmd/scan.in/teller.yml b/teller-cli/tests/cmd/scan.in/.teller.yml similarity index 100% rename from teller-cli/tests/cmd/scan.in/teller.yml rename to teller-cli/tests/cmd/scan.in/.teller.yml diff --git a/teller-cli/tests/cmd/scan.trycmd b/teller-cli/tests/cmd/scan.trycmd index 8d471e7f..46a27fc4 100644 --- a/teller-cli/tests/cmd/scan.trycmd +++ b/teller-cli/tests/cmd/scan.trycmd @@ -1,5 +1,5 @@ ```console -$ teller -c teller.yml scan +$ teller scan scanning for 4 item(s) in . 2:9 ./one.env fo*** dotenv one.env 2:9 ./two.env ba*** dotenv two.env @@ -7,7 +7,7 @@ scanning for 4 item(s) in . 1:12 ./one.env li*** dotenv one.env found 4 result(s) -$ teller -c teller.yml scan -a +$ teller scan -a scanning for 4 item(s) in . 2:9 ./one.env fo*** dotenv one.env 2:9 ./two.env ba*** dotenv two.env @@ -16,7 +16,7 @@ scanning for 4 item(s) in . 1:12 ./one.env li*** dotenv one.env found 5 result(s) -$ teller -c teller.yml scan -b +$ teller scan -b scanning for 4 item(s) in . 2:9 ./one.env fo*** dotenv one.env 2:9 ./two.env ba*** dotenv two.env diff --git a/teller-cli/tests/cmd/template.in/teller.yml b/teller-cli/tests/cmd/template.in/.teller.yml similarity index 100% rename from teller-cli/tests/cmd/template.in/teller.yml rename to teller-cli/tests/cmd/template.in/.teller.yml diff --git a/teller-cli/tests/cmd/template.trycmd b/teller-cli/tests/cmd/template.trycmd index 7ba16b92..80b0d674 100644 --- a/teller-cli/tests/cmd/template.trycmd +++ b/teller-cli/tests/cmd/template.trycmd @@ -1,5 +1,5 @@ ```console -$ teller -c teller.yml template --in config-templ.t +$ teller template --in config-templ.t production_var: linus production_mood: happy