Skip to content

Commit

Permalink
Make purge remove source directory even if not default
Browse files Browse the repository at this point in the history
  • Loading branch information
twpayne committed Aug 22, 2020
1 parent 4b1fc64 commit 78da220
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cmd/purge.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@ func (c *Config) runPurgeCmd(cmd *cobra.Command, args []string) error {
paths = append(paths, filepath.Join(dir, "chezmoi"))
}
}
paths = append(paths, c.configFile, c.getPersistentStateFile())
paths = append(paths,
c.configFile,
c.getPersistentStateFile(),
c.SourceDir,
)

// Remove all paths that exist.
PATH:
Expand Down

0 comments on commit 78da220

Please sign in to comment.