diff --git a/dcos/api/constants.py b/dcos/api/constants.py index 5799040..8a72b7c 100644 --- a/dcos/api/constants.py +++ b/dcos/api/constants.py @@ -1,3 +1,6 @@ +DCOS_DIR = ".dcos" +"""DCOS data directory. Can store subcommands and the config file.""" + DCOS_SUBCOMMAND_SUBDIR = 'subcommands' """Name of the subdirectory that contains all of the subcommands. This is relative to the location of the executable.""" diff --git a/dcos/api/subcommand.py b/dcos/api/subcommand.py index e4cac95..aebc6b4 100644 --- a/dcos/api/subcommand.py +++ b/dcos/api/subcommand.py @@ -42,7 +42,9 @@ BIN_DIRECTORY = 'Scripts' if util.is_windows_platform() else 'bin' def _subcommand_dir(): - return os.path.expanduser(os.path.join("~", ".dcos", "subcommands")) + return os.path.expanduser(os.path.join("~", + constants.DCOS_DIR, + constants.DCOS_SUBCOMMAND_SUBDIR)) def list_paths(dcos_path):