fix(cli): Don't silently overwrite existing config file
This commit is contained in:
parent
2b83500b74
commit
2e2b239c42
2 changed files with 7 additions and 1 deletions
|
|
@ -20,7 +20,7 @@ pub struct Config {
|
|||
}
|
||||
|
||||
impl Config {
|
||||
fn find_config_file() -> Result<Option<PathBuf>> {
|
||||
pub fn find_config_file() -> Result<Option<PathBuf>> {
|
||||
if let Ok(path) = env::var("TREE_SITTER_DIR") {
|
||||
let mut path = PathBuf::from(path);
|
||||
path.push("config.json");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue