手抄报 安全手抄报 手抄报内容 手抄报图片 英语手抄报 清明节手抄报 节约用水手抄报

在Arch Linux中搜索一个包

时间:2024-10-24 17:10:17

1、如何用pacman搜索包?pacman的语法如下:pacman -Ss {pkgNameHere}pacman -Ss {keyWordHere}假如要搜索nmap包:$ pacman -Ss nmap或者是$ pacman -Ss auditing示例输出:extra/nmap 7.40-2 Utility for network discovery and security auditingcommunity/dsniff 2.4b1-26 Collection of tools for network auditing and penetration testingcommunity/lynis 2.4.8-1 Security and system auditing tool to harden Unix/Linux systemscommunity/perf 4.11-1 (linux-tools) Linux kernel performance auditing tool

2、如何使用pkgfile搜索包?pkgfile命令只不过是一个pacman .files元数据资源管理器。首先安装pkgfile,执行:$ sudo pacman -S pkgfile示例输出:

在Arch Linux中搜索一个包

3、键入以下命令来更新索引:$ sudo pkgfile --update示例输出::: Updating 3 repos... download complete: core [ 693.9 KiB 208K/s 2 remaining] download complete: extra [ 7.1 MiB 807K/s 1 remaining] download complete: community [ 15.5 MiB 48.6K/s 0 remaining]:: download complete in 325.94s < 23.2 MiB 73.0K/s 3 files >:: waiting for 1 process to finish repacking repos...

4、简单搜索键入命令:$ pkgfile nginx$ pkgfile php$ pkgfile nmap输出:extra/bash-completionextra/nmap

5、如何显示远程包提供的文件,即卸载包?语法是示:$ pkgfile -l packageName$ pkgfile -l nmap$ pkgfile -l bash示例输出:core / bash / etc /core / bash /etc/bash.bash_logoutcore / bash /etc/bash.bashrccore / bash / etc / skel /core / bash /etc/skel/.bash_logoutcore / bash /etc/skel/.bash_profilecore / bash /etc/skel/.bashrccore / bash / usr /core / bash / usr / bin /core / bash / usr / bin / bashcore / bash / usr / bin / bashbugcore / bash / usr / bin / shcore / bash / usr / include /core / bash / usr / include / bash /core / bash /usr/include/bash/alias.hcore / bash /usr/include/bash/array.hcore / bash /usr/include/bash/arrayfunc.hcore / bash /usr/include/bash/assoc.h...........core / bash / usr / share / locale / zh_CN / LC_MESSAGES /core / bash /usr/share/locale/zh_CN/LC_MESSAGES/bash.mocore / bash / usr / share / locale / zh_TW /core / bash / usr / share / locale / zh_TW / LC_MESSAGES /core / bash /usr/share/locale/zh_TW/LC_MESSAGES/bash.mocore / bash / usr / share / man /core / bash / usr / share / man / man1 /core / bash /usr/share/man/man1/bash.1.gzcore / bash /usr/share/man/man1/bashbug.1.gz要查看本地软件包提供的文件列表,请使用:$ pacman -Ql bash

6、如何执行与正则表达式的匹配?语法是:$ pkgfile -r regex$ pkgfile -r php*$ pkgfile -r nginx*查看所有其他选项语法为:$ pkgfile -h输出:pkgfile 17Usage: pkgfile [options] targetOperations: -l, --list list contents of a package -s, --search search for packages containing the target (default) -u, --update update repo files listsMatching: -b, --binaries return only files contained in a bin dir -d, --directories match directories in searches -g, --glob enable matching with glob characters -i, --ignorecase use case insensitive matching -R, --repo search a singular repo -r, --regex enable matching with regular expressionsOutput: -q, --quiet output less when listing -v, --verbose output more -w, --raw disable output justification -0, --null null terminate outputDownloading: -z, --compress[=type] compress downloaded reposGeneral: -C, --config use an alternate config (default: /etc/pacman.conf) -h, --help display this help and exit -V, --version display the version and exit

© 手抄报圈