aboutsummaryrefslogtreecommitdiff
path: root/man/cpt-alternatives.1
blob: 8196b4030d12fd6cf8a450fa411d245a39d61633 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
.Dd Feb 25, 2021
.Dt cpt-alternatives 1
.Sh NAME
.Nm cpt-alternatives
.Nd List and swap to alternatives
.Sh SYNOPSIS
.Nm cpt-alternatives
.Op Ar -
.Op Ar package file
.Sh USAGE
.Nm
can be used to either list or swap to alternatives, depending on the given
arguments:
.Bl -tag -offset indent -width 12n
.It Sy -
Swap to alternatives given on the standard input.
.It Sy none
List alternatives.
.It Sy pkg file
Swap to the alternative
.Sy file
from
.Sy pkg
.El
.Sh EXAMPLES
.Pp
Here are some sample commands to make it easier to understand how
.Nm
works.
.Ss LISTING ALTERNATIVES
.Pp
Calling
.Nm
without any arguments will print all available alternatives on your system.
.Bd -literal -offset indent
$ cpt-alternatives
ncurses /usr/bin/clear
ncurses /usr/bin/reset
.Ed
.Ss SWITCHING ALTERNATIVES
You can simply switch between alternatives by giving the name of the package and
the file as arguments.
.Bd -literal -offset indent
$ cpt-alternatives ncurses /usr/bin/clear
-> Swapping '/usr/bin/clear' from 'busybox' to 'ncurses'
.Ed
.Ss SWITCHING ALTERNATIVES IN BULK
There may be times where you want to change multiple alternatives at once. Here
is an example for using all alternatives from the package
.Sy sbase .
.Bd -literal -offset indent
$ cpt-alternatives | grep ^sbase | cpt-alternatives -
.Ed
.Sh AUTHOR
.An Cem Keylan Aq Mt cem@ckyln.com
.Sh LICENSE
See LICENSE for copyright information.
.Sh SEE ALSO
.Xr cpt 1