Skip to content

Commit

Permalink
big rework, prepare sources for multiple variants of handbook
Browse files Browse the repository at this point in the history
  • Loading branch information
sighook committed Dec 18, 2023
1 parent b6b7550 commit 265b6db
Show file tree
Hide file tree
Showing 24 changed files with 294 additions and 608 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ all: help
help:

pod:
perl -0pe 's/\R?$$/\n\n/' ${SRC} | sed '/^# vim: .*/d' > ${POD}
perl -0pe 's/\R?$$/\n\n/' src/*.pod | sed '/^# vim: .*/d' > ${POD}

man: pod
pod2man -r "${NAME} ${VERSION}" -c "${DESCRIPTION}" \
Expand Down
6 changes: 6 additions & 0 deletions src/1. PREFACE.pod
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
=head1 1. PREFACE

This handbook (and Zeppe-Lin itself) is inspired and based on the
L<CRUX Handbook|http://crux.nu/Main/Documentation>.

=cut
68 changes: 0 additions & 68 deletions src/2. INTRODUCTION.pod
Original file line number Diff line number Diff line change
@@ -1,69 +1 @@
=head1 2. INTRODUCTION

=begin html

<img alt="Zeppe-Lin" class="logo" src="https://github.com/zeppe-lin/artwork/blob/master/logo-small.png?raw=true" />

=end html

This handbook (and Zeppe-Lin itself) is inspired and based on the
L<CRUX Handbook|http://crux.nu/Main/Documentation>.

=begin html

It is also available on the Zeppe-Lin system as a
<a href="https://github.com/zeppe-lin/handbook">handbook(7)</a>
manual page.

=end html

=begin comment

=head2 2.1. What is Zeppe-Lin?

=end comment

Zeppe-Lin is a lightweight GNU/Linux distribution for the x86-64
architecture targeted at experienced users. It is forked from CRUX
and the primary focus of this distribution is "keep it simple" too.

The KISS principle reflects in a simple I<tar.gz>-based package
system, BSD-style init scripts, and a relatively small collection of
trimmed packages.

The secondary focus is the utilization of new GNU/Linux features and
recent tools and libraries.

=begin comment

=head2 2.2. Why use Zeppe-Lin?

In short, B<Zeppe-Lin> might suit you very well if you are:

=over

=item *

an experienced user who wants a clean and simple GNU/Linux
distribution as a foundation of your installation;

=item *

a person who prefers editing configuration files with an editor to
using GUI;

=item *

someone who does not hesitate to download and compile programs from
the source;

=item *

someone who wants a KISS GNU/Linux distribution as a foundation of
your own distro;

=back

=end comment

=cut
14 changes: 14 additions & 0 deletions src/2.1. What is Zeppe-Lin?.pod
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
=head2 2.1. What is Zeppe-Lin?

Zeppe-Lin is a lightweight GNU/Linux distribution for the x86-64
architecture targeted at experienced users. It is forked from CRUX
and the primary focus of this distribution is "keep it simple" too.

The KISS principle reflects in a simple I<tar.gz>-based package
system, BSD-style init scripts, and a relatively small collection of
trimmed packages.

The secondary focus is the utilization of new GNU/Linux features and
recent tools and libraries.

=cut
29 changes: 29 additions & 0 deletions src/2.2. Why use Zeppe-Lin?.pod
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
=head2 2.2. Why use Zeppe-Lin?

In short, B<Zeppe-Lin> might suit you very well if you are:

=over 3

=item *

an experienced user who wants a clean and simple GNU/Linux
distribution as a foundation of your installation;

=item *

a person who prefers editing configuration files with an editor to
using GUI;

=item *

someone who does not hesitate to download and compile programs from
the source;

=item *

someone who wants a KISS GNU/Linux distribution as a foundation of
your own distro;

=back

=cut
90 changes: 12 additions & 78 deletions src/4.2.1. Disk partitions and filesystems.pod
Original file line number Diff line number Diff line change
Expand Up @@ -5,45 +5,12 @@ is a SCSI disk C</dev/sda>, but if you have an NVME disk
(like C</dev/nvme0n1>) or another SCSI disk (like C</dev/sdb>), it's
simple as run C<sed 's/sda/sdb/g'>.

=begin man

.TS
center, box, tab (|) ;
l | l | l | l
l | l | l | l.
Partition|Filesystem|Size|Description
_
.SP
/dev/sda1|fat32|512MB|boot partition
/dev/sda2|luks|rest of the disk|luks partition
.TE

=end man

=begin html

<table>
<tr>
<th>Partition</th>
<th>Filesystem</th>
<th>Size</th>
<th>Description</th>
</tr>
<tr>
<td>/dev/sda1</td>
<td>fat32</td>
<td>512MB</td>
<td>boot partition</td>
</tr>
<tr>
<td>/dev/sda2</td>
<td>luks</td>
<td>rest of the disk</td>
<td>luks partition</td>
</tr>
</table>

=end html
+-----------+------------+------------------+----------------+
| Partition | Filesystem | Size | Description |
+-----------+------------+------------------+----------------+
| /dev/sda1 | fat32 | 512MB | boot partition |
| /dev/sda2 | luks | rest of the disk | luks partition |
+-----------+------------+------------------+----------------+

Using L<parted(8)> utility we can create all required partitions.

Expand Down Expand Up @@ -84,45 +51,12 @@ device:

This is a quite simple logical volumes scheme used in this handbook.

=begin man

.TS
center, box, tab (|) ;
l | l | l | l
l | l | l | l.
Volume name|Filesystem|Size|Description
_
.SP
swap|swap|2 * RAM|swap area
root|ext4|rest of the disk|root fs
.TE

=end man

=begin html

<table>
<tr>
<th>Volume name</th>
<th>Filesystem</th>
<th>Size</th>
<th>Description</th>
</tr>
<tr>
<td>swap</td>
<td>swap</td>
<td>2 * RAM</td>
<td>swap area</td>
</tr>
<tr>
<td>root</td>
<td>ext4</td>
<td>rest of the disk</td>
<td>root fs</td>
</tr>
</table>

=end html
+-------------+------------+------------------+-------------+
| Volume name | Filesystem | Size | Description |
+-------------+------------+------------------+-------------+
| swap | swap | 2 * RAM | swap area |
| root | ext4 | rest of the disk | root fs |
+-------------+------------+------------------+-------------+

To see the actual amount of RAM, type the following command:

Expand Down
48 changes: 0 additions & 48 deletions src/5.1. Introduction.pod
Original file line number Diff line number Diff line change
@@ -1,49 +1 @@
=head2 5.1. Introduction

=head3 B<5.1.1. Basic package management tools>

The package system (B<pkgutils>) is a fork of CRUX's pkgutils.
It is made with simplicity in mind, where all packages are plain
I<tar.gz> files (i.e. without any kind of metadata).

Packages follow the naming convention
I<name#version-release.pkg.tar.gz>, where I<name> is the name of the
program, I<version> is the version number of the program, and
I<release> is the version number of the package.

The I<pkg.tar.gz> extension is used (instead of just I<tar.gz>) to
indicate that this is not just any I<tar.gz> file, but a I<tar.gz>
that is meant to be installed using L<pkgadd(8)>. This helps
distinguish packages from other I<tar.gz> files. Note that
L<pkgmk(8)> supports additional compression schemes like B<bzip2> with
the I<tar.bz2> extension, B<lzip> with I<tar.lz>, B<xz> with I<tar.xz>,
or B<zstd> ending with I<tar.zst>.

L<pkgadd(8)>, L<pkgrm(8)>, and L<pkginfo(1)> are the basic package
management utilities and are part of the package B<pkgutils>. In
addition to them, package management includes utilities such as
L<pkgmk(8)>, L<rejmerge(8)>, and L<revdep(1)>.

They could also be considered basic, but they are placed in separate
packages so that changes in one utility do not require rebuilding all
of them.

With these utilities, you can install, uninstall, inspect, make
packages, query the package database, merge files that were rejected
during package upgrades, and check for missing libraries of installed
packages.

When a new package is installed using L<pkgadd(8)>, a new record is
added to the package database (stored in F</var/lib/pkg/db>). The
basic package system does not have any kind of dependency checking,
this will not warn you if you install a package that requires other
packages to be installed. The included L<pkgman(1)> tool (B<pkgman>),
however, does support dependencies.

The following sections will describe in short how to use the package
utilities. Additional information about these utilities can be found
on their respective manpage.

=cut

# vim: cc=72 tw=70
47 changes: 47 additions & 0 deletions src/5.1.1. Basic package management tools.pod
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
=head3 B<5.1.1. Basic package management tools>

The package system (B<pkgutils>) is a fork of CRUX's pkgutils.
It is made with simplicity in mind, where all packages are plain
I<tar.gz> files (i.e. without any kind of metadata).

Packages follow the naming convention
I<name#version-release.pkg.tar.gz>, where I<name> is the name of the
program, I<version> is the version number of the program, and
I<release> is the version number of the package.

The I<pkg.tar.gz> extension is used (instead of just I<tar.gz>) to
indicate that this is not just any I<tar.gz> file, but a I<tar.gz>
that is meant to be installed using L<pkgadd(8)>. This helps
distinguish packages from other I<tar.gz> files. Note that
L<pkgmk(8)> supports additional compression schemes like B<bzip2> with
the I<tar.bz2> extension, B<lzip> with I<tar.lz>, B<xz> with I<tar.xz>,
or B<zstd> ending with I<tar.zst>.

L<pkgadd(8)>, L<pkgrm(8)>, and L<pkginfo(1)> are the basic package
management utilities and are part of the package B<pkgutils>. In
addition to them, package management includes utilities such as
L<pkgmk(8)>, L<rejmerge(8)>, and L<revdep(1)>.

They could also be considered basic, but they are placed in separate
packages so that changes in one utility do not require rebuilding all
of them.

With these utilities, you can install, uninstall, inspect, make
packages, query the package database, merge files that were rejected
during package upgrades, and check for missing libraries of installed
packages.

When a new package is installed using L<pkgadd(8)>, a new record is
added to the package database (stored in F</var/lib/pkg/db>). The
basic package system does not have any kind of dependency checking,
this will not warn you if you install a package that requires other
packages to be installed. The included L<pkgman(1)> tool (B<pkgman>),
however, does support dependencies.

The following sections will describe in short how to use the package
utilities. Additional information about these utilities can be found
on their respective manpage.

=cut

# vim: cc=72 tw=70
35 changes: 4 additions & 31 deletions src/5.2.1. Installing a package.pod
Original file line number Diff line number Diff line change
Expand Up @@ -28,44 +28,17 @@ When forcing an installation the ownership of the conflicting files
will be transferred to the package that is currently being installed.
Directories can however be owned by more than one package.

=begin man
=over

=item B<Warning>:

.TS
center, box, tab (|) ;
c
c.
<WARNING>
_
.SP
It is often not a good idea to force the installation
unless you really know what you are doing. If a package
conflicts with already installed files it could be a sign
that the package is broken and installs unexpected files.
Use this option with extreme care, preferably not at all.
.TE

=end man

=begin html

<table>
<tr>
<th>WARNING</th>
</tr>

<tr>
<td>
It is often not a good idea to force the installation
unless you really know what you are doing. If a
package conflicts with already installed files it
could be a sign that the package is broken and
installs unexpected files. Use this option with
extreme care, preferably not at all.
</td>
</tr>
</table>

=end html
=back

As earlier, the package file itself does not contain any metadata.
Instead, the L<pkgadd(8)> uses the package filename to determine the
Expand Down
8 changes: 7 additions & 1 deletion src/5.2.2. Upgrading a package.pod
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,15 @@ F</etc/X11/> (subdirectories included), unless it's the file
F</etc/X11/xorg.conf>. The default rule is to upgrade everything,
rules in this file are exceptions to that rule.

B<Note>: A pattern should never contain an initial "/" since you are
=over

=item B<Caution>:

A pattern should never contain an initial "/" since you are
referring to the files in the package, not the files on the disk.

=back

See L<pkgadd.conf(5)> for more information.

=cut
Loading

0 comments on commit 265b6db

Please sign in to comment.