Results 1 to 7 of 7

Thread: What Does "-y" Mean?

  1. #1
    Join Date
    Jun 2013
    Beans
    81

    What Does "-y" Mean?

    Hi,

    I am a noob with the command line so please bear with me.

    I just upgraded GIMP to the latest version (2.8.8). I added the GIMP PPA (since 2.8.8 is not available in the Ubuntu repository) and installed GIMP via the command line using:

    sudo apt-get install -y gimp

    As instructed at ubuntuhandbook.org.

    So, what does the "-y" mean, in the above command? Why wouldn't I just use:

    sudo apt-get install gimp

    And if I did use that command, would Ubuntu have tried to install from both the GIMP and Ubuntu repositories?

    Thanks in advance!

  2. #2
    Join Date
    Sep 2006
    Location
    France.
    Beans
    Hidden!
    Distro
    Lubuntu 14.10 Utopic Unicorn

    Re: What Does "-y" Mean?

    Code:
    -y, --yes, --assume-yes
    Automatic yes to prompts. Assume "yes" as answer to all prompts and run non-interactively. If an undesirable situation, such as changing a held package or removing an essential package, occurs then apt-get will abort.
    It will force to answer yes to any prompt apt-get might give you during the install.

    http://linux.die.net/man/8/apt-get
    | My old and mostly abandoned blog |
    Linux user #413984 ; Ubuntu user #178
    J'aime les fraises.
    Nighty night me lovelies!

    | Reinstalling Ubuntu ? Please check this bug first ! |
    | Using a ppa ? Please install ppa-purge from universe, you may need it should you want to revert packages back |
    | No support requests by PM, thanks |

  3. #3
    Join Date
    Jul 2007
    Location
    Magic City of the Plains
    Beans
    Hidden!
    Distro
    Xubuntu 14.10 Utopic Unicorn

    Re: What Does "-y" Mean?

    From
    Code:
    man apt-get
    Code:
    -y, --yes, --assume-yes
               Automatic yes to prompts; assume "yes" as answer to all prompts and run
               non-interactively. If an undesirable situation, such as changing a held
               package, trying to install a unauthenticated package or removing an essential
               package occurs then apt-get will abort.
    If you know exactly what you're doing, feel free to use -y. Personally I like having the option to abort, so I seldom use it.

    And if I did use that command, would Ubuntu have tried to install from both the GIMP and Ubuntu repositories?
    If you have the gimp PPA (I'm assuming there is one, haven't looked), apt-get will install the most recent version of gimp from it.

  4. #4
    Join Date
    Jun 2013
    Beans
    81

    Re: What Does "-y" Mean?

    Thanks!

    So how does Ubuntu know to download and install 2.8.8 from the GIMP PPA and not 2.8.6 from the Ubuntu PPA?

    Nevermind: this was answered by oldos2er while I was writing and posting...

  5. #5
    Join Date
    Jul 2007
    Location
    Magic City of the Plains
    Beans
    Hidden!
    Distro
    Xubuntu 14.10 Utopic Unicorn

    Re: What Does "-y" Mean?

    As far as I know, APT will always install the most recent version it can find, as defined by your sources.list and any PPAs you have in /etc/apt/sources.list.d/

  6. #6
    Join Date
    Jun 2013
    Beans
    81

    Re: What Does "-y" Mean?

    Thanks! I really appreciate the help!

  7. #7
    Join Date
    Jul 2007
    Location
    Magic City of the Plains
    Beans
    Hidden!
    Distro
    Xubuntu 14.10 Utopic Unicorn

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •