Giter Club home page Giter Club logo

Comments (16)

DrewPerlman avatar DrewPerlman commented on July 20, 2024

Thanks for opening this issue @pranesh-s.
To go into more detail about this issue, we'd like to have an uninstall script that reverses/"undo's" everything that the install script does so we can test that the install script is doing its job.

from ole--vagrant-community.

sthak004 avatar sthak004 commented on July 20, 2024

@DrewPerlman What do you mean by a second install script? Are there two?

from ole--vagrant-community.

Hulmani avatar Hulmani commented on July 20, 2024

@DrewPerlman could you please elaborate on this?

from ole--vagrant-community.

sthak004 avatar sthak004 commented on July 20, 2024

@DrewPerlman I am currently researching and working on this issue. Would it be more helpful if I created a windows batch script to uninstall bonjour and putty as done in https://github.com/dogi/ole--vagrant-community/blob/master/windows/bonjour_putty_installation.bat as a method of testing?

from ole--vagrant-community.

DrewPerlman avatar DrewPerlman commented on July 20, 2024

Sorry for the late response @sthak004 and @Hulmani. What I meant was we need an install script that installs all the required components AND an uninstall script to remove all of those components in order to test that the install script is working. Does that make sense?

And @sthak004, if the install script adds bonjour and putty to the system (not sure if putty is going to be necessary in the install script fyi), then the UNinstall script should remove them. To start off, however, I would probably go in the direction of uninstalling the vagrant machine and virtualbox.

from ole--vagrant-community.

sthak004 avatar sthak004 commented on July 20, 2024

@DrewPerlman I have submitted #20
I'm not sure if this was the method you wanted the file in (as opposed a zip file or something else).
Please let me know if this is acceptable and if so, I'd like to pass it over to other Windows users to test.

from ole--vagrant-community.

Hulmani avatar Hulmani commented on July 20, 2024

Please help test this uninstall script on mac.

This works if brew cask is installed and the virtualbox and vagrant installed using brew cask.
[The install script will be installing brew cask to install ** virtualbox and vagrant ** and hence brew cask is assumed to be installed]

#!/bin/bash

#assuming brew cask is installed (via install script);
VB="virtualbox";
VG="vagrant";
cask_list=`brew cask list`;

vb=$(echo "$cask_list" | grep "$VB" );
vg=$(echo "$cask_list" | grep "$VG" );

#the variables vb and vg contain the value "virtaulbox" and "vagrant" respectively if they are installed
if [[ $vb == "$VB" ]] ; then
echo "unistalling virtual box";
brew cask uninstall virtualbox;
else
echo 'virtualbox not installed'
fi

if [[ $vg == "$VG" ]] ; then
echo "unistalling vagrant";
brew cask uninstall vagrant;
else
echo 'vagrant not installed'
fi
  1. save this script as uninstall.sh.
  2. chmod +x uninstall.sh
  3. ./uninstall.sh

Please enter the password to complete the steps.
Please comment to let me know the issues with the script

from ole--vagrant-community.

sthak004 avatar sthak004 commented on July 20, 2024

@DrewPerlman I am working on uninstalling Git from Windows machines. I can try and uninstall Git from the virtualbox_and_vagrant uninstaller script as an add-on if you'd like or I can create a different script for it. Is there a preference that you or @dogi would rather see?

from ole--vagrant-community.

DrewPerlman avatar DrewPerlman commented on July 20, 2024

@Hulmani I personally can't test your script because I don't have a Mac, but it looks good! Please submit a pull request with your code.

@sthak004 I think it'd be better add the Git uninstall to the uninstall script you've already made instead of creating a new script in order to keep it more streamlined.

from ole--vagrant-community.

EmilyLarkin avatar EmilyLarkin commented on July 20, 2024

@Hulmani: @DrewPerlman and @dogi tested your script and this was the output:

emily@scout ~/ole--vagrant-community/macosx $ ./uninstall.sh
Warning: The default Caskroom location has moved to /usr/local/Caskroom.

Please migrate your Casks to the new location and delete /opt/homebrew-cask/Caskroom,
or if you would like to keep your Caskroom at /opt/homebrew-cask/Caskroom, add the
following to your HOMEBREW_CASK_OPTS:

  --caskroom=/opt/homebrew-cask/Caskroom

For more details on each of those options, see https://github.com/caskroom/homebrew-cask/issues/21913.
virtualbox not installed
vagrant not installed

from ole--vagrant-community.

Hulmani avatar Hulmani commented on July 20, 2024

@EmilyLarkin @dogi while installing vagrant and virtualbox, we have to use brew cask to install them.
Please see this link.
So if we use this link to download vagrant, the script is unable to recognize as it is using brew casks.
As we are using script to install and uninstall software, I assumed we will use brew cask.

Please try this to uninstall vagrant and if you have installed virtual box the from the website, uninstall virtual box from deleting it from the applications directory.
right click virtual box in the applications directory and click on move to trash

After you delete the two, please run

brew cask install virtualbox
brew cask install vagrant

then run the uninstall script.

I will soon update on install script.

from ole--vagrant-community.

sthak004 avatar sthak004 commented on July 20, 2024

@dogi @DrewPerlman So, I have hit a bit of a roadblock in incorporating Git into the virtualbox and vagrant uninstaller script.

I realized that both vagrant and virtualbox use MSI uninstallers, while Git does not

The issue here:
Incorporating Git into my script as it is now, will cause the code to become longer and unnecessarily messy, as compensating for Git having its own uninstaller would mean the newly added code would not keep the script as modular as possible.

My suggestion:

Create a new uninstall script for Git and call it from the vagrant_virtualbox_uninstaller.bat script.

from ole--vagrant-community.

DrewPerlman avatar DrewPerlman commented on July 20, 2024

@Hulmani Okay, I'll try that soon and let you know the results.

@sthak004 Your solution of having a different uninstall script for Git and calling it from the other uninstall script sounds good! 😄

from ole--vagrant-community.

DrewPerlman avatar DrewPerlman commented on July 20, 2024

@Hulmani Just tried your instructions above with brew cask and using your uninstall.sh and it worked! 😄

from ole--vagrant-community.

sthak004 avatar sthak004 commented on July 20, 2024

@DrewPerlman I have submitted a PR #25

I have wrote in the PR message, but just to reiterate, I could not find a way disable any GUI interface from appearing when GIt is being uninstalled. It is however, considered a silent uninstall so the user doesn't have to interact in any way and it only lasts momentarily.

from ole--vagrant-community.

sthak004 avatar sthak004 commented on July 20, 2024

@DrewPerlman Also, I apologize for the script naming because I forgot to change those, but in order to uninstall VirtualBox, Vagrant, and Git you would simply call virtualbox_vagrant_uninstaller.bat since it calls the git_uninstaller script within it.

TODO: I will make the changes shortly to improve clarity.

from ole--vagrant-community.

Related Issues (17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.