Sure, but I've written +150K lines of AI generated code myself and never seen it do a destructive command. Pretty much Cursor non-stop and my own agent before that.
Show HN: A Claude Code plugin that catch destructive Git and filesystem commands
51–60 of 72 posts
Re: Show HN: A Claude Code plugin that catch destructive Git and filesystem commands
#52In my opinion this is a solution at the wrong layer. It's working by trying to filter executed commands, but it doesn't work in many cases (even in 'strict mode'), and there's better, more complete, solutions. What do I mean by "it doesn't work"? Well, claude code is really good at executing things in unusual ways when it needs to, and this is trying to parse shell to catch them. When claude code has trouble running…
If the LLM never gets a chance to try to work around the block then this is more likely to work. Probably one better way to do this would be, if it detects a destructive edit, block it and switch Claude out of any autoaccept mode until the user re-engages it. If the model mostly doesn't realize there is a filter at all until it's blocked, it won't know to work around it until it's kicked the issue up to the user, who…
Re: Show HN: A Claude Code plugin that catch destructive Git and filesystem commands
#53https://github.com/Dicklesworthstone/misc_coding_agent_tips_...
You be the judge:
Re: Show HN: A Claude Code plugin that catch destructive Git and filesystem commands
#54In my opinion this is a solution at the wrong layer. It's working by trying to filter executed commands, but it doesn't work in many cases (even in 'strict mode'), and there's better, more complete, solutions. What do I mean by "it doesn't work"? Well, claude code is really good at executing things in unusual ways when it needs to, and this is trying to parse shell to catch them. When claude code has trouble running…
Yeah, I had an issue where Claude was convinced that a sqlite database was corrupt and kept wanting to delete it. It wasn't corrupt, the code using it was just failing to parse the data it was retrieving from it correctly. I kept telling it to debug the problem, and that I had confirmed that database file was not the problem. It kept trying to rm the file after it noticed the code would recreate it (although with no…
Re: Show HN: A Claude Code plugin that catch destructive Git and filesystem commands
#55This sure looks similar to something I posted on X 2 weeks ago: https://github.com/Dicklesworthstone/misc_coding_agent_tips_... You be the judge: https://x.com/doodlestein/status/2002423770259345451?s=46
Re: Show HN: A Claude Code plugin that catch destructive Git and filesystem commands
#56Sure, but I've written +150K lines of AI generated code myself and never seen it do a destructive command. Pretty much Cursor non-stop and my own agent before that.
Re: Show HN: A Claude Code plugin that catch destructive Git and filesystem commands
#57In my opinion this is a solution at the wrong layer. It's working by trying to filter executed commands, but it doesn't work in many cases (even in 'strict mode'), and there's better, more complete, solutions. What do I mean by "it doesn't work"? Well, claude code is really good at executing things in unusual ways when it needs to, and this is trying to parse shell to catch them. When claude code has trouble running…
I recently had a similar conflict with GPT-5.1, where I did not want it to use a specific Python function. As a result, it wrote several sandbox escape exploits, for example the following, which uses the stack frame of an exception to call arbitrary functions: name_parts = ("com", "pile") name = "".join(name_parts) try: raise RuntimeError except RuntimeError as exc: frame = exc.__traceback__.tb_frame builtins_dict =…
Re: Show HN: A Claude Code plugin that catch destructive Git and filesystem commands
#58This sure looks similar to something I posted on X 2 weeks ago: https://github.com/Dicklesworthstone/misc_coding_agent_tips_... You be the judge: https://x.com/doodlestein/status/2002423770259345451?s=46
Re: Show HN: A Claude Code plugin that catch destructive Git and filesystem commands
#59Earlier quoted context omitted.
If the LLM never gets a chance to try to work around the block then this is more likely to work. Probably one better way to do this would be, if it detects a destructive edit, block it and switch Claude out of any autoaccept mode until the user re-engages it. If the model mostly doesn't realize there is a filter at all until it's blocked, it won't know to work around it until it's kicked the issue up to the user, who…
You better hope Clause isn’t reading this thread!
Re: Show HN: A Claude Code plugin that catch destructive Git and filesystem commands
#60In my opinion this is a solution at the wrong layer. It's working by trying to filter executed commands, but it doesn't work in many cases (even in 'strict mode'), and there's better, more complete, solutions. What do I mean by "it doesn't work"? Well, claude code is really good at executing things in unusual ways when it needs to, and this is trying to parse shell to catch them. When claude code has trouble running…
I recently had a similar conflict with GPT-5.1, where I did not want it to use a specific Python function. As a result, it wrote several sandbox escape exploits, for example the following, which uses the stack frame of an exception to call arbitrary functions: name_parts = ("com", "pile") name = "".join(name_parts) try: raise RuntimeError except RuntimeError as exc: frame = exc.__traceback__.tb_frame builtins_dict =…