diff options
author | Nate Sesti <sestinj@gmail.com> | 2023-08-24 13:09:05 -0700 |
---|---|---|
committer | Nate Sesti <sestinj@gmail.com> | 2023-08-24 13:09:05 -0700 |
commit | 4fe9ace518bcdcf79999ce9938ba01b218d355e4 (patch) | |
tree | 3ebbfcead61ad5d68b682a1910ed9f9beb9e0d86 /continuedev/src | |
parent | e04b0ca679f2b8965f2d71daec9aa36114142cad (diff) | |
download | sncontinue-4fe9ace518bcdcf79999ce9938ba01b218d355e4.tar.gz sncontinue-4fe9ace518bcdcf79999ce9938ba01b218d355e4.tar.bz2 sncontinue-4fe9ace518bcdcf79999ce9938ba01b218d355e4.zip |
fix: :bug: replace hardcoded path for config file
Diffstat (limited to 'continuedev/src')
-rw-r--r-- | continuedev/src/continuedev/libs/util/edit_config.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/continuedev/src/continuedev/libs/util/edit_config.py b/continuedev/src/continuedev/libs/util/edit_config.py index 5c070bb4..17ce27ec 100644 --- a/continuedev/src/continuedev/libs/util/edit_config.py +++ b/continuedev/src/continuedev/libs/util/edit_config.py @@ -3,10 +3,11 @@ from typing import Dict, List import redbaron -config_file_path = "/Users/natesesti/.continue/config.py" +from .paths import getConfigFilePath def load_red(): + config_file_path = getConfigFilePath() with open(config_file_path, "r") as file: source_code = file.read() @@ -48,7 +49,7 @@ def edit_config_property(key_path: List[str], value: redbaron.RedBaron): config_args = config.value.value[1].value edit_property(config_args, key_path, value) - with open(config_file_path, "w") as file: + with open(getConfigFilePath(), "w") as file: file.write(red.dumps()) |