How does MAC uninstall Jenkins

Yesterday, when I installed Jenkins, I found that my Mac had already installed Jenkins, and I forgot my password. So I searched a lot of technical blogs, but I spent several hours without finding them. Finally, I found them on foreign websites http://stackoverflow.com/questions/11608996/how-to-uninstall-jenkins
The first time I wrote a blog, it was wrong. I’m sorry

First, uninstall Jenkins, open your Mac terminal, enter the following command/or find your Jenkins file, double-click the folder to run install. Command

2. Delete some configurations that may be forgotten

sudo rm -rf /var/root/.jenkins ~/.jenkins

3. If the old Jenkins version cannot be found, use the following command

sudo launchctl unload /Library/LaunchDaemons/org.jenkins-ci.plist
sudo rm /Library/LaunchDaemons/org.jenkins-ci.plist
sudo rm -rf /Applications/Jenkins "/Library/Application Support/Jenkins" /Library/Documentation/Jenkins

4. Delete all the contents of Jenkins folder

sudo rm -rf /<User you replace>/Shared/Jenkins

5. Delete user and group

sudo dscl . -delete /Users/jenkins
sudo dscl . -delete /Groups/jenkins

6. The following command is also uninstalled from the newer version of Jenkins in the script

sudo rm -f /etc/newsyslog.d/jenkins.conf
pkgutil --pkgs | grep 'org\.jenkins-ci\.' | xargs -n 1 sudo pkgutil --forget

Similar Posts: