doctr icon indicating copy to clipboard operation
doctr copied to clipboard

DOC: warn about --force for dirty repos

Open stsievert opened this issue 3 years ago • 2 comments

What does this PR implement? It warns about running doctr deploy with the --force flag and dirty files.

I made the mistake of doing this, and this warning would have prevented my mistake. I am submitting this PR to ask a question: how do I recover those dirty files untracked by Git? Or are they gone forever?

stsievert avatar Aug 02 '20 22:08 stsievert

doctr deploy --force should basically never be used. It forces doctr to run locally, whereas it normally only runs in Travis. It's only useful for development. We should probably hide the flag.

doctr deploy stashes your dirty changes. It should unstash them, but maybe that failed. You can try running git stash pop manually.

asmeurer avatar Aug 02 '20 22:08 asmeurer

doctr deploy stashes your dirty changes. It should unstash them, but maybe that failed. You can try running git stash pop manually.

Luckily I've been able to recover. git stash didn't have my changes, but (very luckily) I've aliased rm to move files macOS's "Trash" directory.

stsievert avatar Aug 02 '20 22:08 stsievert