Apt-get: non interactive install, search for package, uninstall package

By neokrates, written on May 21, 2010

howto

Rate it
  • 1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
    Loading ... Loading ...
Ad
Poll
  • Your skill as shell programmer is?

    • No skill (35%, 7 Votes)
    • FreeTime coder (acceptable) (25%, 5 Votes)
    • Developer (good) (15%, 3 Votes)
    • Novice (15%, 3 Votes)
    • Admin (very good) (10%, 2 Votes)
    • Guru (perfect) (0%, 0 Votes)

    Total Voters: 20

    Vote

    Loading ... Loading ...
Feeds:
  • bodytext bodytext bodytext
Most popular search terms:

Apt-get would often require interaction, expect you to say “yes” or “no”. Not good for scripts. In most cases easy to avoid. Some more useful apt-get’s examples.

Software:

[v] Ubuntu *

1

Non interactive install

Use apt-get –force-yes –yes.

For example get xulrunner-1.9, apt-get asks no questions:

> sudo apt-get --force-yes --yes install xulrunner-1.9

2

Find out exact package name

You are not sure, which is the name and version of the package you need.

Use apt-cache search.

Example:

> sudo apt-cache search dbus

 
Now, you can choose from all packages and version the one you need.

3

Uninstall package

apt-get remove removes the package itself:

> sudo apt-get remove xulrunner-1.9

 
apt-get remove will also remove the ‘unused dependencies’.
 
[!] Warning: In my experience some of the dependencies that Unix sees as unused might be still needed.


[i] Remark: Not in each distro, i.e. on Ubuntu, up Ubuntu Edgy Eft (6.10)

> apt-get autoremove xulrunner-1.9
 
Does that help to solve your problem?
VN:F [1.8.5_1061]
Rating: -1 (from 1 vote)
0 votes 'YES'  1 votes 'NO'

LEARN MORE (amazon bookstore)

TAGS

RELATED
Pages
Posts
    nope :(

SOCIAL
Share and Enjoy: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • bodytext
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google
  • BlinkList
  • Blogosphere News
  • E-mail this story to a friend!
  • Furl
  • LinkArena
  • Live
  • MisterWong
  • Print this article!
  • StumbleUpon
  • Technorati
  • Webnews.de
  • YahooMyWeb

INCOMING SEARCH TERMS


Leave a Reply