Arch --- pacman指南
帮助
https://wiki.archlinux.org/index.php/Pacman_%28%E7%AE%80%E4%BD%93%E4%B8%AD%E6%96%87%29
https://wiki.archlinux.org/index.php/Pacman_tips_%28%E7%AE%80%E4%BD%93%E4%B8%AD%E6%96%87%29
man pacman
用法
pacman <operation> [options] [targets]
<operation>
-D, --database
-Q, --query
-R, --remove
-S, --sync
-T, --deptest
-U, --upgrade
-V, --version
-h, --help
<options>
-b, --dbpath <full path>
-r, --root <path>
-v, --verbose
--arch <arch>
--cachedir <dir>
--color <file>
--config <file>
--debug
--gpgdir <dir>
--logfile <full path>
--noconfirm
<TRANSACTION OPTIONS> [-S, -R, -U]
-d, --nodeps
--dbonly
--noprogressbar
--noscriptlet
--p, --print
--print-format <format>
<UPGRADE OPTIONS>
--force
--asdeps
--asexplicit
--ignore <package>
--ignoregroup <group>
--needed
<QUERY OPTIONS>
-c, --changelog
-d, --deps
-e, --explcit
-g, --groups
-i, --info
-k, --check
-l, --list
-m, --foreign
-n, --native
-o, --owns <file>
-p, --file
-q, --quite
-s, --search <regexp>
-t, --unrequired
-u, --upgrades
<REMOVE OPTIONS>
-c, --cascade
-n, --nosave
-s, --recursive
-u, --nneeded
<SYNC OPTIONS>
-c, --clean
-g, --groups
-i, --info
-l, --list
-q, --quite
-s, --search <regexp>
-u, --sysupgrade
-w, --downloadonly
-y, --refresh
pacman 配置文件 /etc/pacman.conf
DBPath ---- /var/lib/pacman/
CacheDir ---- /var/cache/pacman/pkg/
LogFile ---- /var/log/pacman.log
GPGDir ---- /etc/pacman.d/gnupg
Mirrorlist ---- /etc/pacman.d/mirrorlist
删除软件包
pacman -R ---- 删除软件包(删除单个软件包,保留其全部已经安装的依赖关系)
pacman -Rs ---- 删除软件包(保留与其他已安装软件存在依赖的包)
pacman -Rsc ---- 删除软件包(及所有的依赖,此操作是递归的,可能会删除大量的软件包)
pacman -Rn
pacman -Rsn
同步软件包
pacman -S --help ---- 查询远程同步的数据库
pacman -S package_name ---- 安装多个软件包(空格分开)
pacman -Ss package_name ---- 在包数据库中查询软件包
pacman -Si package_name ---- 显示软件包信息
pacman -Sc ---- 清理软件包缓存
pacman -Su ---- 更新已安装的旧数据包
pacman -Syyu ---- 强制数据库更新和升级
pacman -Syy ---- 更新数据库
pacman -Syu ---- 升级整个系统(滚动升级)
pacman -Sw package_name ---- 下载包不安装包
pacman -Sgl package_group ---- 查看分组包
pacman -S package_group ---- 安装分组包
查询软件包
pacman -Q --help ---- 查询本地软件包数据库
pacman -Qs package_name ---- 查询已安装的软件包
pacman -Qi package_name ---- 显示已安装软件包的信息
pacman -Qii package_name ---- 显示已安装包的备份文件与修改状态
pacman -Ql package_name ---- 获取以安装软件包所包含的文件列表
pacman -Qu ---- 识别旧版本,尝试升级
pacman -Ql openssh | grep bin
更新数据包
pacman -U /path/to/pack.pkg.tar.xz ---- 安装一个本地包
pacman -U http://demo/pack.tar.xz ---- 安装远程的包
pkgfile -l package_name ---- 查看某个包的文件列表(未安装包)
pactree package_name ---- 显示软件包的以来树
[root@core share]# pacman -Qii pacman
Name : pacman
Version : 4.2.0-6
Description : A library-based package manager with dependency support
Architecture : x86_64
URL : http://www.archlinux.org/pacman/
Licenses : GPL
Groups : base base-devel
Provides : pacman-contrib
Depends On : bash glibc libarchive>=3.1.2 curl>=7.39.0 gpgme pacman-mirrorlist archlinux-keyring
Optional Deps : None
Required By : package-query yaourt
Optional For : None
Conflicts With : pacman-contrib
Replaces : pacman-contrib
Installed Size : 4.22 MiB
Packager : Allan McRae <allan@archlinux.org>
Build Date : Mon 12 Jan 2015 05:44:40 AM UTC
Install Date : Sun 25 Jan 2015 12:05:32 PM UTC
Install Reason : Explicitly installed
Install Script : No
Validated By : Signature
Backup Files:
MODIFIED /etc/pacman.conf
UNMODIFIED /etc/makepkg.conf
[root@core share]# pacman -Ql pacman | grep bin
pacman /usr/bin/
pacman /usr/bin/bacman
pacman /usr/bin/checkupdates
pacman /usr/bin/cleanupdelta
pacman /usr/bin/makepkg
pacman /usr/bin/makepkg-template
pacman /usr/bin/paccache
pacman /usr/bin/pacdiff
pacman /usr/bin/paclist
pacman /usr/bin/paclog-pkglist
pacman /usr/bin/pacman
pacman /usr/bin/pacman-db-upgrade
pacman /usr/bin/pacman-key
pacman /usr/bin/pacman-optimize
pacman /usr/bin/pacscripts
pacman /usr/bin/pacsearch
pacman /usr/bin/pacsort
pacman /usr/bin/pactree
pacman /usr/bin/pkgdelta
pacman /usr/bin/rankmirrors
pacman /usr/bin/repo-add
pacman /usr/bin/repo-elephant
pacman /usr/bin/repo-remove
pacman /usr/bin/testdb
pacman /usr/bin/testpkg
pacman /usr/bin/updpkgsums
pacman /usr/bin/vercmp
pacman
├─bash
│ ├─readline
│ │ ├─glibc
│ │ │ ├─linux-api-headers
│ │ │ ├─tzdata
│ │ │ └─filesystem
│ │ │ └─iana-etc
│ │ └─ncurses
│ │ ├─glibc
│ │ ├─gcc-libs
│ │ │ └─glibc
│ │ └─bash provides sh
│ └─glibc
├─glibc
├─libarchive
│ ├─acl
│ │ └─attr
│ │ └─glibc
│ ├─attr
│ ├─bzip2
│ │ └─glibc
│ ├─expat
│ │ └─glibc
│ ├─lzo
│ │ └─glibc
│ ├─openssl
│ │ ├─zlib
│ │ │ └─glibc
│ │ └─perl
│ │ ├─gdbm
│ │ │ ├─glibc
│ │ │ └─bash provides sh
│ │ ├─db
│ │ │ ├─gcc-libs
│ │ │ └─bash provides sh
│ │ └─glibc
│ ├─xz
│ │ └─bash provides sh
│ └─zlib
├─curl
│ ├─ca-certificates
│ │ ├─ca-certificates-mozilla
│ │ │ └─ca-certificates-utils
│ │ │ ├─bash
│ │ │ ├─coreutils
│ │ │ │ ├─glibc
│ │ │ │ ├─pam
│ │ │ │ │ ├─glibc
│ │ │ │ │ ├─cracklib
│ │ │ │ │ │ ├─glibc
│ │ │ │ │ │ └─zlib
│ │ │ │ │ ├─libtirpc
│ │ │ │ │ │ └─krb5
│ │ │ │ │ │ ├─e2fsprogs
│ │ │ │ │ │ │ ├─bash provides sh
│ │ │ │ │ │ │ └─libutil-linux
│ │ │ │ │ │ ├─libldap
│ │ │ │ │ │ │ ├─libsasl
│ │ │ │ │ │ │ │ └─openssl
│ │ │ │ │ │ │ └─e2fsprogs
│ │ │ │ │ │ └─keyutils
│ │ │ │ │ │ ├─glibc
│ │ │ │ │ │ └─bash provides sh
│ │ │ │ │ └─pambase
│ │ │ │ ├─acl
│ │ │ │ ├─gmp
│ │ │ │ │ ├─gcc-libs
│ │ │ │ │ └─bash provides sh
│ │ │ │ ├─libcap
│ │ │ │ │ ├─glibc
│ │ │ │ │ └─attr
│ │ │ │ └─openssl
│ │ │ ├─findutils
│ │ │ │ ├─glibc
│ │ │ │ └─bash provides sh
│ │ │ └─p11-kit
│ │ │ ├─glibc
│ │ │ ├─libtasn1
│ │ │ │ ├─glibc
│ │ │ │ └─texinfo
│ │ │ │ ├─ncurses
│ │ │ │ ├─findutils
│ │ │ │ ├─gzip
│ │ │ │ │ ├─glibc
│ │ │ │ │ ├─bash
│ │ │ │ │ └─less
│ │ │ │ │ ├─glibc
│ │ │ │ │ ├─ncurses
│ │ │ │ │ └─pcre
│ │ │ │ │ ├─gcc-libs
│ │ │ │ │ ├─readline
│ │ │ │ │ ├─zlib
│ │ │ │ │ ├─bzip2
│ │ │ │ │ └─bash
│ │ │ │ ├─perl
│ │ │ │ └─bash provides sh
│ │ │ └─libffi
│ │ │ └─glibc
│ │ └─ca-certificates-cacert
│ │ └─ca-certificates-utils
│ ├─krb5
│ ├─libssh2
│ │ └─openssl
│ ├─libidn
│ │ ├─glibc
│ │ └─texinfo
│ ├─openssl
│ └─zlib
├─gpgme
│ ├─libgpg-error
│ │ ├─glibc
│ │ └─bash provides sh
│ ├─pth
│ │ ├─glibc
│ │ └─gawk provides awk
│ │ ├─bash provides sh
│ │ ├─glibc
│ │ └─mpfr
│ │ └─gmp
│ └─gnupg
│ ├─npth
│ ├─libgpg-error
│ ├─libgcrypt
│ │ └─libgpg-error
│ ├─libksba
│ │ ├─bash
│ │ ├─libgpg-error
│ │ └─glibc
│ ├─libidn
│ │ ├─glibc
│ │ └─texinfo
│ ├─openssl
│ └─zlib
├─gpgme
│ ├─libgpg-error
│ │ ├─glibc
│ │ └─bash provides sh
│ ├─pth
│ │ ├─glibc
│ │ └─gawk provides awk
│ │ ├─bash provides sh
│ │ ├─glibc
│ │ └─mpfr
│ │ └─gmp
│ └─gnupg
│ ├─npth
│ ├─libgpg-error
│ ├─libgcrypt
│ │ └─libgpg-error
│ ├─libksba
│ │ ├─bash
│ │ ├─libgpg-error
│ │ └─glibc
│ ├─libassuan
│ │ └─libgpg-error
│ ├─pinentry
│ │ ├─ncurses
│ │ └─libcap
│ ├─bzip2
│ ├─readline
│ └─gnutls
│ ├─gcc-libs
│ ├─libidn
│ ├─libtasn1
│ ├─readline
│ ├─zlib
│ ├─nettle
│ │ └─gmp
│ └─p11-kit
├─pacman-mirrorlist
└─archlinux-keyring
[notfound@core share]$ bacman zip
==> Entering fakeroot environment
==> Package: zip-3.0-6
-> Copying package files...
-> Generating .PKGINFO metadata...
-> Generating the package...
==> Done.
帮助
https://wiki.archlinux.org/index.php/Pacman_%28%E7%AE%80%E4%BD%93%E4%B8%AD%E6%96%87%29
https://wiki.archlinux.org/index.php/Pacman_tips_%28%E7%AE%80%E4%BD%93%E4%B8%AD%E6%96%87%29
man pacman
用法
pacman <operation> [options] [targets]
<operation>
-D, --database
-Q, --query
-R, --remove
-S, --sync
-T, --deptest
-U, --upgrade
-V, --version
-h, --help
<options>
-b, --dbpath <full path>
-r, --root <path>
-v, --verbose
--arch <arch>
--cachedir <dir>
--color <file>
--config <file>
--debug
--gpgdir <dir>
--logfile <full path>
--noconfirm
<TRANSACTION OPTIONS> [-S, -R, -U]
-d, --nodeps
--dbonly
--noprogressbar
--noscriptlet
--p, --print
--print-format <format>
<UPGRADE OPTIONS>
--force
--asdeps
--asexplicit
--ignore <package>
--ignoregroup <group>
--needed
<QUERY OPTIONS>
-c, --changelog
-d, --deps
-e, --explcit
-g, --groups
-i, --info
-k, --check
-l, --list
-m, --foreign
-n, --native
-o, --owns <file>
-p, --file
-q, --quite
-s, --search <regexp>
-t, --unrequired
-u, --upgrades
<REMOVE OPTIONS>
-c, --cascade
-n, --nosave
-s, --recursive
-u, --nneeded
<SYNC OPTIONS>
-c, --clean
-g, --groups
-i, --info
-l, --list
-q, --quite
-s, --search <regexp>
-u, --sysupgrade
-w, --downloadonly
-y, --refresh
pacman 配置文件 /etc/pacman.conf
DBPath ---- /var/lib/pacman/
CacheDir ---- /var/cache/pacman/pkg/
LogFile ---- /var/log/pacman.log
GPGDir ---- /etc/pacman.d/gnupg
Mirrorlist ---- /etc/pacman.d/mirrorlist
删除软件包
pacman -R ---- 删除软件包(删除单个软件包,保留其全部已经安装的依赖关系)
pacman -Rs ---- 删除软件包(保留与其他已安装软件存在依赖的包)
pacman -Rsc ---- 删除软件包(及所有的依赖,此操作是递归的,可能会删除大量的软件包)
pacman -Rn
pacman -Rsn
同步软件包
pacman -S --help ---- 查询远程同步的数据库
pacman -S package_name ---- 安装多个软件包(空格分开)
pacman -Ss package_name ---- 在包数据库中查询软件包
pacman -Si package_name ---- 显示软件包信息
pacman -Sc ---- 清理软件包缓存
pacman -Su ---- 更新已安装的旧数据包
pacman -Syyu ---- 强制数据库更新和升级
pacman -Syy ---- 更新数据库
pacman -Syu ---- 升级整个系统(滚动升级)
pacman -Sw package_name ---- 下载包不安装包
pacman -Sgl package_group ---- 查看分组包
pacman -S package_group ---- 安装分组包
查询软件包
pacman -Q --help ---- 查询本地软件包数据库
pacman -Qs package_name ---- 查询已安装的软件包
pacman -Qi package_name ---- 显示已安装软件包的信息
pacman -Qii package_name ---- 显示已安装包的备份文件与修改状态
pacman -Ql package_name ---- 获取以安装软件包所包含的文件列表
pacman -Qu ---- 识别旧版本,尝试升级
pacman -Ql openssh | grep bin
更新数据包
pacman -U /path/to/pack.pkg.tar.xz ---- 安装一个本地包
pacman -U http://demo/pack.tar.xz ---- 安装远程的包
pkgfile -l package_name ---- 查看某个包的文件列表(未安装包)
pactree package_name ---- 显示软件包的以来树
[root@core share]# pacman -Qii pacman
Name : pacman
Version : 4.2.0-6
Description : A library-based package manager with dependency support
Architecture : x86_64
URL : http://www.archlinux.org/pacman/
Licenses : GPL
Groups : base base-devel
Provides : pacman-contrib
Depends On : bash glibc libarchive>=3.1.2 curl>=7.39.0 gpgme pacman-mirrorlist archlinux-keyring
Optional Deps : None
Required By : package-query yaourt
Optional For : None
Conflicts With : pacman-contrib
Replaces : pacman-contrib
Installed Size : 4.22 MiB
Packager : Allan McRae <allan@archlinux.org>
Build Date : Mon 12 Jan 2015 05:44:40 AM UTC
Install Date : Sun 25 Jan 2015 12:05:32 PM UTC
Install Reason : Explicitly installed
Install Script : No
Validated By : Signature
Backup Files:
MODIFIED /etc/pacman.conf
UNMODIFIED /etc/makepkg.conf
[root@core share]# pacman -Ql pacman | grep bin
pacman /usr/bin/
pacman /usr/bin/bacman
pacman /usr/bin/checkupdates
pacman /usr/bin/cleanupdelta
pacman /usr/bin/makepkg
pacman /usr/bin/makepkg-template
pacman /usr/bin/paccache
pacman /usr/bin/pacdiff
pacman /usr/bin/paclist
pacman /usr/bin/paclog-pkglist
pacman /usr/bin/pacman
pacman /usr/bin/pacman-db-upgrade
pacman /usr/bin/pacman-key
pacman /usr/bin/pacman-optimize
pacman /usr/bin/pacscripts
pacman /usr/bin/pacsearch
pacman /usr/bin/pacsort
pacman /usr/bin/pactree
pacman /usr/bin/pkgdelta
pacman /usr/bin/rankmirrors
pacman /usr/bin/repo-add
pacman /usr/bin/repo-elephant
pacman /usr/bin/repo-remove
pacman /usr/bin/testdb
pacman /usr/bin/testpkg
pacman /usr/bin/updpkgsums
pacman /usr/bin/vercmp
pacman
├─bash
│ ├─readline
│ │ ├─glibc
│ │ │ ├─linux-api-headers
│ │ │ ├─tzdata
│ │ │ └─filesystem
│ │ │ └─iana-etc
│ │ └─ncurses
│ │ ├─glibc
│ │ ├─gcc-libs
│ │ │ └─glibc
│ │ └─bash provides sh
│ └─glibc
├─glibc
├─libarchive
│ ├─acl
│ │ └─attr
│ │ └─glibc
│ ├─attr
│ ├─bzip2
│ │ └─glibc
│ ├─expat
│ │ └─glibc
│ ├─lzo
│ │ └─glibc
│ ├─openssl
│ │ ├─zlib
│ │ │ └─glibc
│ │ └─perl
│ │ ├─gdbm
│ │ │ ├─glibc
│ │ │ └─bash provides sh
│ │ ├─db
│ │ │ ├─gcc-libs
│ │ │ └─bash provides sh
│ │ └─glibc
│ ├─xz
│ │ └─bash provides sh
│ └─zlib
├─curl
│ ├─ca-certificates
│ │ ├─ca-certificates-mozilla
│ │ │ └─ca-certificates-utils
│ │ │ ├─bash
│ │ │ ├─coreutils
│ │ │ │ ├─glibc
│ │ │ │ ├─pam
│ │ │ │ │ ├─glibc
│ │ │ │ │ ├─cracklib
│ │ │ │ │ │ ├─glibc
│ │ │ │ │ │ └─zlib
│ │ │ │ │ ├─libtirpc
│ │ │ │ │ │ └─krb5
│ │ │ │ │ │ ├─e2fsprogs
│ │ │ │ │ │ │ ├─bash provides sh
│ │ │ │ │ │ │ └─libutil-linux
│ │ │ │ │ │ ├─libldap
│ │ │ │ │ │ │ ├─libsasl
│ │ │ │ │ │ │ │ └─openssl
│ │ │ │ │ │ │ └─e2fsprogs
│ │ │ │ │ │ └─keyutils
│ │ │ │ │ │ ├─glibc
│ │ │ │ │ │ └─bash provides sh
│ │ │ │ │ └─pambase
│ │ │ │ ├─acl
│ │ │ │ ├─gmp
│ │ │ │ │ ├─gcc-libs
│ │ │ │ │ └─bash provides sh
│ │ │ │ ├─libcap
│ │ │ │ │ ├─glibc
│ │ │ │ │ └─attr
│ │ │ │ └─openssl
│ │ │ ├─findutils
│ │ │ │ ├─glibc
│ │ │ │ └─bash provides sh
│ │ │ └─p11-kit
│ │ │ ├─glibc
│ │ │ ├─libtasn1
│ │ │ │ ├─glibc
│ │ │ │ └─texinfo
│ │ │ │ ├─ncurses
│ │ │ │ ├─findutils
│ │ │ │ ├─gzip
│ │ │ │ │ ├─glibc
│ │ │ │ │ ├─bash
│ │ │ │ │ └─less
│ │ │ │ │ ├─glibc
│ │ │ │ │ ├─ncurses
│ │ │ │ │ └─pcre
│ │ │ │ │ ├─gcc-libs
│ │ │ │ │ ├─readline
│ │ │ │ │ ├─zlib
│ │ │ │ │ ├─bzip2
│ │ │ │ │ └─bash
│ │ │ │ ├─perl
│ │ │ │ └─bash provides sh
│ │ │ └─libffi
│ │ │ └─glibc
│ │ └─ca-certificates-cacert
│ │ └─ca-certificates-utils
│ ├─krb5
│ ├─libssh2
│ │ └─openssl
│ ├─libidn
│ │ ├─glibc
│ │ └─texinfo
│ ├─openssl
│ └─zlib
├─gpgme
│ ├─libgpg-error
│ │ ├─glibc
│ │ └─bash provides sh
│ ├─pth
│ │ ├─glibc
│ │ └─gawk provides awk
│ │ ├─bash provides sh
│ │ ├─glibc
│ │ └─mpfr
│ │ └─gmp
│ └─gnupg
│ ├─npth
│ ├─libgpg-error
│ ├─libgcrypt
│ │ └─libgpg-error
│ ├─libksba
│ │ ├─bash
│ │ ├─libgpg-error
│ │ └─glibc
│ ├─libidn
│ │ ├─glibc
│ │ └─texinfo
│ ├─openssl
│ └─zlib
├─gpgme
│ ├─libgpg-error
│ │ ├─glibc
│ │ └─bash provides sh
│ ├─pth
│ │ ├─glibc
│ │ └─gawk provides awk
│ │ ├─bash provides sh
│ │ ├─glibc
│ │ └─mpfr
│ │ └─gmp
│ └─gnupg
│ ├─npth
│ ├─libgpg-error
│ ├─libgcrypt
│ │ └─libgpg-error
│ ├─libksba
│ │ ├─bash
│ │ ├─libgpg-error
│ │ └─glibc
│ ├─libassuan
│ │ └─libgpg-error
│ ├─pinentry
│ │ ├─ncurses
│ │ └─libcap
│ ├─bzip2
│ ├─readline
│ └─gnutls
│ ├─gcc-libs
│ ├─libidn
│ ├─libtasn1
│ ├─readline
│ ├─zlib
│ ├─nettle
│ │ └─gmp
│ └─p11-kit
├─pacman-mirrorlist
└─archlinux-keyring
[notfound@core share]$ bacman zip
==> Entering fakeroot environment
==> Package: zip-3.0-6
-> Copying package files...
-> Generating .PKGINFO metadata...
-> Generating the package...
==> Done.