Skip to content

Commit

Permalink
Merge pull request #518 from MarlzRana/fix-cd-on-quit
Browse files Browse the repository at this point in the history
Enable cd_on_quit When Current Directory is Home Directory
  • Loading branch information
yorukot authored Dec 17, 2024
2 parents ed17192 + 0cefce7 commit 77c4baf
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions src/internal/model.go
Original file line number Diff line number Diff line change
Expand Up @@ -431,9 +431,6 @@ func (m model) quitSuperfile() {
variable.LastDir = currentDir

if Config.CdOnQuit {
if currentDir == variable.HomeDir {
return
}
// escape single quote
currentDir = strings.ReplaceAll(currentDir, "'", "'\\''")
os.WriteFile(variable.SuperFileStateDir+"/lastdir", []byte("cd '"+currentDir+"'"), 0755)
Expand Down

0 comments on commit 77c4baf

Please sign in to comment.