-
-
Notifications
You must be signed in to change notification settings - Fork 273
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Automates uninstallation method #197
base: main
Are you sure you want to change the base?
Conversation
a062ed0
to
a77b328
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Having an uninstall script is essential, so thank you for doing this work! I've left some comments on some bugs that I found.
} | ||
|
||
get_manifest_path() { | ||
local manifest_path=$(find . -name 'install-manifest.txt' -type f -print) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The file is named install_manifest.txt
, not install-manifest.txt
, at least when I tried it.
|
||
get_manifest_path() { | ||
local manifest_path=$(find . -name 'install-manifest.txt' -type f -print) | ||
if [ 1 -lt ${#manifest_path} ]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure what this line is meant to do. Is it checking for an empty string? It doesn't seem to work as intended for me.
get_manifest_path() { | ||
local manifest_path=$(find . -name 'install-manifest.txt' -type f -print) | ||
if [ 1 -lt ${#manifest_path} ]; then | ||
printf '%s\n' "This repo has not been built yet. Please build it to generate install-manifest.txt. Continuing..." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be good if this error got printed to stderr, to avoid corrupting the result of $(get_manifest_path)
echo "manifest_path is $manifest_path" | ||
while IFS= read -r line; do | ||
printf '%s\n' "Removing $line.." | ||
rm "$line" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line needs to be preceded with sudo
to avoid a "permission denied" error. Or the whole script needs to be run with sudo
.
It also may need a -f
to stop an error code from causing this function to exit early, since set -e
has been set.
Summary
In response to #83 regarding uninstallation difficulties, this PR introduces a bash script to automate uninstall of the logiops driver and disable it in systemd.
Testing Instructions
systemctl status logid
../uninstall.sh
.