aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatarUnit 193 <unit193@ubuntu.com>2018-08-28 19:55:01 -0400
committerLibravatarUnit 193 <unit193@ubuntu.com>2018-08-28 19:55:01 -0400
commit9729ee4cc92e67fd41509505f90f2487236689f7 (patch)
tree9f73a619018c6ce302a563c1b67e63769fdfc0bb
parent1f2387b88802d6eef8e69c3daf67d625a8a052f5 (diff)
downloadarch-install-scripts-9729ee4cc92e67fd41509505f90f2487236689f7.tar.bz2
arch-install-scripts-9729ee4cc92e67fd41509505f90f2487236689f7.tar.xz
arch-install-scripts-9729ee4cc92e67fd41509505f90f2487236689f7.tar.zst
d/arch-chroot.adoc, d/control, d/genfstab.adoc, d/manpages, d/rules: Write manpages for the scripts and use asciidoctor to generate final output.
-rw-r--r--debian/arch-chroot.adoc63
-rw-r--r--debian/control2
-rw-r--r--debian/genfstab.adoc46
-rw-r--r--debian/manpages2
-rwxr-xr-xdebian/rules8
5 files changed, 120 insertions, 1 deletions
diff --git a/debian/arch-chroot.adoc b/debian/arch-chroot.adoc
new file mode 100644
index 0000000..61ecdbb
--- /dev/null
+++ b/debian/arch-chroot.adoc
@@ -0,0 +1,63 @@
+arch-chroot(1)
+==============
+:doctype: manpage
+
+NAME
+----
+arch-chroot - script to mount API filesystems like /proc and make /etc/resolv.conf available in a chroot
+
+
+SYNOPSIS
+--------
+*arch-chroot* ['option'] 'chroot-dir' ['command']
+
+
+OPTIONS
+-------
+*-h*::
+ Print the help message
+
+*-u* '<user>[:group]'::
+ Specify non-root user and optional group to use
+
+
+DESCRIPTION
+-----------
+Before *arch-chroot* runs */usr/bin/chroot*, the script mounts API filesystems
+like '/proc' and makes '/etc/resolv.conf' available in a chroot.
+
+The Debian version of this script also sets up '/usr/sbin/policy-rc.d' to
+disable autostart of daemons.
+
+If 'command' is unspecified, arch-chroot will launch */bin/bash*.
+
+
+EXAMPLES
+--------
+=== Enter a chroot ===
+
+Run arch-chroot with the new root directory as first argument:
+
+```
+arch-chroot /location/of/new/root
+```
+
+To exit the chroot simply use:
+
+```
+exit
+```
+
+=== Run a single command and exit ===
+
+To run a command in the chroot and exit again, append the command to the end of the line:
+
+```
+arch-chroot /location/of/new/root command
+```
+
+For example, to run *dpkg-configure -a* for a chroot located at '/media/testing' do:
+
+```
+arch-chroot /media/testing dpkg-configure -a
+```
diff --git a/debian/control b/debian/control
index d60abe2..2f20da1 100644
--- a/debian/control
+++ b/debian/control
@@ -2,7 +2,7 @@ Source: arch-install-scripts
Section: admin
Priority: optional
Maintainer: Unit 193 <unit193@ubuntu.com>
-Build-Depends: debhelper (>= 10), m4
+Build-Depends: debhelper (>= 10), asciidoctor, m4
Standards-Version: 4.1.3
Homepage: https://projects.archlinux.org/arch-install-scripts.git
diff --git a/debian/genfstab.adoc b/debian/genfstab.adoc
new file mode 100644
index 0000000..9f2f35e
--- /dev/null
+++ b/debian/genfstab.adoc
@@ -0,0 +1,46 @@
+genfstab(1)
+===========
+:doctype: manpage
+
+NAME
+----
+genfstab - script to generate an fstab file based on mounted partitions
+
+
+SYNOPSIS
+--------
+*genfstab* ['options'] 'root'
+
+
+OPTIONS
+-------
+*-f* 'FILTER'::
+ Restrict output to mountpoints matching the prefix FILTER
+*-L*::
+ Use labels for source identifiers (shortcut for '-t LABEL')
+*-p*::
+ Exclude pseudofs mounts (default behavior)
+*-P*::
+ Include pseudofs mounts
+*-t* 'TAG'::
+ Use TAG for source identifiers
+*-U*::
+ Use UUIDs for source identifiers (shortcut for '-t UUID')
+*-h*::
+ Print the help message
+
+
+DESCRIPTION
+-----------
+One can use genfstab to generate fstab entries for mounted partitions given a filesystem root.
+This can be useful when installing or chrooting into a broken installation.
+
+
+EXAMPLES
+--------
+
+To generate an fstab file using UUIDs as identifiers, run:
+
+```
+genfstab -U /media/testing >> /media/testing/etc/fstab
+```
diff --git a/debian/manpages b/debian/manpages
new file mode 100644
index 0000000..cc0dedd
--- /dev/null
+++ b/debian/manpages
@@ -0,0 +1,2 @@
+debian/arch-chroot.1
+debian/genfstab.1
diff --git a/debian/rules b/debian/rules
index 63ff2c5..e146889 100755
--- a/debian/rules
+++ b/debian/rules
@@ -9,3 +9,11 @@
override_dh_auto_install:
make PREFIX=/usr DESTDIR="$(CURDIR)/debian/arch-install-scripts" install
-rm debian/arch-install-scripts/usr/bin/pacstrap
+
+override_dh_installman:
+ asciidoctor --backend manpage debian/arch-chroot.adoc
+ asciidoctor --backend manpage debian/genfstab.adoc
+ dh_installman
+
+override_dh_clean:
+ dh_clean debian/arch-chroot.1 debian/genfstab.1