Skip to content

Commit

Permalink
workflow: Add git hook and linter setup to prerequisites
Browse files Browse the repository at this point in the history
Signed-off-by: Rune Morling <[email protected]>
  • Loading branch information
ermo authored Jan 7, 2025
1 parent 4d97730 commit 0a40574
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions content/en/docs/packaging/workflow/prerequisites.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ sudo moss sync -u
sudo moss it build-essential
```


## Activating the Serpent OS helper scripts

The easiest way to create a local repository is to use the helper script distributed with the
Expand All @@ -29,7 +30,6 @@ Start by cloning the recipes/ git repository:
mkdir -pv repos/serpent-os/
pushd repos/serpent-os
git clone https://github.com/serpent-os/recipes

```

After the recipes/ git repository has been cloned, symlink helpers.bash into `~/.bashrcd.d/`:
Expand All @@ -44,13 +44,27 @@ Finally, execute the following in a new terminal tab:

```bash
cd ~
gotoserpentroot
gotoserpentrepo
```

If the helpers script has been correctly loaded, the `gotoserpentrepo` command should switch to
the directory containing the recipes/ git repository clone.


### Setting up git hooks and linters

The `just` command runner should have been installed as part of `build-essential`.

Run the following:

```bash
gotoserpentrepo
just lint
```

This will setup git hooks that will lint for the most common packaging errors upon git commit, as well as fill out commit message templates for you to edit as appropriate.


## Adding /etc/subuid and /etc/subgid entries

Since `boulder` uses user-namespaces to set up isolated build roots, it is necessary to set up
Expand Down

0 comments on commit 0a40574

Please sign in to comment.