-
Notifications
You must be signed in to change notification settings - Fork 542
/
build_iso.sh
executable file
·50 lines (37 loc) · 1.07 KB
/
build_iso.sh
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
#!/bin/bash
set -e
packages_file="/tmp/archlive/packages.x86_64"
# Packages to add to the archiso profile packages
packages=(
gcc
git
pkgconfig
python
python-pip
python-build
python-setuptools
python-wheel
python-simple-term-menu
python-pyparted
)
mkdir -p /tmp/archlive/airootfs/root/archinstall-git
cp -r . /tmp/archlive/airootfs/root/archinstall-git
cat <<- _EOF_ | tee /tmp/archlive/airootfs/root/.zprofile
cd archinstall-git
rm -rf dist
python -m build --wheel --no-isolation
pip install dist/archinstall*.whl --break-system-packages
echo "This is an unofficial ISO for development and testing of archinstall. No support will be provided."
echo "This ISO was built from Git SHA $GITHUB_SHA"
echo "Type archinstall to launch the installer."
_EOF_
pacman --noconfirm -S archiso
cp -r /usr/share/archiso/configs/releng/* /tmp/archlive
sed -i /archinstall/d "$packages_file"
# Add packages to the archiso profile packages
for package in "${packages[@]}"; do
echo "$package" >> "$packages_file"
done
find /tmp/archlive
cd /tmp/archlive
mkarchiso -v -w work/ -o out/ ./