File: linux-packaging.adoc

package info (click to toggle)
asciidoctor 2.0.26-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,464 kB
  • sloc: ruby: 45,298; sh: 147; xml: 53; javascript: 48; makefile: 26; ml: 1
file content (116 lines) | stat: -rw-r--r-- 3,681 bytes parent folder | download | duplicates (2)
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
= Install Using Linux Packaging
:url-alpine: https://pkgs.alpinelinux.org/packages?name=asciidoctor
:url-arch: https://www.archlinux.org/packages/?name=asciidoctor
:url-debian: https://packages.debian.org/sid/asciidoctor
:url-fedora: https://packages.fedoraproject.org/pkgs/rubygem-asciidoctor/rubygem-asciidoctor/
:url-suse: https://software.opensuse.org/package/rubygem-asciidoctor
:url-ubuntu: https://packages.ubuntu.com/search?keywords=asciidoctor

The benefit of using your operating system's package manager to install the gem is that it handles installing Ruby and the RubyGems library if those packages are not already installed on your machine.

== Package versions

The version of Asciidoctor installed by the package manager may not match the latest release of Asciidoctor.
Consult the package repository for your distribution to find out which version is packaged per distribution release.

* {url-alpine}[Alpine Linux (asciidoctor)^]
* {url-arch}[Arch Linux (asciidoctor)^]
* {url-debian}[Debian (asciidoctor)^]
* {url-fedora}[Fedora (asciidoctor)^]
* {url-suse}[openSUSE (rubygem-asciidoctor)^]
* {url-ubuntu}[Ubuntu (asciidoctor)^]

If you want to use a version of Asciidoctor that is newer than what is available via your package manager, see xref:ruby-packaging.adoc[].

== APT

On Debian and Debian-based distributions such as Ubuntu, use APT to install Asciidoctor.
To install the package, open a terminal and type:

 $ sudo apt-get install -y asciidoctor

include::partial$success.adoc[]

== DNF

On RPM-based Linux distributions, such as Fedora, CentOS, and RHEL, use the DNF package manager to install Asciidoctor.
To install the package, open a terminal and type:

 $ sudo dnf install -y asciidoctor

include::partial$success.adoc[]

[#apk]
== apk (Alpine Linux)

To install the gem on Alpine Linux, open a terminal and type:

 $ sudo apk add asciidoctor

include::partial$success.adoc[]

[#pacman]
== pacman (Arch Linux)

To install the gem on Arch Linux-based distributions, open a terminal and type:

 $ sudo pacman -S asciidoctor

include::partial$success.adoc[]

[#upgrade]
== Upgrade on Linux

Some Linux distributions may not have the latest stable version of Asciidoctor packaged immediately after a release of a new gem.
If you need to upgrade to the latest version immediately, use xref:ruby-packaging.adoc[gem install] instead of the package manager.

TIP: Your Linux system may be configured to automatically update packages, in which case the latest Asciidoctor package will be installed as soon as it becomes available.
No further action is required by you.

[#upgrade-apt]
=== APT

On Debian and Debian-based distributions, update the Asciidoctor package using:

 $ sudo apt-get upgrade -y asciidoctor

[#upgrade-dnf]
=== DNF

On Fedora and other RPM-based distributions, you can update the package using:

 $ sudo dnf update -y asciidoctor

[#upgrade-apk]
=== apk (Alpine Linux)

On Alpine Linux, update the Asciidoctor package using:

 $ sudo apk add -u asciidoctor

[#uninstall]
== Uninstall on Linux

To uninstall (i.e., remove) Asciidoctor using Linux packaging, you request your package manager to remove the Asciidoctor package.
The package manager will take care of removing all the necessary application files.

[#uninstall-apt]
=== APT

On Debian and Debian-based distributions, uninstall the Asciidoctor package using:

 $ sudo apt-get remove -y asciidoctor

[#uninstall-dnf]
=== DNF

On Fedora and other RPM-based distributions, you can uninstall the package using:

 $ sudo dnf remove -y asciidoctor

[#uninstall-apk]
=== apk (Alpine Linux)

On Alpine Linux, uninstall the Asciidoctor package using:

 $ sudo apk del asciidoctor