trying to fix the CI/CD
This commit is contained in:
parent
90d55a8604
commit
1771a6f5e4
1 changed files with 8 additions and 7 deletions
15
build.sh
15
build.sh
|
@ -30,11 +30,11 @@ main() {
|
||||||
echo -e "$Red### You are not in root$reset"
|
echo -e "$Red### You are not in root$reset"
|
||||||
exit 1
|
exit 1
|
||||||
else
|
else
|
||||||
|
change_mirror
|
||||||
install
|
install
|
||||||
echo -e "$Blue### Install complete ###$reset"
|
echo -e "$Blue### Install complete ###$reset"
|
||||||
echo -e "$Green### Start build $reponame with archiso ###$reset"
|
echo -e "$Green### Start build $reponame with archiso ###$reset"
|
||||||
build
|
build
|
||||||
makezip
|
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
echo -e "$Red###OS can't supported###$reset"
|
echo -e "$Red###OS can't supported###$reset"
|
||||||
|
@ -42,19 +42,20 @@ main() {
|
||||||
fi
|
fi
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
install() {
|
install() {
|
||||||
set -e
|
set -e
|
||||||
pacman -Sy; pacman --noconfirm -S --needed git archiso github-cli p7zip
|
pacman -Sy; pacman --noconfirm -S --needed git archiso github-cli p7zip reflector rsync
|
||||||
}
|
}
|
||||||
|
|
||||||
|
change_mirror() {
|
||||||
|
reflector --latest 5 --sort rate --save /etc/pacman.d/mirrorlist
|
||||||
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
set -e
|
set -e
|
||||||
mkarchiso -v iso/
|
mkarchiso -v iso/
|
||||||
}
|
}
|
||||||
makezip() {
|
|
||||||
cd out
|
|
||||||
7z -v500m a "$(ls *.iso)".zip "$(ls *.iso)"
|
|
||||||
md5sum * > md5sums.txt
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
main
|
main
|
||||||
|
|
Loading…
Add table
Reference in a new issue