chrisant996/clink

Loop bug fatal error (how to fix mistake in CMD AutoRun regkey?)

Closed this issue · 6 comments

Hi, so ive tried to make clink autorun on cmd, but i did a mistake and ran

“clink —autorun set cmd.exe”
This created a infinite and unstoppable loop, of creating cmds and it crashes my pc everytime and autostarts everytime. I tried unininstalling clink but the error is still there.

how do i fix this? I cannot use my pc terminal without crashing my pc
( powershell works )

First, an explanation:

Autorun uses CMD's AutoRun regkey, which allows you to provide commands for CMD to run every time it starts. If you make the AutoRun regkey run CMD, then naturally it creates an infinite loop -- every time CMD starts, it checks AutoRun and starts CMD, which checks AutoRun and starts CMD, etc etc etc.

I'm not sure what you did, but it wasn't clink --autorun set cmd.exe -- that just produces syntax errors because it's nonsensical.

What you should have done was run clink autorun install. The Usage section of the documentation or running clink autorun --help have some useful reference text.

Getting out of the situation

  1. Press Win-R to show the "Run" dialog box.
  2. Type c:\program files (x86)\clink\clink_x64.exe autorun uninstall, or whatever the full path is to the clink_x64.exe program wherever you installed Clink.

I installed it using scoop, i used scoop uninstall + manually removed from scoop however i havent removed from the C:/ Program Files directory, does it store the files there even using scoop?

Also, youre right that wasnt the exact syntax but it did contain clink autorun and at the end "cmd.exe" not sure how i got it to loop to infinite however.

I installed it using scoop, i used scoop uninstall + manually removed from scoop however i havent removed from the C:/ Program Files directory, does it store the files there even using scoop?

I don't know how to interpret those statements.

I can understand why it could have seemed like trying to uninstall Clink might help, but instead that further exacerbated the problem.

You need to delete the CMD AutoRun regkey.

I did a quick internet search for that and found lots of information on how to do that, so I recommend trying that. I would try to help more, except it's 3 AM in my time zone, and I need sleep.

(The problem at this point has nothing to do with Clink, apart from having used Clink as the way to manually tinker with the CMD AutoRun regkey. That's dangerous, and I don't recommend manually tinkering with it -- clink autorun install is designed to take care of it for you without any manual tinkering or overrides.)

I understand, and sorry for keeping you up i got a whole different timezone. Ill try to do what you've suggested and let you know later.

Thank you

Fixed