Skip to content

Commit 12b47a3

Browse files
committed
Merge pull request #21 from drdancain/feature/cfg-from-env
Allowing override of CFG_(DIR|FILE) from ENV to support multiple endpo…
2 parents 11bfd57 + 2946d1a commit 12b47a3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

stackdio/cli/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ class StackdioShell(
2424
mixins.formulas.FormulaMixin,
2525
mixins.blueprints.BlueprintMixin):
2626

27-
CFG_DIR = os.path.expanduser("~/.stackdio-cli/")
28-
CFG_FILE = os.path.join(CFG_DIR, "config.json")
27+
CFG_DIR = os.path.expanduser(os.getenv('STACKDIO_CFG_DIR',"~/.stackdio-cli/"))
28+
CFG_FILE = os.path.join(CFG_DIR, os.getenv('STACKDIO_CFG_FILE',"config.json"))
2929
BOOTSTRAP_FILE = os.path.join(CFG_DIR, "bootstrap.yaml")
3030
KEYRING_SERVICE = "stackdio_cli"
3131
PROMPT = "\n{username} @ {url}\n> "

0 commit comments

Comments
 (0)