summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xconfigs/profile/build.sh30
-rw-r--r--configs/profile/root-image/root/customize_root_image-constants.inc2
-rwxr-xr-xconfigs/profile/root-image/root/customize_root_image.sh4
-rwxr-xr-xparabolaiso/mkparabolaiso9
4 files changed, 18 insertions, 27 deletions
diff --git a/configs/profile/build.sh b/configs/profile/build.sh
index ede1748..3ae1a61 100755
--- a/configs/profile/build.sh
+++ b/configs/profile/build.sh
@@ -28,7 +28,6 @@ iso_version=$(date +%Y.%m.%d)
iso_label="PARA_$(date +%Y%m)"
iso_dirname='parabola'
enable_offline_install='false'
-offline_switch=''
enable_tts_brltty='false'
pacman_conf_in=${releng_dir}/pacman.conf
work_dir=./work
@@ -60,7 +59,7 @@ _usage ()
echo " -D <iso_dirname> Set the name of the directory inside the ISO"
echo " Default: ${iso_dirname}"
echo " -O Enable offline install."
- echo " Default: '${enable_offline_install}'"
+ echo " Default: '' (net-install only)"
echo " -S Enable speech and braille."
echo " Default: '${enable_tts_brltty}'"
echo " -C Specify the pacman.conf file used for chroot install."
@@ -185,8 +184,8 @@ make_packages() {
if [[ "$enable_offline_install" == 'true' ]]; then
if [[ -n "${_cache_packages}" ]]; then
# download any cache packages and prune obsolete packages
- echo 'downloading "cach-only" packages'
- setarch ${arch} mkparabolaiso ${verbose} -w ${work_dir}/${arch} -C ${pacman_conf} -D ${iso_dirname} -p "${_cache_packages}" ${offline_switch} cache
+ echo 'downloading "cache-only" packages'
+ setarch ${arch} mkparabolaiso ${verbose} -w ${work_dir}/${arch} -C ${pacman_conf} -D ${iso_dirname} -p "${_cache_packages}" cache
fi
# create 'isorepo' for offline install
@@ -223,16 +222,15 @@ make_customize_root_image() {
cp -af ${releng_dir}/root-image ${work_dir}/${arch}
echo "Customizing root image"
- ISO_TITLE="${iso_title}" \
- ISO_INIT="${iso_init}" \
- ISO_GUI="${iso_gui}" \
- ENABLE_OFFLINE_INSTALL="${enable_offline_install}" \
- ENABLE_TTS_BRLTTY="${enable_tts_brltty}" \
- setarch ${arch} mkparabolaiso ${verbose} -w ${work_dir}/${arch} \
- -C ${pacman_conf} \
- -D ${iso_dirname} \
- ${offline_switch} \
- -r /root/customize_root_image.sh \
+ ISO_TITLE="${iso_title}" \
+ ISO_INIT="${iso_init}" \
+ ISO_GUI="${iso_gui}" \
+ ENABLE_OFFLINE_INSTALL="${enable_offline_install}" \
+ ENABLE_TTS_BRLTTY="${enable_tts_brltty}" \
+ setarch ${arch} mkparabolaiso ${verbose} -w ${work_dir}/${arch} \
+ -C ${pacman_conf} \
+ -D ${iso_dirname} \
+ -r /root/customize_root_image.sh \
run
rm ${work_dir}/${arch}/root-image/root/customize_root_image*
}
@@ -365,7 +363,7 @@ make_aitab() {
make_prepare() {
cp -a -l -f ${work_dir}/${arch}/root-image ${work_dir}/
setarch ${arch} mkparabolaiso ${verbose} -w ${work_dir}/ -D ${iso_dirname} -C ${pacman_conf} pkglist
- setarch ${arch} mkparabolaiso ${verbose} -w ${work_dir}/ -D ${iso_dirname} -C ${pacman_conf} ${offline_switch} prepare
+ setarch ${arch} mkparabolaiso ${verbose} -w ${work_dir}/ -D ${iso_dirname} -C ${pacman_conf} prepare
rm -rf ${work_dir}/root-image
# rm -rf ${work_dir}/${arch}/root-image (if low space, this helps)
@@ -388,7 +386,7 @@ while getopts 'E:T:V:L:D:OSC:w:o:vh' arg; do
V) iso_version="${OPTARG}" ;;
L) iso_label="${OPTARG}" ;;
D) iso_dirname="${OPTARG}" ;;
- O) enable_offline_install='true' offline_switch='-O' ;;
+ O) enable_offline_install='true' ;;
S) enable_tts_brltty='true' ;;
C) pacman_conf_in="${OPTARG}" ;;
w) work_dir="${OPTARG}" ;;
diff --git a/configs/profile/root-image/root/customize_root_image-constants.inc b/configs/profile/root-image/root/customize_root_image-constants.inc
index 9831e0f..a3c992e 100644
--- a/configs/profile/root-image/root/customize_root_image-constants.inc
+++ b/configs/profile/root-image/root/customize_root_image-constants.inc
@@ -81,7 +81,7 @@ readonly OPENRC_USER_GROUPS="disk,sys"
[[ "${ISO_INIT}" == 'openrc' ]] && readonly LIVE_USER_GROUPS="${DEFAULT_USER_GROUPS},${OPENRC_USER_GROUPS}" ||
readonly LIVE_USER_GROUPS="${DEFAULT_USER_GROUPS}"
-readonly TITLE_REGEX="^(.+) - (.+) (.+)"
+readonly TITLE_REGEX="^(.+) - (.+) (.+)$"
readonly TITLE_ERROR_MSG="malformed ISO title:\n\t'${ISO_TITLE}'"
! [[ "${ISO_TITLE}" =~ ${TITLE_REGEX} ]] && echo -e "${TITLE_ERROR_MSG}" && exit 1
readonly OS_PRETTY_NAME="${BASH_REMATCH[ 1]}"
diff --git a/configs/profile/root-image/root/customize_root_image.sh b/configs/profile/root-image/root/customize_root_image.sh
index 32bca8b..8c2c066 100755
--- a/configs/profile/root-image/root/customize_root_image.sh
+++ b/configs/profile/root-image/root/customize_root_image.sh
@@ -39,8 +39,8 @@ then # delete files that are specific to other init systems
for service in ${OPENRC_SERVICES} ; do rc-update add ${service} default ; done ;
# create the 'dbus' group and user if they do not exist
- if ! grep 'dbus' /etc/group > /dev/null ; then groupadd -g 81 dbus ; fi ;
- if ! grep 'dbus' /etc/passwd > /dev/null ; then useradd -r -s /sbin/nologin -u 81 -g 81 dbus ; fi ;
+ if ! grep -q 'dbus' /etc/group ; then groupadd -g 81 dbus ; fi ;
+ if ! grep -q 'dbus' /etc/passwd ; then useradd -r -s /sbin/nologin -u 81 -g 81 dbus ; fi ;
elif [[ "${ISO_INIT}" == 'systemd' ]]
then # delete files that are specific to other init systems
diff --git a/parabolaiso/mkparabolaiso b/parabolaiso/mkparabolaiso
index f2f5ff4..c2a50a6 100755
--- a/parabolaiso/mkparabolaiso
+++ b/parabolaiso/mkparabolaiso
@@ -16,7 +16,6 @@ iso_application="Parabola GNU/Linux-libre Live/Rescue ISO"
install_dir="parabola"
work_dir="work"
out_dir="out"
-enable_offline_install='false'
# Show an INFO message
@@ -164,8 +163,6 @@ _usage ()
echo " -D <install_dir> Set an install_dir. All files will by located here."
echo " Default: '${install_dir}'"
echo " NOTE: Max 8 characters, use only [a-z0-9]"
- echo " -O Enable offline install."
- echo " Default: '${enable_offline_install}'"
echo " -w <work_dir> Set the working directory"
echo " Default: '${work_dir}'"
echo " -o <out_dir> Set the output directory"
@@ -206,7 +203,6 @@ _show_config () {
;;
install)
_msg_info " Pacman config file: ${pacman_conf}"
- _msg_info " Offline install: ${enable_offline_install}"
_msg_info " Packages: ${pkg_list}"
;;
cache)
@@ -215,11 +211,9 @@ _show_config () {
;;
run)
_msg_info " Run command: ${run_cmd}"
- _msg_info " Offline install: ${enable_offline_install}"
;;
prepare)
_msg_info " Pacman config file: ${pacman_conf}"
- _msg_info " Offline install: ${enable_offline_install}"
;;
checksum)
;;
@@ -610,7 +604,7 @@ if [[ ${EUID} -ne 0 ]]; then
_msg_error "This script must be run as root." 1
fi
-while getopts 'p:r:C:L:P:A:D:Ow:o:vh' arg; do
+while getopts 'p:r:C:L:P:A:D:w:o:vh' arg; do
case "${arg}" in
p) pkg_list="${pkg_list} ${OPTARG}" ;;
r) run_cmd="${OPTARG}" ;;
@@ -619,7 +613,6 @@ while getopts 'p:r:C:L:P:A:D:Ow:o:vh' arg; do
P) iso_publisher="${OPTARG}" ;;
A) iso_application="${OPTARG}" ;;
D) install_dir="${OPTARG}" ;;
- O) enable_offline_install='true' ;;
w) work_dir="${OPTARG}" ;;
o) out_dir="${OPTARG}" ;;
v) quiet="n" ;;