forked from mirrored-repos/manjaro-tools
util: rename iso_name in os_id
This commit is contained in:
parent
95cef43bc7
commit
436eafaddf
4 changed files with 15 additions and 15 deletions
|
@ -273,7 +273,7 @@ prepare_initcpio(){
|
||||||
|
|
||||||
prepare_initramfs(){
|
prepare_initramfs(){
|
||||||
local mnt="$1"
|
local mnt="$1"
|
||||||
cp ${DATADIR}/mkinitcpio.conf $mnt/etc/mkinitcpio-${iso_name}.conf
|
cp ${DATADIR}/mkinitcpio.conf $mnt/etc/mkinitcpio-${os_id}.conf
|
||||||
local _kernver=$(cat $mnt/usr/lib/modules/*/version)
|
local _kernver=$(cat $mnt/usr/lib/modules/*/version)
|
||||||
if [[ -n ${gpgkey} ]]; then
|
if [[ -n ${gpgkey} ]]; then
|
||||||
su ${OWNER} -c "gpg --export ${gpgkey} >${MT_USERCONFDIR}/gpgkey"
|
su ${OWNER} -c "gpg --export ${gpgkey} >${MT_USERCONFDIR}/gpgkey"
|
||||||
|
@ -281,7 +281,7 @@ prepare_initramfs(){
|
||||||
fi
|
fi
|
||||||
MISO_GNUPG_FD=${gpgkey:+17} chroot-run $mnt \
|
MISO_GNUPG_FD=${gpgkey:+17} chroot-run $mnt \
|
||||||
/usr/bin/mkinitcpio -k ${_kernver} \
|
/usr/bin/mkinitcpio -k ${_kernver} \
|
||||||
-c /etc/mkinitcpio-${iso_name}.conf \
|
-c /etc/mkinitcpio-${os_id}.conf \
|
||||||
-g /boot/initramfs.img
|
-g /boot/initramfs.img
|
||||||
|
|
||||||
if [[ -n ${gpgkey} ]]; then
|
if [[ -n ${gpgkey} ]]; then
|
||||||
|
@ -337,7 +337,7 @@ prepare_grub(){
|
||||||
grub-mkimage -d ${grub}/${platform} -o ${efi}/${img} -O ${platform} -p ${prefix} iso9660
|
grub-mkimage -d ${grub}/${platform} -o ${efi}/${img} -O ${platform} -p ${prefix} iso9660
|
||||||
|
|
||||||
prepare_dir ${grub}/themes
|
prepare_dir ${grub}/themes
|
||||||
cp -r ${theme}/themes/${iso_name}-live ${grub}/themes/
|
cp -r ${theme}/themes/${os_id}-live ${grub}/themes/
|
||||||
cp ${data}/unicode.pf2 ${grub}
|
cp ${data}/unicode.pf2 ${grub}
|
||||||
cp -r ${theme}/{locales,tz} ${grub}
|
cp -r ${theme}/{locales,tz} ${grub}
|
||||||
|
|
||||||
|
|
|
@ -79,8 +79,8 @@ configure_thus(){
|
||||||
echo "DISTRIBUTION_VERSION = \"${dist_release}\"" >> "$conf"
|
echo "DISTRIBUTION_VERSION = \"${dist_release}\"" >> "$conf"
|
||||||
echo "SHORT_NAME = \"${dist_name}\"" >> "$conf"
|
echo "SHORT_NAME = \"${dist_name}\"" >> "$conf"
|
||||||
echo "[install]" >> "$conf"
|
echo "[install]" >> "$conf"
|
||||||
echo "LIVE_MEDIA_SOURCE = \"/run/miso/bootmnt/${iso_name}/${target_arch}/rootfs.sfs\"" >> "$conf"
|
echo "LIVE_MEDIA_SOURCE = \"/run/miso/bootmnt/${os_id}/${target_arch}/rootfs.sfs\"" >> "$conf"
|
||||||
echo "LIVE_MEDIA_DESKTOP = \"/run/miso/bootmnt/${iso_name}/${target_arch}/desktopfs.sfs\"" >> "$conf"
|
echo "LIVE_MEDIA_DESKTOP = \"/run/miso/bootmnt/${os_id}/${target_arch}/desktopfs.sfs\"" >> "$conf"
|
||||||
echo "LIVE_MEDIA_TYPE = \"squashfs\"" >> "$conf"
|
echo "LIVE_MEDIA_TYPE = \"squashfs\"" >> "$conf"
|
||||||
echo "LIVE_USER_NAME = \"${username}\"" >> "$conf"
|
echo "LIVE_USER_NAME = \"${username}\"" >> "$conf"
|
||||||
echo "KERNEL = \"${kernel}\"" >> "$conf"
|
echo "KERNEL = \"${kernel}\"" >> "$conf"
|
||||||
|
@ -130,7 +130,7 @@ make_sfs() {
|
||||||
error "The path %s does not exist" "${src}"
|
error "The path %s does not exist" "${src}"
|
||||||
retrun 1
|
retrun 1
|
||||||
fi
|
fi
|
||||||
local timer=$(get_timer) dest=${iso_root}/${iso_name}/${target_arch}
|
local timer=$(get_timer) dest=${iso_root}/${os_id}/${target_arch}
|
||||||
local name=${1##*/}
|
local name=${1##*/}
|
||||||
local sfs="${dest}/${name}.sfs"
|
local sfs="${dest}/${name}.sfs"
|
||||||
mkdir -p ${dest}
|
mkdir -p ${dest}
|
||||||
|
@ -251,7 +251,7 @@ make_iso() {
|
||||||
|
|
||||||
gen_iso_fn(){
|
gen_iso_fn(){
|
||||||
local vars=() name
|
local vars=() name
|
||||||
vars+=("${iso_name}")
|
vars+=("${os_id}")
|
||||||
if ! ${chrootcfg};then
|
if ! ${chrootcfg};then
|
||||||
[[ -n ${profile} ]] && vars+=("${profile}")
|
[[ -n ${profile} ]] && vars+=("${profile}")
|
||||||
fi
|
fi
|
||||||
|
@ -416,7 +416,7 @@ make_image_boot() {
|
||||||
|
|
||||||
configure_grub(){
|
configure_grub(){
|
||||||
local conf="$1"
|
local conf="$1"
|
||||||
local default_args="misobasedir=${iso_name} misolabel=${iso_label}" boot_args=('quiet')
|
local default_args="misobasedir=${os_id} misolabel=${iso_label}" boot_args=('quiet')
|
||||||
[[ ${initsys} == 'systemd' ]] && boot_args+=('systemd.show_status=1')
|
[[ ${initsys} == 'systemd' ]] && boot_args+=('systemd.show_status=1')
|
||||||
|
|
||||||
sed -e "s|@DIST_NAME@|${dist_name}|g" \
|
sed -e "s|@DIST_NAME@|${dist_name}|g" \
|
||||||
|
@ -429,7 +429,7 @@ configure_grub(){
|
||||||
|
|
||||||
configure_grub_theme(){
|
configure_grub_theme(){
|
||||||
local conf="$1"
|
local conf="$1"
|
||||||
sed -e "s|@ISO_NAME@|${iso_name}|" -i "$conf"
|
sed -e "s|@ISO_NAME@|${os_id}|" -i "$conf"
|
||||||
}
|
}
|
||||||
|
|
||||||
make_grub(){
|
make_grub(){
|
||||||
|
|
|
@ -132,11 +132,11 @@ write_unpack_conf(){
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo "---" > "$conf"
|
echo "---" > "$conf"
|
||||||
echo "unpack:" >> "$conf"
|
echo "unpack:" >> "$conf"
|
||||||
echo " - source: \"/run/miso/bootmnt/${iso_name}/${target_arch}/rootfs.sfs\"" >> "$conf"
|
echo " - source: \"/run/miso/bootmnt/${os_id}/${target_arch}/rootfs.sfs\"" >> "$conf"
|
||||||
echo " sourcefs: \"squashfs\"" >> "$conf"
|
echo " sourcefs: \"squashfs\"" >> "$conf"
|
||||||
echo " destination: \"\"" >> "$conf"
|
echo " destination: \"\"" >> "$conf"
|
||||||
if [[ -f "${desktop_list}" ]] ; then
|
if [[ -f "${desktop_list}" ]] ; then
|
||||||
echo " - source: \"/run/miso/bootmnt/${iso_name}/${target_arch}/desktopfs.sfs\"" >> "$conf"
|
echo " - source: \"/run/miso/bootmnt/${os_id}/${target_arch}/desktopfs.sfs\"" >> "$conf"
|
||||||
echo " sourcefs: \"squashfs\"" >> "$conf"
|
echo " sourcefs: \"squashfs\"" >> "$conf"
|
||||||
echo " destination: \"\"" >> "$conf"
|
echo " destination: \"\"" >> "$conf"
|
||||||
fi
|
fi
|
||||||
|
@ -335,7 +335,7 @@ write_settings_conf(){
|
||||||
echo " - show:" >> "$conf"
|
echo " - show:" >> "$conf"
|
||||||
echo " - finished" >> "$conf" && write_finished_conf
|
echo " - finished" >> "$conf" && write_finished_conf
|
||||||
echo '' >> "$conf"
|
echo '' >> "$conf"
|
||||||
echo "branding: ${iso_name}" >> "$conf"
|
echo "branding: ${os_id}" >> "$conf"
|
||||||
echo '' >> "$conf"
|
echo '' >> "$conf"
|
||||||
echo "prompt-install: false" >> "$conf"
|
echo "prompt-install: false" >> "$conf"
|
||||||
echo '' >> "$conf"
|
echo '' >> "$conf"
|
||||||
|
|
|
@ -258,7 +258,7 @@ init_buildiso(){
|
||||||
|
|
||||||
dist_name=$(get_distname)
|
dist_name=$(get_distname)
|
||||||
|
|
||||||
iso_name=$(get_osid)
|
os_id=$(get_osid)
|
||||||
|
|
||||||
[[ -z ${dist_branding} ]] && dist_branding="MJRO"
|
[[ -z ${dist_branding} ]] && dist_branding="MJRO"
|
||||||
|
|
||||||
|
@ -386,7 +386,7 @@ load_profile(){
|
||||||
${extra} && basic='false'
|
${extra} && basic='false'
|
||||||
|
|
||||||
root_list=${run_dir}/shared/Packages-Root
|
root_list=${run_dir}/shared/Packages-Root
|
||||||
root_overlay="${run_dir}/shared/${dist_name}/root-overlay"
|
root_overlay="${run_dir}/shared/${os_id}/root-overlay"
|
||||||
if [[ -e "$profdir/root-overlay" ]];then
|
if [[ -e "$profdir/root-overlay" ]];then
|
||||||
root_overlay="$profdir/root-overlay"
|
root_overlay="$profdir/root-overlay"
|
||||||
fi
|
fi
|
||||||
|
@ -403,7 +403,7 @@ load_profile(){
|
||||||
live_list="$profdir/Packages-Live"
|
live_list="$profdir/Packages-Live"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
live_overlay="${run_dir}/shared/${dist_name}/live-overlay"
|
live_overlay="${run_dir}/shared/${os_id}/live-overlay"
|
||||||
if [[ -e "$profdir/live-overlay" ]];then
|
if [[ -e "$profdir/live-overlay" ]];then
|
||||||
live_overlay="$profdir/live-overlay"
|
live_overlay="$profdir/live-overlay"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue