Skip to content

Arch Linux

Javier Romero edited this page Jun 5, 2020 · 3 revisions

Testing

Prerequisites

Setup an Arch Linux container

docker run -it --rm archlinux /bin/bash

Now inside the container run...

# setup non-root user
useradd -m archie

# add non-root user to sudoers
pacman -Sy --noconfirm sudo
echo 'archie ALL=(ALL:ALL) NOPASSWD:ALL' >> /etc/sudoers

# switch to non-root user
su - archie

Install packages

Prerequisites
# setup AUR packaging deps
sudo pacman -Sy --noconfirm git base-devel libffi
pack-cli
Install
# install pack-cli
cd ~
git clone https://aur.archlinux.org/pack-cli.git
cd pack-cli
makepkg -sri --noconfirm
Uninstalled
# uninstall pack-cli
sudo pacman -R pack-cli
pack-cli-bin
Install
# install pack-cli-bin
cd ~
git clone https://aur.archlinux.org/pack-cli-bin.git
cd pack-cli-bin
makepkg -sri --noconfirm
Uninstalled
# uninstall pack-cli-bin
sudo pacman -R pack-cli-bin

Publishing

NOTES:

  • If this is your first time attempting to publish an AUR package, please read the provided guidelines.
  • ~/.ssh/cnb-aur refers to a key maintained in LastPass

1. Downloading source

# remove all existing keys
ssh-add -D

# add aur key
ssh-add ~/.ssh/cnb-aur

# download pack-cli
git clone ssh://[email protected]/pack-cli.git

# download pack-cli-bin
git clone ssh://[email protected]/pack-cli-bin.git

After making changes and testing them, publishing may be done by following these steps...

2. Publish

From inside the working directory of the package you would like to update.

# regenerate .SRCINFO
makepkg --printsrcinfo > .SRCINFO

# stage changes
git add PKGBUILD .SRCINFO

# commit changes
git commit -s

# publish changes
git push