mirror of
https://github.com/ddworken/hishtory.git
synced 2024-11-23 00:34:27 +01:00
mkdir ~/.config/fish if it doesn't exist yet
This commit is contained in:
parent
54679dc2db
commit
2ee050a629
@ -578,6 +578,10 @@ func configureFish(homedir, binaryPath string) error {
|
||||
return nil
|
||||
}
|
||||
// Add to fishrc
|
||||
err = os.MkdirAll(path.Join(homedir, ".config/fish"), 0o744)
|
||||
if err != nil {
|
||||
return fmt.Errorf("failed to create fish config directory: %v", err)
|
||||
}
|
||||
f, err := os.OpenFile(path.Join(homedir, ".config/fish/config.fish"), os.O_APPEND|os.O_WRONLY|os.O_CREATE, 0o644)
|
||||
if err != nil {
|
||||
return fmt.Errorf("failed to append to ~/.config/fish/config.fish: %v", err)
|
||||
|
Loading…
Reference in New Issue
Block a user