I think this post potentially mischaracterises what may be a one off issue for a certain person as if it were a broader problem. I'm guessing some context has been corrupted?
It's not a one off issue - it has happened to me a few times. It has once even force pushed to github, which doesn't allow branch protection for private personal projects. Here's an example. 1) claude will stash (despite clear instructions never to do so). 2) claude will use sed to bulk replace (despite clear instructions never to do so). sed replacements make a mess and replaces far too many files. 3) claude restore…
Claude Code runs Git reset –hard origin/main against project repo every 10 mins
151–160 of 219 posts
Re: Claude Code runs Git reset –hard origin/main against project repo every 10 mins
#152I think this post potentially mischaracterises what may be a one off issue for a certain person as if it were a broader problem. I'm guessing some context has been corrupted?
It's not a one off issue - it has happened to me a few times. It has once even force pushed to github, which doesn't allow branch protection for private personal projects. Here's an example. 1) claude will stash (despite clear instructions never to do so). 2) claude will use sed to bulk replace (despite clear instructions never to do so). sed replacements make a mess and replaces far too many files. 3) claude restore…
Re: Claude Code runs Git reset –hard origin/main against project repo every 10 mins
#153Earlier quoted context omitted.
Sounds like you care about data stored on your filesystem! Take one step back and solve that problem. Use a proper isolated sandbox, e.g. Github workspace on an account that is working with a fork. Care about the data in that workspace? Push it first. Othwerwise it is a cat and mouse game of whackamole.
Does any one of this help me if Claude runs `git reset --hard`? If I am working in a sandbox, I have uncommitted changes in a sandbox and if Claude runs `git reset --hard` on those uncommitted changes in the sandbox, I've got the same problem? > Care about the data in that workspace? Push it first. But you're changing the problem. If I push everything, then yeah I've got no problem. But between pushing one change and…
Also you can instruct it to commit and push at every step too.
Re: Claude Code runs Git reset –hard origin/main against project repo every 10 mins
#154Earlier quoted context omitted.
I agree that it should be left as a double hyphen, but an en dash is far more appropriate considering the decades-long precedent set by LaTeX (and continued by Typst).
It's a command line argument. The undeniably correct way to render it is with two minus signs[1] and absolutely not something non-ascii. [1] Not strictly a hyphen, which has its own unicode point (0x2010) outside of ascii. Unicode embraced the ambiguity by calling this point (0x2d) "HYPHEN-MINUS" formally, but really its only unique typographic usage is to represent subtraction.
Re: Claude Code runs Git reset –hard origin/main against project repo every 10 mins
#155I think this post potentially mischaracterises what may be a one off issue for a certain person as if it were a broader problem. I'm guessing some context has been corrupted?
It's not a one off issue - it has happened to me a few times. It has once even force pushed to github, which doesn't allow branch protection for private personal projects. Here's an example. 1) claude will stash (despite clear instructions never to do so). 2) claude will use sed to bulk replace (despite clear instructions never to do so). sed replacements make a mess and replaces far too many files. 3) claude restore…
Re: Claude Code runs Git reset –hard origin/main against project repo every 10 mins
#156Re: Claude Code runs Git reset –hard origin/main against project repo every 10 mins
#157Earlier quoted context omitted.
It's not a one off issue - it has happened to me a few times. It has once even force pushed to github, which doesn't allow branch protection for private personal projects. Here's an example. 1) claude will stash (despite clear instructions never to do so). 2) claude will use sed to bulk replace (despite clear instructions never to do so). sed replacements make a mess and replaces far too many files. 3) claude restore…
Why do you expect that a weighted random text generator will ever behave in predictable way? How can people be so naive as to run something like Claude anywhere other than in a strictly locked down sandbox that has no access to anything but the single git repo they are working on (and certainly no creds to push code)? This is absolutely insane behavior that you would give Claude access to your GitHub creds. What happ…
Because it is much easier to do and failure rate is quite low.
(not saying that it is a good idea)
Re: Claude Code runs Git reset –hard origin/main against project repo every 10 mins
#158Earlier quoted context omitted.
It's not a one off issue - it has happened to me a few times. It has once even force pushed to github, which doesn't allow branch protection for private personal projects. Here's an example. 1) claude will stash (despite clear instructions never to do so). 2) claude will use sed to bulk replace (despite clear instructions never to do so). sed replacements make a mess and replaces far too many files. 3) claude restore…
Maybe stop using the CLAUDE.md to prevent it from running tools you don't want it to and just setup a hook for pretooluse that blocks any command you don't want. Its trivial to setup and you could literally ask claude to do it for you and never have any of these issues ever again. Any and all "I don't want it to ever run this command" issues are just skill issues.
Re: Claude Code runs Git reset –hard origin/main against project repo every 10 mins
#159Earlier quoted context omitted.
Surely its copy and paste though?
You underestimate just how annoying iOS autocomplete can be.
A few months on… I like it! Frustration is all gone, any errors are just on me now, and it forces me to slow down a bit and use the brain a bit more!