Is there a clever way to get rid of all the `*-lock_BASE_*` and `*-lock-REMOTE_*` and `*.orig*` etc files that emerge while merging things in git? Without removing other untracked files...?

I think I'm looking for something like a `git merge --cleanup`

I remember bad times with svn…
You may want to have a look at git stash:

For your current problem, you could combine find and rm, but create a backup first :D

@flukdipudl @mascha no need for rm, just add the -delete option. Should be safe as long as you do a dry run without the -delete flag and make sure you don't pick up any files you don't want to delete.

Sign in to participate in the conversation

Fosstodon is an English speaking Mastodon instance that is open to anyone who is interested in technology; particularly free & open source software.