mport — mport
package manager
mport |
[-v] [-c ⟨chroot
path⟩] [-f] [-o
⟨output path⟩] [-q]
[-V] ⟨command⟩ |
mport |
annotate [-A]
[-S] [-D]
[-a] [-q]
[name] [tag] |
mport |
config get [setting
name] |
mport |
config set [setting name]
[setting value] |
mport |
download [-d]
[name] |
mport |
install [-A]
[-M] [name] |
The mport command installs or removes
mport packages, and displays information on installed packages.
The following options are supported by
mport:
-v,
--version
- Display the current version of
mport.
-c
⟨chroot path⟩, --chroot ⟨chroot
path⟩
mport will chroot in the ⟨chroot
path⟩
-q,
--quiet
- Make output less verbose and hide download progress.
-V,
--verbose
- Make output more verbose.
-f,
--force
- Force the operation. Supported for install and delete currently.
-o
⟨output path⟩, --output ⟨output
path⟩
mport will download packages into the
⟨output path⟩
The following commands are supported by
mport:
add
⟨name⟩
- Installs a local package file and also attempts to install any missing
dependencies in the path specified. For online installs, use mport install
instead.
-A,
-S, -D,
-a, -q,
annotate ⟨name⟩
⟨tag⟩
- Add (A), Show (S), or Delete (D) an annotation tag for a package. The q
flag shows abbreviated output for use in scripts. The a flag allows you to
operate on all installed packages.
audit
- Displays vulnerable packages installed on the system. Uses CPE data to
match against a NVD feed provided by the MidnightBSD project.
autoremove
- Experimental! Removes all packages installed as dependencies that are no
longer needed as the original package depending on them has been
removed.
clean
- Clean up old packages not found in the index and perform maintenence on
the database.
config
get ⟨name⟩
- Displays the value of a configuration setting
config
set ⟨name⟩ ⟨value⟩
- Sets the value of the configuration setting.
cpe
- List all CPE information for each installed package
cpe
⟨name⟩
- List CPE information for a specific package
list
- List all currently installed packages
list
updates
- List currently installed packages with updates available
list
prime
- List all packages explicitly installed rather than as a dependency
info
⟨name⟩
- Print detailed information about a package
delete
⟨name⟩
- Delete or uninstall a package
deleteall
- Delete or uninstall all packages on the system. Useful for major OS
upgrades, or testing.
download
⟨name⟩
- Download a package, but do not install it. Useful for later offline
installations. The d flag will allow it to download dependencies as
well.
index
- Force a download of the index to refresh it without waiting for the
timeout interval. This allows the user to get the latest list of
packages.
install
-A -M
⟨name⟩
- Fetch and install a package. With the A flag set, marks the installed
packages as automatic. Will be automatically removed if no other packages
depend on them. With the M flag set, will ignore missing dependencies and
attempt to install the package anyway.
mirror
list
- Lists all available package mirrors.
mirror
select
- Pings various mirrors to attempt to select the closest and sets it as
default.
purl
- Lists PURL for each installed package Lists PURL for a specific
package
search
- Search package names and descriptions. Supports globbing queries such as
"*php*".
shell
- Starts a sqlite3 client connected to the mport master database.
stats
- List statistics about available and installed packages.
update
⟨name⟩
- Fetch and update a specific package
upgrade
- Upgrade all currently installed packages with the latest version
verify
-r ⟨name⟩
- Verify currently installed packages have not had files deleted or modified
from the original installation. The r flag will attempt recompute the
checksum of the installed files. This is useful if the user modified files
and wants to verify the package is still valid. A large number of files
with invalid checksums may indicate a security issue or corrupted
package.
The mport command has the following
settings that modify it's behavior:
mirror_region
Determines which mirror region to use to fetch packages. Valid values are
currently us, us2, us3, uk, jp The current list is always available in the
mport index file in /var/db/mport/index.db in the mirrors table
target_os
Override the OS version used to fetch packages and install them. If undefined,
we try /bin/midnightbsd-version first and fall back to the running kernel
version.
index_last_check
This is the last time the index file was checked for an update.
index_autoupdate
Determines if the index file will be updated automatically. If set to NO or
FALSE, it will be skipped unless it is missing entirely. A persistent version
of the mport -U flag.
handle_rc_scripts
When set to yes or true, will start and stop rc.d services included with the
package. If set to no or false, will not run rc.d scripts.
FETCH_BIND_ADDRESS
- Specifies a hostname or IP address to which sockets used for outgoing
connections will be bound.
FTP_LOGIN
- Default FTP login if none was provided in the URL.
FTP_PASSIVE_MODE
- If set to ‘
no’, forces the FTP code
to use active mode. If set to any other value, forces passive mode even if
the application requested active mode.
FTP_PASSWORD
- Default FTP password if the remote server requests one and none was
provided in the URL.
FTP_PROXY
- URL of the proxy to use for FTP requests. The document part is ignored.
FTP and HTTP proxies are supported; if no scheme is specified, FTP is
assumed. If the proxy is an FTP proxy,
ASSUME_ALWAYS_YES
- If set to a non empty value, will assume any question should be answered
with a yes.
HANDLE_RC_SCRIPTS
- If set to a non empty value, will start/stop rc.d scripts included in the
package.
Search for a package:
$ mport search curl
Install a package:
Installing must specify a unique
origin
% mport install curl
List installed packages:
$ mport list
Upgrade all installed packages:
% mport upgrade
Upgrade a single package:
% mport update gmake
List packages needing upgrades:
$ mport list updates
List non-automatic packages:
$ mport list prime
Delete an installed package:
% mport delete curl
Remove unneeded dependencies:
% mport autoremove
Determine which package installed a file:
$ mport which
/usr/local/bin/curl
Check installed packages for checksum mismatches:
# mport verify
Install a local package file:
$ mport add
/home/myuser/mypkg.mport
Search for all xfce related packages:
$ mport search xfce*
The mport command first appeared in
The mport utility and manual page were
written by Lucas Holt
⟨luke@MidnightBSD.org⟩.