bash-it icon indicating copy to clipboard operation
bash-it copied to clipboard

[Bug]: Uninstall script shouldn't delete existing bashrc and mindlessly pull from old backup

Open hrfried opened this issue 1 year ago • 2 comments

Expected behavior

Should NOT just revert back to a config created at initial install that may be ages out of date...

Current behavior

It apparently creates a backup at the first install then just reverts back to that, deleting any changes that may have been made since.

Possible solution

Just don't do that....create a backup just in case of the existing file...pull into a separate .bashitrc file...

Easiest half-ass fix would be to drop in a line to copy the file to be overwritten over to .bashrc-bashit-uninstall and prompt the user to delete it afterwards if they want. Not just pull from an indeterminately old backup and wipe over it.

Context

Tested out bash-it ages ago and it didn't fit my needs. Was cleaning up stuff and saw it had an uninstall script. Should have looked before running...thankfully I have backups, but that's not an acceptable way to do this.

Steps to reproduce

Trivial

Bash-it version

dontcarebutcurrent

List of enabled plugins, themes and aliases

irrelevant

Bash version

irrelevant

Operating system and version

irrelevant

bash-it doctor output

# How to get: bash-it doctor

Your ~/.bashrc

irrelevant

Notes

No response

hrfried avatar Dec 17 '23 23:12 hrfried