forked from AndydeCleyre/archbuilder_iosevka
-
Notifications
You must be signed in to change notification settings - Fork 0
87 lines (70 loc) · 3.46 KB
/
buildpkg.yml
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
name: Build and upload Arch Linux packages
on:
push:
tags:
- '**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: create and update build ctnr from official repos
run: |
buildah from --name ctnr docker.io/library/archlinux:base-devel
buildah copy ctnr 'https://archlinux.org/mirrorlist/?country=US&protocol=https&ip_version=4&ip_version=6&use_mirror_status=on' /tmp/mirrorlist
buildah run ctnr sh -c "sed 's/^#Server =/Server =/g' /tmp/mirrorlist | shuf >/etc/pacman.d/mirrorlist"
buildah run ctnr chmod 0644 /etc/pacman.d/mirrorlist
buildah run ctnr pacman --noconfirm -Syu
buildah run ctnr pacman --noconfirm -S --needed git
- name: add non-root user to build ctnr
run: |
buildah run ctnr useradd -m dev
buildah run ctnr sh -c 'printf "%s\n" "dev ALL=(ALL) NOPASSWD: ALL" >>/etc/sudoers.d/dev'
- name: build and install AUR dep ttfautohint
run: |
buildah config -u dev ctnr
buildah run ctnr gpg --keyserver keyserver.ubuntu.com --recv-keys 58E0C111E39F5408C5D3EC76C1A60EACE707FDA5
buildah run ctnr git clone https://aur.archlinux.org/ttfautohint /home/dev/ttfautohint
buildah config --workingdir /home/dev/ttfautohint ctnr
buildah run ctnr makepkg --noconfirm -si
- name: install templating tools
run: |
python3 -m pip install -U pip setuptools wheel
python3 -m pip install -r requirements.txt
printf '%s\n' "$HOME/.local/bin" >>$GITHUB_PATH
- name: render PKGBUILDs
run: ./mk/pkgbuilds.sh
- name: copy ttf-iosevka-term-custom-git PKGBUILD into build ctnr
run: |
buildah copy --chown dev ctnr pkgs/ttf-iosevka-term-custom-git /home/dev/ttf-iosevka-term-custom-git
- name: build and siphon ttf-iosevka-term-custom-git from build ctnr
run: |
buildah config -u dev --workingdir /home/dev/ttf-iosevka-term-custom-git ctnr
buildah run ctnr makepkg --noconfirm -s
buildah run ctnr ls -lh
pkg="$(buildah run ctnr sh -c "printf '%s\n' *.pkg.*")"
mkdir -p "${RUNNER_TEMP}/dist"
buildah run ctnr cat "$pkg" >"${RUNNER_TEMP}/dist/${pkg}"
printf '%s\n' "${RUNNER_TEMP}/dist/"
ls -lh "${RUNNER_TEMP}/dist/"
- name: copy ttf-iosevka-quasi-proportional-extension-only-custom-git PKGBUILD into build ctnr
run: |
buildah copy --chown dev ctnr pkgs/ttf-iosevka-quasi-proportional-extension-only-custom-git /home/dev/ttf-iosevka-quasi-proportional-extension-only-custom-git
- name: build and siphon ttf-iosevka-quasi-proportional-extension-only-custom-git from build ctnr
run: |
buildah config -u dev --workingdir /home/dev/ttf-iosevka-quasi-proportional-extension-only-custom-git ctnr
buildah run ctnr makepkg --noconfirm -s
buildah run ctnr ls -lh
pkg="$(buildah run ctnr sh -c "printf '%s\n' *.pkg.*")"
mkdir -p "${RUNNER_TEMP}/dist"
buildah run ctnr cat "$pkg" >"${RUNNER_TEMP}/dist/${pkg}"
printf '%s\n' "${RUNNER_TEMP}/dist/"
ls -lh "${RUNNER_TEMP}/dist/"
- name: Release
uses: softprops/action-gh-release@v1
with:
files: ${{ runner.temp }}/dist/*
fail_on_unmatched_files: true
body_path: private-build-plans.toml