Nie jesteś zalogowany.
Jeśli nie posiadasz konta, zarejestruj je już teraz! Pozwoli Ci ono w pełni korzystać z naszego serwisu. Spamerom dziękujemy!

Ogłoszenie

Prosimy o pomoc dla małej Julki — przekaż 1% podatku na Fundacji Dzieciom zdazyć z Pomocą.
Więcej informacji na dug.net.pl/pomagamy/.

#1  2015-01-05 21:26:12

  morfik - Cenzor wirtualnego świata

morfik
Cenzor wirtualnego świata
Skąd: ze WSI
Zarejestrowany: 2011-09-15
Serwis

Konfiguracja apt/aptitude

Z nudów przejrzałem sobie man apt, aptitude i apt.conf i naskrobałem sobie poniższy plik z konfiguracją apt/aptitude:

Kod:

#
# /etc/apt/apt.conf or ~/.aptitude/config
#
# http://aptitude.alioth.debian.org/doc/en/
#

# Location to fetch packages from.
Dir::Etc::SourceList "/etc/apt/sources.list";

# File fragments for locations to fetch packages from.
Dir::Etc::SourceParts "/etc/apt/sources.list.d/";

# APT configuration file.
Dir::Etc::Main "/etc/apt/apt.conf";

# APT configuration file fragments.
Dir::Etc::Parts "/etc/apt/apt.conf.d/";

# Version preferences file. This is where you would specify "pinning", i.e. a preference to get
# certain packages from a separate source or from a different version of a distribution.
Dir::Etc::Preferences "/etc/apt/preferences";

# File fragments for the version preferences.
Dir::Etc::PreferencesParts "/etc/apt/preferences.d/";

# Storage area for:
#  retrieved package files,
#  package files in transit,
#  state information for each package resource specified in sources.list(5)
Dir::Cache "/media/Kabi/backup_packages/apt";
Dir::Cache::Archives "/media/Kabi/backup_packages/apt/archives/";
Dir::State::Lists "/media/Kabi/backup_packages/apt/lists/";

# Default release to install packages from if more than one version is available. Contains release
# name, codename or release version. Examples: 'stable', 'testing', 'unstable', 'jessie', 'stretch',
# '4.0', '5.0*'.
#APT::Default-Release "testing";

# If this option is true, aptitude will automatically attempt to fulfill the dependencies of a
# package when you mark a package to be installed or upgraded. 
Aptitude::Auto-Install "true";

# If this option is true and Aptitude::Auto-Install is true, then whenever you mark a package for
# installation, aptitude will also mark the packages it recommends for installation. Furthermore,
# if this option is true, aptitude will not consider packages to be unused (and thus will not
# automatically remove them) as long as any installed package recommends them. 
APT::Install-Recommends "false";

# If this option is true and Aptitude::Auto-Install is true, then whenever you mark a package for
# installation, aptitude will also mark the packages it suggests for installation. Furthermore,
# if this option is true, aptitude will not consider packages to be unused (and thus will not
# automatically remove them) as long as any installed package suggests them. 
APT::Install-Suggests "false";

# If this option is true, then aptitude will not consider packages to be unused (and thus will not
# automatically remove them) as long as any installed package recommends them. 
APT::AutoRemove::RecommendsImportant "false";

# If this option is true, then aptitude will not consider packages to be unused (and thus will not
# automatically remove them) as long as any installed package suggests them. 
APT::AutoRemove::SuggestsImportant "false";

# Ignore if packages can't be authenticated and don't prompt about it.
APT::Get::AllowUnauthenticated "false";
Aptitude::CmdLine::Ignore-Trust-Violations "false";

# Show full versions for upgraded and installed packages.
APT::Get::Show-Versions "true";

# Use purge instead of remove for anything that would be removed. An asterisk ("*") will be
# displayed next to packages which are scheduled to be purged.
APT::Get::Purge "false";

# If the command is either install or remove, then this option acts like running the autoremove
# command, removing unused dependency packages.
APT::Get::AutomaticRemove "true";

# This option is on by default; use --no-list-cleanup to turn it off. When it is on, apt-get will
# automatically manage the contents of /var/lib/apt/lists to ensure that obsolete files are erased.
APT::Get::List-Cleanup "true";

# If this option is true, aptitude will clean up obsolete files (cache) every time you update the
# package list. 
Aptitude::Autoclean-After-Update "false";

# If this option is enabled, the results of command-line searches (performed via aptitude search)
# will not be formatted into fixed-width columns or truncated to the screen width.
Aptitude::CmdLine::Disable-Columns "true";

# Set to auto, none, package, or source-package to control whether and how the output of
# "aptitude versions" is grouped.
Aptitude::CmdLine::Versions-Group-By "source-package";

# This is a format string, which is used to display the results of "aptitude search" command.
Aptitude::CmdLine::Package-Display-Format "%c%a%M %p# => %d# [%t]";

# This controls how verbose the command-line mode of aptitude is. Every occurrence of the -v
# command-line option adds 1 to this value. 
Aptitude::CmdLine::Verbose "1";

# Show user friendly progress information in the terminal window when packages are installed,
# upgraded or removed.
Dpkg::Progress "true";
Dpkg::Progress-Fancy "true";

# Useful for systems with a separate /usr/ partition that is mounted in read only mode.
#DPkg
#{
#Pre-Invoke { "mount /usr -o remount,rw" };
#Post-Invoke { "mount /usr -o remount,ro" };
#};

# Try to download deltas called PDiffs for indexes (like Packages files) instead of downloading
# whole ones.
Acquire::PDiffs "true";

# The used bandwidth can be limited with this option, which accepts integer values in kilobytes
# per second. The default value is 0 which deactivates the limit and tries to use all available
# bandwidth. Note that this option implicitly disables downloading from multiple servers at the
# same time.
Acquire::http::Dl-Limit "0";
Acquire::https::Dl-Limit "0";
Acquire::ftp::Dl-Limit "0";

# These options set the timeout timer and this value applies to the connection as well as the
# data timeout.
Acquire::http::Timeout "2";
Acquire::https::Timeout "2";
Acquire::ftp::Timeout "2";

# When downloading, force to use only the IPv4 protocol.
Acquire::ForceIPv4 "true";

I teraz ten apt wygląda tak:

[img]http://i.imgur.com/mudPNBb.png[/img]

Tutaj upgrade

[img]http://i.imgur.com/CGLHc7K.png[/img]

A a tu wynik zwracany przy szukaniu pakietów:

[img]http://i.imgur.com/2whZuaY.png[/img]

Ma ktoś jakieś propozycje wpisów, które można by jeszcze tam dodać do apt.conf? Może da radę jakoś pokolorować to wyjście apt/aptitude?

Offline

 

#2  2015-01-05 21:55:14

  yossarian - Szczawiożerca

yossarian
Szczawiożerca
Skąd: Shangri-La
Zarejestrowany: 2011-04-25

Re: Konfiguracja apt/aptitude

Musiałbyś sobie sam to wyrzeźbić. Tu masz przykład:
http://www.kereoz.org/apt.html

Offline

 

#3  2015-01-05 21:58:26

  winnetou - złodziej wirków ]:->

winnetou
złodziej wirków ]:->
Skąd: Jasło/Rzeszów kiedyś Gdańs
Zarejestrowany: 2008-03-31
Serwis

Re: Konfiguracja apt/aptitude

[quote=morfik]Może da radę jakoś pokolorować to wyjście apt/aptitude?[/quote]
Nawet jakby w standardzie nie było opcji to się da ;) Hint: perl + Term::ANSIColor + wraper ;)

P.S.
Ktoś mnie ubiegł i zapodał prostszą wersję ;)


LRU: #472938
[b]napisz do mnie:[/b] ola@mojmail.eu
[url=http://valhalla.org.pl]Hołmpejdż[/url] | [url=http://valhalla.org.pl/foto]Galerie[/url] | [url=http://valhalla.org.pl/tech]"Twórczość"[/url] || [url=http://img.munn.in]Free Image Hosting[/url]

Offline

 

Stopka forum

Powered by PunBB
© Copyright 2002–2005 Rickard Andersson
Nas ludzie lubią po prostu, a nie klikając w przyciski ;-)

[ Generated in 0.006 seconds, 9 queries executed ]

Informacje debugowania

Time (s) Query
0.00009 SET CHARSET latin2
0.00005 SET NAMES latin2
0.00089 SELECT u.*, g.*, o.logged FROM punbb_users AS u INNER JOIN punbb_groups AS g ON u.group_id=g.g_id LEFT JOIN punbb_online AS o ON o.ident='18.226.226.158' WHERE u.id=1
0.00061 REPLACE INTO punbb_online (user_id, ident, logged) VALUES(1, '18.226.226.158', 1732537124)
0.00047 SELECT * FROM punbb_online WHERE logged<1732536824
0.00055 SELECT t.subject, t.closed, t.num_replies, t.sticky, f.id AS forum_id, f.forum_name, f.moderators, fp.post_replies, 0 FROM punbb_topics AS t INNER JOIN punbb_forums AS f ON f.id=t.forum_id LEFT JOIN punbb_forum_perms AS fp ON (fp.forum_id=f.id AND fp.group_id=3) WHERE (fp.read_forum IS NULL OR fp.read_forum=1) AND t.id=26877 AND t.moved_to IS NULL
0.00005 SELECT search_for, replace_with FROM punbb_censoring
0.00116 SELECT u.email, u.title, u.url, u.location, u.use_avatar, u.signature, u.email_setting, u.num_posts, u.registered, u.admin_note, p.id, p.poster AS username, p.poster_id, p.poster_ip, p.poster_email, p.message, p.hide_smilies, p.posted, p.edited, p.edited_by, g.g_id, g.g_user_title, o.user_id AS is_online FROM punbb_posts AS p INNER JOIN punbb_users AS u ON u.id=p.poster_id INNER JOIN punbb_groups AS g ON g.g_id=u.group_id LEFT JOIN punbb_online AS o ON (o.user_id=u.id AND o.user_id!=1 AND o.idle=0) WHERE p.topic_id=26877 ORDER BY p.id LIMIT 0,25
0.00075 UPDATE punbb_topics SET num_views=num_views+1 WHERE id=26877
Total query time: 0.00462 s