forked from mirrored-repos/manjaro-tools
Compare commits
16 commits
master
...
stable-0.1
Author | SHA1 | Date | |
---|---|---|---|
|
d5b49f0f77 | ||
|
c06d2e160b | ||
|
c5facb498e | ||
|
aa976eda09 | ||
|
f9fdcad3a3 | ||
|
6c07c3286b | ||
|
0f896a2918 | ||
|
7b6fe03c3a | ||
|
9e36cc99c2 | ||
|
28db47e276 | ||
|
f3118097b9 | ||
|
109bf845a8 | ||
|
a2cd3f5c3f | ||
|
c122eef1f7 | ||
|
8a8bf8487a | ||
|
a48c76c6a2 |
13 changed files with 117 additions and 420 deletions
5
Makefile
5
Makefile
|
@ -1,4 +1,4 @@
|
||||||
Version=0.15.14
|
Version=0.15.12
|
||||||
|
|
||||||
PREFIX = /usr/local
|
PREFIX = /usr/local
|
||||||
SYSCONFDIR = /etc
|
SYSCONFDIR = /etc
|
||||||
|
@ -13,8 +13,7 @@ BIN_BASE = \
|
||||||
bin/manjaro-chroot \
|
bin/manjaro-chroot \
|
||||||
bin/fstabgen \
|
bin/fstabgen \
|
||||||
bin/signfile \
|
bin/signfile \
|
||||||
bin/chroot-run \
|
bin/chroot-run
|
||||||
bin/check-yaml
|
|
||||||
|
|
||||||
LIBS_BASE = \
|
LIBS_BASE = \
|
||||||
lib/util.sh \
|
lib/util.sh \
|
||||||
|
|
|
@ -50,7 +50,6 @@ show_profile(){
|
||||||
[[ -n ${smb_workgroup} ]] && msg2 "smb_workgroup: %s" "${smb_workgroup}"
|
[[ -n ${smb_workgroup} ]] && msg2 "smb_workgroup: %s" "${smb_workgroup}"
|
||||||
|
|
||||||
msg2 "enable_systemd: %s" "${enable_systemd[*]}"
|
msg2 "enable_systemd: %s" "${enable_systemd[*]}"
|
||||||
msg2 "enable_systemd_timers: %s" "${enable_systemd_timers[*]}"
|
|
||||||
msg2 "enable_systemd_live: %s" "${enable_systemd_live[*]}"
|
msg2 "enable_systemd_live: %s" "${enable_systemd_live[*]}"
|
||||||
[[ -n ${disable_systemd[*]} ]] && msg2 "disable_systemd: %s" "${disable_systemd[*]}"
|
[[ -n ${disable_systemd[*]} ]] && msg2 "disable_systemd: %s" "${disable_systemd[*]}"
|
||||||
|
|
||||||
|
@ -131,7 +130,6 @@ usage() {
|
||||||
echo " [default: ${kernel}]"
|
echo " [default: ${kernel}]"
|
||||||
echo ' -l Create permalink'
|
echo ' -l Create permalink'
|
||||||
echo ' -m Set SquashFS image mode to persistence'
|
echo ' -m Set SquashFS image mode to persistence'
|
||||||
echo ' -n Disable multilib'
|
|
||||||
echo " -p <profile> Buildset or profile [default: ${build_list_iso}]"
|
echo " -p <profile> Buildset or profile [default: ${build_list_iso}]"
|
||||||
echo ' -o Enable office installer module'
|
echo ' -o Enable office installer module'
|
||||||
echo ' -q Query settings and pretend build'
|
echo ' -q Query settings and pretend build'
|
||||||
|
@ -151,7 +149,7 @@ usage() {
|
||||||
|
|
||||||
orig_argv=("$@")
|
orig_argv=("$@")
|
||||||
|
|
||||||
opts='p:a:b:r:t:k:g:d:cfzxmnvqhilo'
|
opts='p:a:b:r:t:k:g:d:cfzxmvqhilo'
|
||||||
|
|
||||||
while getopts "${opts}" arg; do
|
while getopts "${opts}" arg; do
|
||||||
case "${arg}" in
|
case "${arg}" in
|
||||||
|
@ -164,7 +162,6 @@ while getopts "${opts}" arg; do
|
||||||
g) gpgkey="$OPTARG" ;;
|
g) gpgkey="$OPTARG" ;;
|
||||||
k) kernel="$OPTARG" ;;
|
k) kernel="$OPTARG" ;;
|
||||||
m) persist=true ;;
|
m) persist=true ;;
|
||||||
n) no_multilib=true ;; # only exist if set here
|
|
||||||
p) build_list_iso="$OPTARG" ;;
|
p) build_list_iso="$OPTARG" ;;
|
||||||
q) pretend=true ;;
|
q) pretend=true ;;
|
||||||
r) chroots_iso="$OPTARG" ;;
|
r) chroots_iso="$OPTARG" ;;
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
MODULES=(loop dm-snapshot)
|
MODULES="loop dm-snapshot"
|
||||||
HOOKS=(base udev miso_shutdown miso miso_loop_mnt miso_pxe_common miso_pxe_http miso_pxe_nbd miso_pxe_nfs miso_kms modconf block filesystems keyboard keymap)
|
HOOKS="base udev miso_shutdown miso miso_loop_mnt miso_pxe_common miso_pxe_http miso_pxe_nbd miso_pxe_nfs miso_kms modconf block filesystems keyboard keymap"
|
||||||
COMPRESSION="xz"
|
COMPRESSION="xz"
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
HoldPkg = pacman glibc
|
HoldPkg = pacman glibc
|
||||||
# If upgrades are available for these packages they will be asked for first
|
# If upgrades are available for these packages they will be asked for first
|
||||||
SyncFirst = manjaro-system archlinux-keyring manjaro-keyring
|
SyncFirst = manjaro-system archlinux-keyring manjaro-keyring
|
||||||
#XferCommand = /usr/bin/curl -L -C - -f -o %o %u
|
#XferCommand = /usr/bin/curl -C - -f %u > %o
|
||||||
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u
|
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u
|
||||||
#CleanMethod = KeepInstalled
|
#CleanMethod = KeepInstalled
|
||||||
#UseDelta = 0.7
|
#UseDelta = 0.7
|
||||||
|
@ -34,11 +34,10 @@ Architecture = auto
|
||||||
# Misc options
|
# Misc options
|
||||||
#UseSyslog
|
#UseSyslog
|
||||||
#Color
|
#Color
|
||||||
#NoProgressBar
|
#TotalDownload
|
||||||
# We cannot check disk space from within a chroot environment
|
# We cannot check disk space from within a chroot environment
|
||||||
#CheckSpace
|
#CheckSpace
|
||||||
#VerbosePkgLists
|
#VerbosePkgLists
|
||||||
ParallelDownloads = 4
|
|
||||||
|
|
||||||
# By default, pacman accepts packages signed by keys that its local keyring
|
# By default, pacman accepts packages signed by keys that its local keyring
|
||||||
# trusts (see pacman-key and its man page), as well as unsigned packages.
|
# trusts (see pacman-key and its man page), as well as unsigned packages.
|
||||||
|
@ -81,8 +80,13 @@ Include = /etc/pacman.d/mirrorlist
|
||||||
SigLevel = PackageRequired
|
SigLevel = PackageRequired
|
||||||
Include = /etc/pacman.d/mirrorlist
|
Include = /etc/pacman.d/mirrorlist
|
||||||
|
|
||||||
|
[community]
|
||||||
|
SigLevel = PackageRequired
|
||||||
|
Include = /etc/pacman.d/mirrorlist
|
||||||
|
|
||||||
# An example of a custom package repository. See the pacman manpage for
|
# An example of a custom package repository. See the pacman manpage for
|
||||||
# tips on creating your own repositories.
|
# tips on creating your own repositories.
|
||||||
#[custom]
|
#[custom]
|
||||||
#SigLevel = Optional TrustAll
|
#SigLevel = Optional TrustAll
|
||||||
#Server = file:///home/custompkgs
|
#Server = file:///home/custompkgs
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
#LogFile = /var/log/pacman.log
|
#LogFile = /var/log/pacman.log
|
||||||
#GPGDir = /etc/pacman.d/gnupg/
|
#GPGDir = /etc/pacman.d/gnupg/
|
||||||
HoldPkg = pacman glibc
|
HoldPkg = pacman glibc
|
||||||
#XferCommand = /usr/bin/curl -L -C - -f -o %o %u
|
#XferCommand = /usr/bin/curl -C - -f %u > %o
|
||||||
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u
|
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u
|
||||||
#CleanMethod = KeepInstalled
|
#CleanMethod = KeepInstalled
|
||||||
Architecture = auto
|
Architecture = auto
|
||||||
|
@ -30,10 +30,9 @@ Architecture = auto
|
||||||
# Misc options
|
# Misc options
|
||||||
#UseSyslog
|
#UseSyslog
|
||||||
#UseDelta
|
#UseDelta
|
||||||
#NoProgressBar
|
#TotalDownload
|
||||||
CheckSpace
|
CheckSpace
|
||||||
#VerbosePkgLists
|
#VerbosePkgLists
|
||||||
#ParallelDownloads = 5
|
|
||||||
|
|
||||||
# PGP signature checking
|
# PGP signature checking
|
||||||
# NOTE: None of this will work without running `pacman-key --init` first.
|
# NOTE: None of this will work without running `pacman-key --init` first.
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
HoldPkg = pacman glibc
|
HoldPkg = pacman glibc
|
||||||
# If upgrades are available for these packages they will be asked for first
|
# If upgrades are available for these packages they will be asked for first
|
||||||
SyncFirst = manjaro-system archlinux-keyring manjaro-keyring
|
SyncFirst = manjaro-system archlinux-keyring manjaro-keyring
|
||||||
#XferCommand = /usr/bin/curl -L -C - -f -o %o %u
|
#XferCommand = /usr/bin/curl -C - -f %u > %o
|
||||||
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u
|
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u
|
||||||
#CleanMethod = KeepInstalled
|
#CleanMethod = KeepInstalled
|
||||||
#UseDelta = 0.7
|
#UseDelta = 0.7
|
||||||
|
@ -34,11 +34,10 @@ Architecture = auto
|
||||||
# Misc options
|
# Misc options
|
||||||
#UseSyslog
|
#UseSyslog
|
||||||
#Color
|
#Color
|
||||||
#NoProgressBar
|
#TotalDownload
|
||||||
# We cannot check disk space from within a chroot environment
|
# We cannot check disk space from within a chroot environment
|
||||||
#CheckSpace
|
#CheckSpace
|
||||||
#VerbosePkgLists
|
#VerbosePkgLists
|
||||||
ParallelDownloads = 4
|
|
||||||
|
|
||||||
# By default, pacman accepts packages signed by keys that its local keyring
|
# By default, pacman accepts packages signed by keys that its local keyring
|
||||||
# trusts (see pacman-key and its man page), as well as unsigned packages.
|
# trusts (see pacman-key and its man page), as well as unsigned packages.
|
||||||
|
@ -81,6 +80,10 @@ Include = /etc/pacman.d/mirrorlist
|
||||||
SigLevel = PackageRequired
|
SigLevel = PackageRequired
|
||||||
Include = /etc/pacman.d/mirrorlist
|
Include = /etc/pacman.d/mirrorlist
|
||||||
|
|
||||||
|
[community]
|
||||||
|
SigLevel = PackageRequired
|
||||||
|
Include = /etc/pacman.d/mirrorlist
|
||||||
|
|
||||||
# If you want to run 32 bit applications on your x86_64 system,
|
# If you want to run 32 bit applications on your x86_64 system,
|
||||||
# enable the multilib repositories as required here.
|
# enable the multilib repositories as required here.
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
run_cleanuphook() {
|
run_cleanuphook() {
|
||||||
rm -rf /usr/lib/modules
|
rm -rf /usr/lib/modules
|
||||||
cp -ax /. /run/initramfs
|
cp -ax / /run/initramfs
|
||||||
}
|
}
|
||||||
|
|
||||||
# vim: set ft=sh ts=4 sw=4 et:
|
# vim: set ft=sh ts=4 sw=4 et:
|
||||||
|
|
|
@ -18,7 +18,7 @@ prepare_initcpio(){
|
||||||
|
|
||||||
prepare_initramfs(){
|
prepare_initramfs(){
|
||||||
cp ${DATADIR}/mkinitcpio.conf $1/etc/mkinitcpio-${iso_name}.conf
|
cp ${DATADIR}/mkinitcpio.conf $1/etc/mkinitcpio-${iso_name}.conf
|
||||||
local _kernver=$(cat $1/usr/lib/modules/*/kernelbase | awk -F'-' '{print $1}')
|
local _kernver=$(cat $1/usr/lib/modules/*/version)
|
||||||
if [[ -n ${gpgkey} ]]; then
|
if [[ -n ${gpgkey} ]]; then
|
||||||
su ${OWNER} -c "gpg --export ${gpgkey} >${USERCONFDIR}/gpgkey"
|
su ${OWNER} -c "gpg --export ${gpgkey} >${USERCONFDIR}/gpgkey"
|
||||||
exec 17<>${USERCONFDIR}/gpgkey
|
exec 17<>${USERCONFDIR}/gpgkey
|
||||||
|
@ -42,6 +42,7 @@ prepare_boot_extras(){
|
||||||
cp $1/usr/share/licenses/amd-ucode/LIC* $2/amd_ucode.LICENSE
|
cp $1/usr/share/licenses/amd-ucode/LIC* $2/amd_ucode.LICENSE
|
||||||
cp $1/usr/share/licenses/intel-ucode/LIC* $2/intel_ucode.LICENSE
|
cp $1/usr/share/licenses/intel-ucode/LIC* $2/intel_ucode.LICENSE
|
||||||
cp $1/boot/memtest86+/memtest.bin $2/memtest
|
cp $1/boot/memtest86+/memtest.bin $2/memtest
|
||||||
|
cp $1/usr/share/licenses/common/GPL2/license.txt $2/memtest.COPYING
|
||||||
}
|
}
|
||||||
|
|
||||||
prepare_grub(){
|
prepare_grub(){
|
||||||
|
|
|
@ -51,6 +51,19 @@ configure_mhwd_drivers(){
|
||||||
local path=$1${mhwd_repo}/ \
|
local path=$1${mhwd_repo}/ \
|
||||||
drv_path=$1/var/lib/mhwd/db/pci/graphic_drivers
|
drv_path=$1/var/lib/mhwd/db/pci/graphic_drivers
|
||||||
info "Configuring mhwd db ..."
|
info "Configuring mhwd db ..."
|
||||||
|
if [ -z "$(ls $path | grep catalyst-utils 2> /dev/null)" ]; then
|
||||||
|
msg2 "Disabling Catalyst driver"
|
||||||
|
mkdir -p $drv_path/catalyst/
|
||||||
|
echo "" > $drv_path/catalyst/MHWDCONFIG
|
||||||
|
fi
|
||||||
|
if [ -z "$(ls $path | grep nvidia-340xx-utils 2> /dev/null)" ]; then
|
||||||
|
msg2 "Disabling Nvidia 340xx driver"
|
||||||
|
mkdir -p $drv_path/nvidia-340xx/
|
||||||
|
echo "" > $drv_path/nvidia-340xx/MHWDCONFIG
|
||||||
|
msg2 "Disabling Nvidia 340xx Bumblebee driver"
|
||||||
|
mkdir -p $drv_path/hybrid-intel-nvidia-340xx-bumblebee/
|
||||||
|
echo "" > $drv_path/hybrid-intel-nvidia-340xx-bumblebee/MHWDCONFIG
|
||||||
|
fi
|
||||||
if [ -z "$(ls $path | grep nvidia-390xx-utils 2> /dev/null)" ]; then
|
if [ -z "$(ls $path | grep nvidia-390xx-utils 2> /dev/null)" ]; then
|
||||||
msg2 "Disabling Nvidia 390xx driver"
|
msg2 "Disabling Nvidia 390xx driver"
|
||||||
mkdir -p $drv_path/nvidia-390xx/
|
mkdir -p $drv_path/nvidia-390xx/
|
||||||
|
@ -59,27 +72,47 @@ configure_mhwd_drivers(){
|
||||||
mkdir -p $drv_path/hybrid-intel-nvidia-390xx-bumblebee/
|
mkdir -p $drv_path/hybrid-intel-nvidia-390xx-bumblebee/
|
||||||
echo "" > $drv_path/hybrid-intel-nvidia-390xx-bumblebee/MHWDCONFIG
|
echo "" > $drv_path/hybrid-intel-nvidia-390xx-bumblebee/MHWDCONFIG
|
||||||
fi
|
fi
|
||||||
if [ -z "$(ls $path | grep nvidia-utils 2> /dev/null)" ]; then
|
if [ -z "$(ls $path | grep nvidia-418xx-utils 2> /dev/null)" ]; then
|
||||||
msg2 "Disabling Nvidia driver"
|
msg2 "Disabling Nvidia 418xx driver"
|
||||||
mkdir -p $drv_path/nvidia/
|
mkdir -p $drv_path/nvidia-418xx/
|
||||||
echo "" > $drv_path/nvidia/MHWDCONFIG
|
echo "" > $drv_path/nvidia-418xx/MHWDCONFIG
|
||||||
msg2 "Disabling Nvidia AMD Prime driver"
|
msg2 "Disabling Nvidia 418xx Bumblebee driver"
|
||||||
mkdir -p $drv_path/hybrid-amd-nvidia-prime/
|
mkdir -p $drv_path/hybrid-intel-nvidia-418xx-bumblebee/
|
||||||
echo "" > $drv_path/hybrid-amd-nvidia-prime/MHWDCONFIG
|
echo "" > $drv_path/hybrid-intel-nvidia-418xx-bumblebee/MHWDCONFIG
|
||||||
msg2 "Disabling Nvidia Intel Prime driver"
|
|
||||||
mkdir -p $drv_path/hybrid-intel-nvidia-prime/
|
|
||||||
echo "" > $drv_path/hybrid-intel-nvidia-prime/MHWDCONFIG
|
|
||||||
fi
|
fi
|
||||||
if [ -z "$(ls $path | grep nvidia-470xx-utils 2> /dev/null)" ]; then
|
if [ -z "$(ls $path | grep nvidia-430xx-utils 2> /dev/null)" ]; then
|
||||||
msg2 "Disabling Nvidia 470xx driver"
|
msg2 "Disabling Nvidia 430xx driver"
|
||||||
mkdir -p $drv_path/nvidia-470xx/
|
mkdir -p $drv_path/nvidia-430xx/
|
||||||
echo "" > $drv_path/nvidia-470xx/MHWDCONFIG
|
echo "" > $drv_path/nvidia-430xx/MHWDCONFIG
|
||||||
msg2 "Disabling Nvidia 470xx AMD Prime driver"
|
msg2 "Disabling Nvidia 430xx Bumblebee driver"
|
||||||
mkdir -p $drv_path/hybrid-amd-nvidia-470xx-prime/
|
mkdir -p $drv_path/hybrid-intel-nvidia-430xx-bumblebee/
|
||||||
echo "" > $drv_path/hybrid-amd-nvidia-470xx-prime/MHWDCONFIG
|
echo "" > $drv_path/hybrid-intel-nvidia-430xx-bumblebee/MHWDCONFIG
|
||||||
msg2 "Disabling Nvidia 470xx Intel Prime driver"
|
fi
|
||||||
mkdir -p $drv_path/hybrid-intel-nvidia-470xx-prime/
|
if [ -z "$(ls $path | grep nvidia-435xx-utils 2> /dev/null)" ]; then
|
||||||
echo "" > $drv_path/hybrid-intel-nvidia-470xx-prime/MHWDCONFIG
|
msg2 "Disabling Nvidia 435xx driver"
|
||||||
|
mkdir -p $drv_path/nvidia-435xx/
|
||||||
|
echo "" > $drv_path/nvidia-435xx/MHWDCONFIG
|
||||||
|
msg2 "Disabling Nvidia 435xx Prime driver"
|
||||||
|
mkdir -p $drv_path/hybrid-intel-nvidia-435xx-prime/
|
||||||
|
echo "" > $drv_path/hybrid-intel-nvidia-435xx-prime/MHWDCONFIG
|
||||||
|
fi
|
||||||
|
if [ -z "$(ls $path | grep nvidia-440xx-utils 2> /dev/null)" ]; then
|
||||||
|
msg2 "Disabling Nvidia 440xx driver"
|
||||||
|
mkdir -p $drv_path/nvidia-440xx/
|
||||||
|
echo "" > $drv_path/nvidia-440xx/MHWDCONFIG
|
||||||
|
msg2 "Disabling Nvidia 440xx Prime driver"
|
||||||
|
mkdir -p $drv_path/hybrid-intel-nvidia-440xx-prime/
|
||||||
|
echo "" > $drv_path/hybrid-intel-nvidia-440xx-prime/MHWDCONFIG
|
||||||
|
fi
|
||||||
|
if [ -z "$(ls $path | grep xf86-video-amdgpu 2> /dev/null)" ]; then
|
||||||
|
msg2 "Disabling AMD gpu driver"
|
||||||
|
mkdir -p $drv_path/xf86-video-amdgpu/
|
||||||
|
echo "" > $drv_path/xf86-video-amdgpu/MHWDCONFIG
|
||||||
|
fi
|
||||||
|
if [ -z "$(ls $path | grep virtualbox-guest-modules 2> /dev/null)" ]; then
|
||||||
|
msg2 "Disabling VirtualBox guest driver"
|
||||||
|
mkdir -p $drv_path/virtualbox/
|
||||||
|
echo "" > $drv_path/virtualbox/MHWDCONFIG
|
||||||
fi
|
fi
|
||||||
local drv_path=$1/var/lib/mhwd/db/pci/network_drivers
|
local drv_path=$1/var/lib/mhwd/db/pci/network_drivers
|
||||||
if [ -z "$(ls $path | grep broadcom-wl 2> /dev/null)" ]; then
|
if [ -z "$(ls $path | grep broadcom-wl 2> /dev/null)" ]; then
|
||||||
|
@ -102,12 +135,12 @@ configure_mhwd_drivers(){
|
||||||
configure_lsb(){
|
configure_lsb(){
|
||||||
if [ -e $1/etc/lsb-release ] ; then
|
if [ -e $1/etc/lsb-release ] ; then
|
||||||
msg2 "Configuring lsb-release"
|
msg2 "Configuring lsb-release"
|
||||||
sed -i -e "s/^.*DISTRIB_RELEASE.*/DISTRIB_RELEASE=\"${dist_release}\"/" $1/etc/lsb-release
|
sed -i -e "s/^.*DISTRIB_RELEASE.*/DISTRIB_RELEASE=${dist_release}/" $1/etc/lsb-release
|
||||||
sed -i -e "s/^.*DISTRIB_CODENAME.*/DISTRIB_CODENAME=\"${dist_codename}\"/" $1/etc/lsb-release
|
sed -i -e "s/^.*DISTRIB_CODENAME.*/DISTRIB_CODENAME=${dist_codename}/" $1/etc/lsb-release
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
configure_branding_old(){
|
configure_branding(){
|
||||||
msg2 "Configuring branding"
|
msg2 "Configuring branding"
|
||||||
echo "---
|
echo "---
|
||||||
componentName: manjaro
|
componentName: manjaro
|
||||||
|
@ -215,249 +248,6 @@ style:
|
||||||
sidebarTextHighlight: "\"${sidebartexthighlight}"\"" > $1/usr/share/calamares/branding/manjaro/branding.desc
|
sidebarTextHighlight: "\"${sidebartexthighlight}"\"" > $1/usr/share/calamares/branding/manjaro/branding.desc
|
||||||
}
|
}
|
||||||
|
|
||||||
configure_branding(){
|
|
||||||
msg2 "Configuring branding"
|
|
||||||
echo "# SPDX-FileCopyrightText: no
|
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
|
||||||
#
|
|
||||||
# Product branding information. This influences some global
|
|
||||||
# user-visible aspects of Calamares, such as the product
|
|
||||||
# name, window behavior, and the slideshow during installation.
|
|
||||||
#
|
|
||||||
# Additional styling can be done using the stylesheet.qss
|
|
||||||
# file, also in the branding directory.
|
|
||||||
---
|
|
||||||
componentName: manjaro
|
|
||||||
|
|
||||||
|
|
||||||
### WELCOME / OVERALL WORDING
|
|
||||||
#
|
|
||||||
# These settings affect some overall phrasing and looks,
|
|
||||||
# which are most visible in the welcome page.
|
|
||||||
|
|
||||||
# This selects between different welcome texts. When false, uses
|
|
||||||
# the traditional "Welcome to the %1 installer.", and when true,
|
|
||||||
# uses "Welcome to the Calamares installer for %1." This allows
|
|
||||||
# to distinguish this installer from other installers for the
|
|
||||||
# same distribution.
|
|
||||||
welcomeStyleCalamares: ${welcomestyle}
|
|
||||||
|
|
||||||
# Should the welcome image (productWelcome, below) be scaled
|
|
||||||
# up beyond its natural size? If false, the image does not grow
|
|
||||||
# with the window but remains the same size throughout (this
|
|
||||||
# may have surprising effects on HiDPI monitors).
|
|
||||||
welcomeExpandingLogo: ${welcomelogo}
|
|
||||||
|
|
||||||
### WINDOW CONFIGURATION
|
|
||||||
#
|
|
||||||
# The settings here affect the placement of the Calamares
|
|
||||||
# window through hints to the window manager and initial
|
|
||||||
# sizing of the Calamares window.
|
|
||||||
|
|
||||||
# Size and expansion policy for Calamares.
|
|
||||||
# - "normal" or unset, expand as needed, use *windowSize*
|
|
||||||
# - "fullscreen", start as large as possible, ignore *windowSize*
|
|
||||||
# - "noexpand", don't expand automatically, use *windowSize*
|
|
||||||
windowExpanding: ${windowexp}
|
|
||||||
|
|
||||||
# Size of Calamares window, expressed as w,h. Both w and h
|
|
||||||
# may be either pixels (suffix px) or font-units (suffix em).
|
|
||||||
# e.g. "800px,600px"
|
|
||||||
# "60em,480px"
|
|
||||||
# This setting is ignored if "fullscreen" is selected for
|
|
||||||
# *windowExpanding*, above. If not set, use constants defined
|
|
||||||
# in CalamaresUtilsGui, 800x520.
|
|
||||||
windowSize: ${windowsize}
|
|
||||||
|
|
||||||
# Placement of Calamares window. Either "center" or "free".
|
|
||||||
# Whether "center" actually works does depend on the window
|
|
||||||
# manager in use (and only makes sense if you're not using
|
|
||||||
# *windowExpanding* set to "fullscreen").
|
|
||||||
windowPlacement: ${windowplacement}
|
|
||||||
|
|
||||||
### PANELS CONFIGURATION
|
|
||||||
#
|
|
||||||
# Calamares has a main content area, and two panels (navigation
|
|
||||||
# and progress / sidebar). The panels can be controlled individually,
|
|
||||||
# or switched off. If both panels are switched off, the layout of
|
|
||||||
# the main content area loses its margins, on the assumption that
|
|
||||||
# you're doing something special.
|
|
||||||
|
|
||||||
# Kind of sidebar (panel on the left, showing progress).
|
|
||||||
# - "widget" or unset, use traditional sidebar (logo, items)
|
|
||||||
# - "none", hide it entirely
|
|
||||||
# - "qml", use calamares-sidebar.qml from branding folder
|
|
||||||
# In addition, you **may** specify a side, separated by a comma,
|
|
||||||
# from the kind. Valid sides are:
|
|
||||||
# - "left" (if not specified, uses this)
|
|
||||||
# - "right"
|
|
||||||
# - "top"
|
|
||||||
# - "bottom"
|
|
||||||
# For instance, "widget,right" is valid; so is "qml", which defaults
|
|
||||||
# to putting the sidebar on the left. Also valid is "qml,top".
|
|
||||||
# While "widget,top" is valid, the widgets code is **not** flexible
|
|
||||||
# and results will be terrible.
|
|
||||||
sidebar: qml
|
|
||||||
|
|
||||||
# Kind of navigation (button panel on the bottom).
|
|
||||||
# - "widget" or unset, use traditional navigation
|
|
||||||
# - "none", hide it entirely
|
|
||||||
# - "qml", use calamares-navigation.qml from branding folder
|
|
||||||
# In addition, you **may** specify a side, separated by a comma,
|
|
||||||
# from the kind. The same sides are valid as for *sidebar*,
|
|
||||||
# except the default is *bottom*.
|
|
||||||
navigation: widget
|
|
||||||
|
|
||||||
|
|
||||||
### STRINGS, IMAGES AND COLORS
|
|
||||||
#
|
|
||||||
# This section contains the "branding proper" of names
|
|
||||||
# and images, rather than global-look settings.
|
|
||||||
|
|
||||||
# These are strings shown to the user in the user interface.
|
|
||||||
# There is no provision for translating them -- since they
|
|
||||||
# are names, the string is included as-is.
|
|
||||||
#
|
|
||||||
# The four Url strings are the Urls used by the buttons in
|
|
||||||
# the welcome screen, and are not shown to the user. Clicking
|
|
||||||
# on the "Support" button, for instance, opens the link supportUrl.
|
|
||||||
# If a Url is empty, the corresponding button is not shown.
|
|
||||||
#
|
|
||||||
# bootloaderEntryName is how this installation / distro is named
|
|
||||||
# in the boot loader (e.g. in the GRUB menu).
|
|
||||||
#
|
|
||||||
# These strings support substitution from /etc/os-release
|
|
||||||
# if KDE Frameworks 5.58 are available at build-time. When
|
|
||||||
# enabled, @{var-name} is replaced by the equivalent value
|
|
||||||
# from os-release. All the supported var-names are in all-caps,
|
|
||||||
# and are listed on the FreeDesktop.org site,
|
|
||||||
# https://www.freedesktop.org/software/systemd/man/os-release.html
|
|
||||||
# Note that ANSI_COLOR and CPE_NAME don't make sense here, and
|
|
||||||
# are not supported (the rest are). Remember to quote the string
|
|
||||||
# if it contains substitutions, or you'll get YAML exceptions.
|
|
||||||
#
|
|
||||||
# The *Url* entries are used on the welcome page, and they
|
|
||||||
# are visible as buttons there if the corresponding *show* keys
|
|
||||||
# are set to "true" (they can also be overridden).
|
|
||||||
strings:
|
|
||||||
productName: ${dist_name} Linux
|
|
||||||
shortProductName: ${dist_name}
|
|
||||||
version: ${dist_release}
|
|
||||||
shortVersion: ${dist_release}
|
|
||||||
versionedName: ${dist_name} Linux ${dist_release} "\"${dist_codename}"\"
|
|
||||||
shortVersionedName: ${dist_name} ${dist_release}
|
|
||||||
bootloaderEntryName: ${dist_name}
|
|
||||||
|
|
||||||
|
|
||||||
# These images are loaded from the branding module directory.
|
|
||||||
#
|
|
||||||
# productBanner is an optional image, which if present, will be shown
|
|
||||||
# on the welcome page of the application, above the welcome text.
|
|
||||||
# It is intended to have a width much greater than height.
|
|
||||||
# It is displayed at 64px height (also on HiDPI).
|
|
||||||
# Recommended size is 64px tall, and up to 460px wide.
|
|
||||||
# productIcon is used as the window icon, and will (usually) be used
|
|
||||||
# by the window manager to represent the application. This image
|
|
||||||
# should be square, and may be displayed by the window manager
|
|
||||||
# as small as 16x16 (but possibly larger).
|
|
||||||
# productLogo is used as the logo at the top of the left-hand column
|
|
||||||
# which shows the steps to be taken. The image should be square,
|
|
||||||
# and is displayed at 80x80 pixels (also on HiDPI).
|
|
||||||
# productWallpaper is an optional image, which if present, will replace
|
|
||||||
# the normal solid background on every page of the application.
|
|
||||||
# It can be any size and proportion,
|
|
||||||
# and will be tiled to fit the entire window.
|
|
||||||
# For a non-tiled wallpaper, the size should be the same as
|
|
||||||
# the overall window, see *windowSize* above (800x520).
|
|
||||||
# productWelcome is shown on the welcome page of the application in
|
|
||||||
# the middle of the window, below the welcome text. It can be
|
|
||||||
# any size and proportion, and will be scaled to fit inside
|
|
||||||
# the window. Use 'welcomeExpandingLogo' to make it non-scaled.
|
|
||||||
# Recommended size is 320x150.
|
|
||||||
#
|
|
||||||
# These filenames can also use substitutions from os-release (see above).
|
|
||||||
images:
|
|
||||||
# productBanner: "banner.png"
|
|
||||||
productIcon: "logo_small.svg"
|
|
||||||
productLogo: "logo.svg"
|
|
||||||
# productWallpaper: "wallpaper.png"
|
|
||||||
productWelcome: "welcome/mascot.svg"
|
|
||||||
|
|
||||||
# Colors for text and background components.
|
|
||||||
#
|
|
||||||
# - SidebarBackground is the background of the sidebar
|
|
||||||
# - SidebarText is the (foreground) text color
|
|
||||||
# - SidebarBackgroundCurrent sets the background of the current step.
|
|
||||||
# Optional, and defaults to the application palette.
|
|
||||||
# - SidebarTextCurrent is the text color of the current step.
|
|
||||||
#
|
|
||||||
# These colors can **also** be set through the stylesheet, if the
|
|
||||||
# branding component also ships a stylesheet.qss. Then they are
|
|
||||||
# the corresponding CSS attributes of #sidebarApp.
|
|
||||||
style:
|
|
||||||
sidebarBackground: "\"${sidebarbackground}"\"
|
|
||||||
sidebarText: "\"${sidebartext}"\"
|
|
||||||
sidebarTextSelect: "\"${sidebartextselect}"\"
|
|
||||||
sidebarTextHighlight: "\"${sidebartexthighlight}"\"
|
|
||||||
SidebarBackground: "\"${sidebarbackground}"\"
|
|
||||||
SidebarText: "\"${sidebartext}"\"
|
|
||||||
SidebarTextSelect: "\"${sidebartextselect}"\"
|
|
||||||
SidebarBackgroundCurrent: "\"${sidebartexthighlight}"\"
|
|
||||||
|
|
||||||
### SLIDESHOW
|
|
||||||
#
|
|
||||||
# The slideshow is displayed during execution steps (e.g. when the
|
|
||||||
# installer is actually writing to disk and doing other slow things).
|
|
||||||
|
|
||||||
# The slideshow can be a QML file (recommended) which can display
|
|
||||||
# arbitrary things -- text, images, animations, or even play a game --
|
|
||||||
# during the execution step. The QML **is** abruptly stopped when the
|
|
||||||
# execution step is done, though, so maybe a game isn't a great idea.
|
|
||||||
#
|
|
||||||
# The slideshow can also be a sequence of images (not recommended unless
|
|
||||||
# you don't want QML at all in your Calamares). The images are displayed
|
|
||||||
# at a rate of 1 every 2 seconds during the execution step.
|
|
||||||
#
|
|
||||||
# To configure a QML file, list a single filename:
|
|
||||||
# slideshow: "show.qml"
|
|
||||||
# To configure images, like the filenames (here, as an inline list):
|
|
||||||
# slideshow: [ "/etc/calamares/slideshow/0.png", "/etc/logo.png" ]
|
|
||||||
slideshow: "slideshow/SlideShow.qml"
|
|
||||||
|
|
||||||
# There are two available APIs for a QML slideshow:
|
|
||||||
# - 1 (the default) loads the entire slideshow when the installation-
|
|
||||||
# slideshow page is shown and starts the QML then. The QML
|
|
||||||
# is never stopped (after installation is done, times etc.
|
|
||||||
# continue to fire).
|
|
||||||
# - 2 loads the slideshow on startup and calls onActivate() and
|
|
||||||
# onLeave() in the root object. After the installation is done,
|
|
||||||
# the show is stopped (first by calling onLeave(), then destroying
|
|
||||||
# the QML components).
|
|
||||||
#
|
|
||||||
# An image slideshow does not need to have the API defined.
|
|
||||||
slideshowAPI: 2
|
|
||||||
|
|
||||||
|
|
||||||
# These options are to customize online uploading of logs to pastebins:
|
|
||||||
# - type : Defines the kind of pastebin service to be used. Currently
|
|
||||||
# it accepts two values:
|
|
||||||
# - none : disables the pastebin functionality
|
|
||||||
# - fiche : use fiche pastebin server
|
|
||||||
# - url : Defines the address of pastebin service to be used.
|
|
||||||
# Takes string as input. Important bits are the host and port,
|
|
||||||
# the scheme is not used.
|
|
||||||
# - sizeLimit : Defines maximum size limit (in KiB) of log file to be pasted.
|
|
||||||
# The option must be set, to have the log option work.
|
|
||||||
# Takes integer as input. If < 0, no limit will be forced,
|
|
||||||
# else only last (approximately) 'n' KiB of log file will be pasted.
|
|
||||||
# Please note that upload size may be slightly over the limit (due
|
|
||||||
# to last minute logging), so provide a suitable value.
|
|
||||||
uploadServer :
|
|
||||||
type : "fiche"
|
|
||||||
url : "http://termbin.com:9999"
|
|
||||||
sizeLimit : -1" > $1/usr/share/calamares/branding/manjaro/branding.desc
|
|
||||||
}
|
|
||||||
|
|
||||||
configure_polkit_user_rules(){
|
configure_polkit_user_rules(){
|
||||||
msg2 "Configuring polkit user rules"
|
msg2 "Configuring polkit user rules"
|
||||||
echo "/* Stop asking the user for a password while they are in a live session
|
echo "/* Stop asking the user for a password while they are in a live session
|
||||||
|
|
|
@ -59,29 +59,11 @@ mount_fs_net(){
|
||||||
track_fs -t overlay overlay -olowerdir="${work_dir}/livefs":"${work_dir}/rootfs",upperdir="$1",workdir="${mnt_dir}/work" "$1"
|
track_fs -t overlay overlay -olowerdir="${work_dir}/livefs":"${work_dir}/rootfs",upperdir="$1",workdir="${mnt_dir}/work" "$1"
|
||||||
}
|
}
|
||||||
|
|
||||||
check_umount() {
|
|
||||||
if mountpoint -q "$1"
|
|
||||||
then
|
|
||||||
umount -l "$1"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
umount_fs(){
|
umount_fs(){
|
||||||
if [[ -n ${FS_ACTIVE_MOUNTS[@]} ]]; then
|
if [[ -n ${FS_ACTIVE_MOUNTS[@]} ]]; then
|
||||||
info "overlayfs umount: [%s]" "${FS_ACTIVE_MOUNTS[@]}"
|
info "overlayfs umount: [%s]" "${FS_ACTIVE_MOUNTS[@]}"
|
||||||
#umount "${FS_ACTIVE_MOUNTS[@]}"
|
umount "${FS_ACTIVE_MOUNTS[@]}"
|
||||||
for i in "${FS_ACTIVE_MOUNTS[@]}"
|
|
||||||
do
|
|
||||||
info "umount overlayfs: [%s]" "$i"
|
|
||||||
check_umount $i
|
|
||||||
done
|
|
||||||
unset FS_ACTIVE_MOUNTS
|
unset FS_ACTIVE_MOUNTS
|
||||||
rm -rf "${mnt_dir}/work"
|
rm -rf "${mnt_dir}/work"
|
||||||
fi
|
fi
|
||||||
mount_folders=$(grep "${work_dir}" /proc/mounts | awk '{print$2}' | sort -r)
|
|
||||||
for i in $mount_folders
|
|
||||||
do
|
|
||||||
info "umount folder: [%s]" "$i"
|
|
||||||
check_umount $i
|
|
||||||
done
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -358,12 +358,9 @@ make_image_desktop() {
|
||||||
cp "${path}/desktopfs-pkgs.txt" ${iso_dir}/$(gen_iso_fn)-pkgs.txt
|
cp "${path}/desktopfs-pkgs.txt" ${iso_dir}/$(gen_iso_fn)-pkgs.txt
|
||||||
[[ -e ${profile_dir}/desktop-overlay ]] && copy_overlay "${profile_dir}/desktop-overlay" "${path}"
|
[[ -e ${profile_dir}/desktop-overlay ]] && copy_overlay "${profile_dir}/desktop-overlay" "${path}"
|
||||||
|
|
||||||
if [[ -e "${path}/usr/share/calamares/branding/manjaro/calamares-sidebar.qml" ]]; then
|
if [[ -e "${path}/usr/share/calamares/branding/manjaro/branding.desc" ]]; then
|
||||||
configure_branding "${path}"
|
configure_branding "${path}"
|
||||||
msg "Done [Distribution: Release ${dist_release} Codename ${dist_codename}]"
|
msg "Done [Distribution: Release ${dist_release} Codename ${dist_codename}]"
|
||||||
elif [[ -e "${path}/usr/share/calamares/branding/manjaro/show.qml" ]]; then
|
|
||||||
configure_branding_old "${path}"
|
|
||||||
msg "Done [Distribution: Release ${dist_release} Codename ${dist_codename}]"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
reset_pac_conf "${path}"
|
reset_pac_conf "${path}"
|
||||||
|
@ -402,19 +399,9 @@ make_image_live() {
|
||||||
copy_overlay "${profile_dir}/live-overlay" "${path}"
|
copy_overlay "${profile_dir}/live-overlay" "${path}"
|
||||||
configure_live_image "${path}"
|
configure_live_image "${path}"
|
||||||
|
|
||||||
# mask some systemd targets on live-session
|
if [[ -e "${path}/usr/share/calamares/branding/manjaro/branding.desc" ]]; then
|
||||||
mkdir -p "${path}"/etc/systemd/system
|
|
||||||
ln -sfv /dev/null "${path}"/etc/systemd/system/sleep.target
|
|
||||||
ln -sfv /dev/null "${path}"/etc/systemd/system/suspend.target
|
|
||||||
ln -sfv /dev/null "${path}"/etc/systemd/system/hibernate.target
|
|
||||||
ln -sfv /dev/null "${path}"/etc/systemd/system/hybrid-sleep.target
|
|
||||||
|
|
||||||
if [[ -e "${path}/usr/share/calamares/branding/manjaro/calamares-sidebar.qml" ]]; then
|
|
||||||
configure_branding "${path}"
|
configure_branding "${path}"
|
||||||
msg "Done [Distribution: Release ${dist_release} Codename ${dist_codename}]"
|
msg "Done [Distribution: Release ${dist_release} Codename ${dist_codename}]"
|
||||||
elif [[ -e "${path}/usr/share/calamares/branding/manjaro/show.qml" ]]; then
|
|
||||||
configure_branding_old "${path}"
|
|
||||||
msg "Done [Distribution: Release ${dist_release} Codename ${dist_codename}]"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
configure_polkit_user_rules "${path}"
|
configure_polkit_user_rules "${path}"
|
||||||
|
|
104
lib/util-yaml.sh
104
lib/util-yaml.sh
|
@ -10,7 +10,7 @@
|
||||||
# GNU General Public License for more details.
|
# GNU General Public License for more details.
|
||||||
|
|
||||||
write_machineid_conf(){
|
write_machineid_conf(){
|
||||||
local conf="${etc_config_dir}/machineid.conf"
|
local conf="${modules_dir}/machineid.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo '---' > "$conf"
|
echo '---' > "$conf"
|
||||||
echo "systemd: true" >> $conf
|
echo "systemd: true" >> $conf
|
||||||
|
@ -20,7 +20,7 @@ write_machineid_conf(){
|
||||||
|
|
||||||
write_finished_conf(){
|
write_finished_conf(){
|
||||||
msg2 "Writing %s ..." "finished.conf"
|
msg2 "Writing %s ..." "finished.conf"
|
||||||
local conf="${etc_config_dir}/finished.conf" cmd="systemctl reboot"
|
local conf="${modules_dir}/finished.conf" cmd="systemctl reboot"
|
||||||
echo '---' > "$conf"
|
echo '---' > "$conf"
|
||||||
echo 'restartNowEnabled: true' >> "$conf"
|
echo 'restartNowEnabled: true' >> "$conf"
|
||||||
echo 'restartNowChecked: false' >> "$conf"
|
echo 'restartNowChecked: false' >> "$conf"
|
||||||
|
@ -42,7 +42,7 @@ get_preset(){
|
||||||
}
|
}
|
||||||
|
|
||||||
write_bootloader_conf(){
|
write_bootloader_conf(){
|
||||||
local conf="${etc_config_dir}/bootloader.conf"
|
local conf="${modules_dir}/bootloader.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
source "$(get_preset)"
|
source "$(get_preset)"
|
||||||
echo '---' > "$conf"
|
echo '---' > "$conf"
|
||||||
|
@ -63,7 +63,7 @@ write_bootloader_conf(){
|
||||||
}
|
}
|
||||||
|
|
||||||
write_servicescfg_conf(){
|
write_servicescfg_conf(){
|
||||||
local conf="${etc_config_dir}/servicescfg.conf"
|
local conf="${modules_dir}/servicescfg.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo '---' > "$conf"
|
echo '---' > "$conf"
|
||||||
echo '' >> "$conf"
|
echo '' >> "$conf"
|
||||||
|
@ -72,67 +72,30 @@ write_servicescfg_conf(){
|
||||||
}
|
}
|
||||||
|
|
||||||
write_services_conf(){
|
write_services_conf(){
|
||||||
local conf="${etc_config_dir}/services.conf"
|
local conf="${modules_dir}/services.conf"
|
||||||
local check="${modules_dir}/services.conf"
|
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo '---' > "$conf"
|
echo '---' > "$conf"
|
||||||
echo '' >> "$conf"
|
echo '' >> "$conf"
|
||||||
if [ ! ${#enable_systemd[@]} -eq 0 ]; then
|
echo 'services:' > "$conf"
|
||||||
if [ ! $(grep "services:" ${check} | wc -l) -eq 0 ]; then
|
|
||||||
echo 'services:' >> "$conf"
|
|
||||||
else
|
|
||||||
echo 'units:' >> "$conf"
|
|
||||||
fi
|
|
||||||
for s in ${enable_systemd[@]}; do
|
for s in ${enable_systemd[@]}; do
|
||||||
if [ ! $(grep "services:" ${check} | wc -l) -eq 0 ]; then
|
|
||||||
echo " - name: $s" >> "$conf"
|
echo " - name: $s" >> "$conf"
|
||||||
else
|
|
||||||
echo " - name: $s.service" >> "$conf"
|
|
||||||
echo ' action: "enable"' >> "$conf"
|
|
||||||
fi
|
|
||||||
echo ' mandatory: false' >> "$conf"
|
echo ' mandatory: false' >> "$conf"
|
||||||
echo '' >> "$conf"
|
echo '' >> "$conf"
|
||||||
done
|
done
|
||||||
fi
|
echo 'targets:' >> "$conf"
|
||||||
if [ ! ${#enable_systemd_timers[@]} -eq 0 ]; then
|
|
||||||
[ ! $(grep "timers:" ${check} | wc -l) -eq 0 ] && echo 'timers:' >> "$conf"
|
|
||||||
for s in ${enable_systemd_timers[@]}; do
|
|
||||||
if [ ! $(grep "timers:" ${check} | wc -l) -eq 0 ]; then
|
|
||||||
echo " - name: $s" >> "$conf"
|
|
||||||
else
|
|
||||||
echo " - name: $s.timer" >> "$conf"
|
|
||||||
echo ' action: "enable"' >> "$conf"
|
|
||||||
fi
|
|
||||||
echo ' mandatory: false' >> "$conf"
|
|
||||||
echo '' >> "$conf"
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
[ ! $(grep "targets:" ${check} | wc -l) -eq 0 ] && echo 'targets:' >> "$conf"
|
|
||||||
if [ ! $(grep "targets:" ${check} | wc -l) -eq 0 ]; then
|
|
||||||
echo ' - name: "graphical"' >> "$conf"
|
echo ' - name: "graphical"' >> "$conf"
|
||||||
else
|
|
||||||
echo ' - name: "graphical.target"' >> "$conf"
|
|
||||||
echo ' action: "set-default"' >> "$conf"
|
|
||||||
fi
|
|
||||||
echo ' mandatory: true' >> "$conf"
|
echo ' mandatory: true' >> "$conf"
|
||||||
echo '' >> "$conf"
|
echo '' >> "$conf"
|
||||||
if [ ! ${#disable_systemd[@]} -eq 0 ]; then
|
echo 'disable:' >> "$conf"
|
||||||
[ ! $(grep "disable:" ${check} | wc -l) -eq 0 ] && echo 'disable:' >> "$conf"
|
|
||||||
for s in ${disable_systemd[@]}; do
|
for s in ${disable_systemd[@]}; do
|
||||||
if [ ! $(grep "services:" ${check} | wc -l) -eq 0 ]; then
|
|
||||||
echo " - name: $s" >> "$conf"
|
echo " - name: $s" >> "$conf"
|
||||||
else
|
|
||||||
echo " - name: $s.service" >> "$conf"
|
|
||||||
echo ' action: "disable"' >> "$conf"
|
|
||||||
fi
|
|
||||||
echo ' mandatory: false' >> "$conf"
|
echo ' mandatory: false' >> "$conf"
|
||||||
echo '' >> "$conf"
|
echo '' >> "$conf"
|
||||||
done
|
done
|
||||||
fi
|
|
||||||
}
|
}
|
||||||
|
|
||||||
write_displaymanager_conf(){
|
write_displaymanager_conf(){
|
||||||
local conf="${etc_config_dir}/displaymanager.conf"
|
local conf="${modules_dir}/displaymanager.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo "---" > "$conf"
|
echo "---" > "$conf"
|
||||||
echo "displaymanagers:" >> "$conf"
|
echo "displaymanagers:" >> "$conf"
|
||||||
|
@ -147,14 +110,14 @@ write_displaymanager_conf(){
|
||||||
}
|
}
|
||||||
|
|
||||||
write_initcpio_conf(){
|
write_initcpio_conf(){
|
||||||
local conf="${etc_config_dir}/initcpio.conf"
|
local conf="${modules_dir}/initcpio.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo "---" > "$conf"
|
echo "---" > "$conf"
|
||||||
echo "kernel: ${kernel}" >> "$conf"
|
echo "kernel: ${kernel}" >> "$conf"
|
||||||
}
|
}
|
||||||
|
|
||||||
write_unpack_conf(){
|
write_unpack_conf(){
|
||||||
local conf="${etc_config_dir}/unpackfs.conf"
|
local conf="${modules_dir}/unpackfs.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo "---" > "$conf"
|
echo "---" > "$conf"
|
||||||
echo "unpack:" >> "$conf"
|
echo "unpack:" >> "$conf"
|
||||||
|
@ -169,7 +132,7 @@ write_unpack_conf(){
|
||||||
}
|
}
|
||||||
|
|
||||||
write_users_conf(){
|
write_users_conf(){
|
||||||
local conf="${etc_config_dir}/users.conf"
|
local conf="${modules_dir}/users.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo "---" > "$conf"
|
echo "---" > "$conf"
|
||||||
echo "defaultGroups:" >> "$conf"
|
echo "defaultGroups:" >> "$conf"
|
||||||
|
@ -181,8 +144,6 @@ write_users_conf(){
|
||||||
echo "autologinGroup: autologin" >> "$conf"
|
echo "autologinGroup: autologin" >> "$conf"
|
||||||
echo "doAutologin: false" >> "$conf" # can be either 'true' or 'false'
|
echo "doAutologin: false" >> "$conf" # can be either 'true' or 'false'
|
||||||
echo "sudoersGroup: wheel" >> "$conf"
|
echo "sudoersGroup: wheel" >> "$conf"
|
||||||
echo "passwordRequirements:" >> "$conf"
|
|
||||||
echo " nonempty: true" >> "$conf" # can be either 'true' or 'false'
|
|
||||||
echo "setRootPassword: true" >> "$conf" # must be true, else some options get hidden
|
echo "setRootPassword: true" >> "$conf" # must be true, else some options get hidden
|
||||||
echo "doReusePassword: false" >> "$conf" # only used in old 'users' module
|
echo "doReusePassword: false" >> "$conf" # only used in old 'users' module
|
||||||
echo "availableShells: /bin/bash, /bin/zsh" >> "$conf" # only used in new 'users' module
|
echo "availableShells: /bin/bash, /bin/zsh" >> "$conf" # only used in new 'users' module
|
||||||
|
@ -192,27 +153,8 @@ write_users_conf(){
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
write_partition_conf(){
|
|
||||||
local conf="${etc_config_dir}/partition.conf"
|
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
|
||||||
echo "---" > "$conf"
|
|
||||||
echo "efiSystemPartition: \"/boot/efi\"" >> "$conf"
|
|
||||||
echo "userSwapChoices:" >> "$conf"
|
|
||||||
echo " - none # Create no swap, use no swap" >> "$conf"
|
|
||||||
echo " - small # Up to 4GB" >> "$conf"
|
|
||||||
echo " - suspend # At least main memory size" >> "$conf"
|
|
||||||
echo " - file # To swap file instead of partition" >> "$conf"
|
|
||||||
echo "alwaysShowPartitionLabels: true" >> "$conf"
|
|
||||||
echo "# There are four options: erase, replace, alongside, manual)," >> "$conf"
|
|
||||||
echo "# the default is \"none\"." >> "$conf"
|
|
||||||
echo "initialPartitioningChoice: erase" >> "$conf"
|
|
||||||
echo "initialSwapChoice: none" >> "$conf"
|
|
||||||
echo "defaultFileSystemType: \"ext4\"" >> "$conf"
|
|
||||||
echo "availableFileSystemTypes: [\"ext4\",\"btrfs\",\"f2fs\",\"xfs\"]" >> "$conf"
|
|
||||||
}
|
|
||||||
|
|
||||||
write_packages_conf(){
|
write_packages_conf(){
|
||||||
local conf="${etc_config_dir}/packages.conf"
|
local conf="${modules_dir}/packages.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo "---" > "$conf"
|
echo "---" > "$conf"
|
||||||
echo "backend: pacman" >> "$conf"
|
echo "backend: pacman" >> "$conf"
|
||||||
|
@ -227,7 +169,7 @@ write_packages_conf(){
|
||||||
}
|
}
|
||||||
|
|
||||||
write_welcome_conf(){
|
write_welcome_conf(){
|
||||||
local conf="${etc_config_dir}/welcome.conf"
|
local conf="${modules_dir}/welcome.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo "---" > "$conf" >> "$conf"
|
echo "---" > "$conf" >> "$conf"
|
||||||
echo "showSupportUrl: true" >> "$conf"
|
echo "showSupportUrl: true" >> "$conf"
|
||||||
|
@ -260,7 +202,7 @@ write_welcome_conf(){
|
||||||
}
|
}
|
||||||
|
|
||||||
write_mhwdcfg_conf(){
|
write_mhwdcfg_conf(){
|
||||||
local conf="${etc_config_dir}/mhwdcfg.conf"
|
local conf="${modules_dir}/mhwdcfg.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo "---" > "$conf"
|
echo "---" > "$conf"
|
||||||
echo "bus:" >> "$conf"
|
echo "bus:" >> "$conf"
|
||||||
|
@ -287,7 +229,7 @@ write_mhwdcfg_conf(){
|
||||||
}
|
}
|
||||||
|
|
||||||
write_postcfg_conf(){
|
write_postcfg_conf(){
|
||||||
local conf="${etc_config_dir}/postcfg.conf"
|
local conf="${modules_dir}/postcfg.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo "---" > "$conf"
|
echo "---" > "$conf"
|
||||||
echo "keyrings:" >> "$conf"
|
echo "keyrings:" >> "$conf"
|
||||||
|
@ -315,7 +257,7 @@ get_yaml(){
|
||||||
}
|
}
|
||||||
|
|
||||||
write_netinstall_conf(){
|
write_netinstall_conf(){
|
||||||
local conf="${etc_config_dir}/netinstall.conf"
|
local conf="${modules_dir}/netinstall.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo "---" > "$conf"
|
echo "---" > "$conf"
|
||||||
echo "groupsUrl: ${netgroups}/$(get_yaml)" >> "$conf"
|
echo "groupsUrl: ${netgroups}/$(get_yaml)" >> "$conf"
|
||||||
|
@ -324,7 +266,7 @@ write_netinstall_conf(){
|
||||||
}
|
}
|
||||||
|
|
||||||
write_locale_conf(){
|
write_locale_conf(){
|
||||||
local conf="${etc_config_dir}/locale.conf"
|
local conf="${modules_dir}/locale.conf"
|
||||||
msg2 "Writing %s ..." "${conf##*/}"
|
msg2 "Writing %s ..." "${conf##*/}"
|
||||||
echo "---" > "$conf"
|
echo "---" > "$conf"
|
||||||
echo "localeGenPath: /etc/locale.gen" >> "$conf"
|
echo "localeGenPath: /etc/locale.gen" >> "$conf"
|
||||||
|
@ -354,7 +296,7 @@ write_settings_conf(){
|
||||||
echo " - locale" >> "$conf" && write_locale_conf
|
echo " - locale" >> "$conf" && write_locale_conf
|
||||||
echo " - keyboard" >> "$conf"
|
echo " - keyboard" >> "$conf"
|
||||||
fi
|
fi
|
||||||
echo " - partition" >> "$conf" && write_partition_conf
|
echo " - partition" >> "$conf"
|
||||||
if ${oem_used}; then
|
if ${oem_used}; then
|
||||||
msg2 "Skipping to show users module."
|
msg2 "Skipping to show users module."
|
||||||
else
|
else
|
||||||
|
@ -404,10 +346,7 @@ write_settings_conf(){
|
||||||
echo " - initcpio" >> "$conf" && write_initcpio_conf
|
echo " - initcpio" >> "$conf" && write_initcpio_conf
|
||||||
if ${oem_used}; then
|
if ${oem_used}; then
|
||||||
msg2 "Skipping to set users module."
|
msg2 "Skipping to set users module."
|
||||||
if ${set_oem_user}; then
|
|
||||||
msg2 "Setup OEM user."
|
|
||||||
echo " - oemuser" >> "$conf"
|
echo " - oemuser" >> "$conf"
|
||||||
fi
|
|
||||||
else
|
else
|
||||||
echo " - users" >> "$conf"
|
echo " - users" >> "$conf"
|
||||||
fi
|
fi
|
||||||
|
@ -452,9 +391,8 @@ write_settings_conf(){
|
||||||
|
|
||||||
configure_calamares(){
|
configure_calamares(){
|
||||||
info "Configuring [Calamares]"
|
info "Configuring [Calamares]"
|
||||||
etc_config_dir=$1/etc/calamares/modules
|
modules_dir=$1/etc/calamares/modules
|
||||||
modules_dir=$1/usr/share/calamares/modules
|
prepare_dir "${modules_dir}"
|
||||||
prepare_dir "${etc_config_dir}"
|
|
||||||
write_settings_conf "$1"
|
write_settings_conf "$1"
|
||||||
info "Done configuring [Calamares]"
|
info "Done configuring [Calamares]"
|
||||||
}
|
}
|
||||||
|
|
|
@ -213,7 +213,7 @@ init_common(){
|
||||||
|
|
||||||
[[ -z ${log_dir} ]] && log_dir='/var/log/manjaro-tools'
|
[[ -z ${log_dir} ]] && log_dir='/var/log/manjaro-tools'
|
||||||
|
|
||||||
[[ -z ${build_mirror} ]] && build_mirror='https://mirror.easyname.at/manjaro'
|
[[ -z ${build_mirror} ]] && build_mirror='https://manjaro.moson.eu'
|
||||||
|
|
||||||
[[ -z ${tmp_dir} ]] && tmp_dir='/tmp/manjaro-tools'
|
[[ -z ${tmp_dir} ]] && tmp_dir='/tmp/manjaro-tools'
|
||||||
}
|
}
|
||||||
|
@ -409,7 +409,6 @@ load_profile_config(){
|
||||||
[[ -z ${snap_channel} ]] && snap_channel="stable"
|
[[ -z ${snap_channel} ]] && snap_channel="stable"
|
||||||
|
|
||||||
[[ -z ${multilib} ]] && multilib="true"
|
[[ -z ${multilib} ]] && multilib="true"
|
||||||
[[ ${no_multilib} == 'true' ]] && multilib="false"
|
|
||||||
|
|
||||||
[[ -z ${nonfree_mhwd} ]] && nonfree_mhwd="true"
|
[[ -z ${nonfree_mhwd} ]] && nonfree_mhwd="true"
|
||||||
|
|
||||||
|
@ -450,7 +449,6 @@ load_profile_config(){
|
||||||
[[ -z ${mhwd_used} ]] && mhwd_used='true'
|
[[ -z ${mhwd_used} ]] && mhwd_used='true'
|
||||||
|
|
||||||
[[ -z ${oem_used} ]] && oem_used='false'
|
[[ -z ${oem_used} ]] && oem_used='false'
|
||||||
[[ -z ${set_oem_user} ]] && set_oem_user='true'
|
|
||||||
|
|
||||||
[[ -z ${chrootcfg} ]] && chrootcfg='false'
|
[[ -z ${chrootcfg} ]] && chrootcfg='false'
|
||||||
|
|
||||||
|
@ -517,7 +515,6 @@ reset_profile(){
|
||||||
unset extra
|
unset extra
|
||||||
unset full_iso
|
unset full_iso
|
||||||
unset office_installer
|
unset office_installer
|
||||||
unset no_multilib
|
|
||||||
}
|
}
|
||||||
|
|
||||||
check_profile(){
|
check_profile(){
|
||||||
|
@ -836,7 +833,7 @@ create_chksums() {
|
||||||
init_profiles() {
|
init_profiles() {
|
||||||
_workdir='/usr/share/manjaro-tools'
|
_workdir='/usr/share/manjaro-tools'
|
||||||
if [[ -d ${_workdir}/iso-profiles ]]; then
|
if [[ -d ${_workdir}/iso-profiles ]]; then
|
||||||
rm -Rf ${_workdir}/iso-profiles
|
rm -Rf ${_workdir}/iso-profiles ]]
|
||||||
fi
|
fi
|
||||||
git clone -q --depth 1 -b ${branch} https://gitlab.manjaro.org/profiles-and-settings/iso-profiles.git ${_workdir}/iso-profiles/
|
git clone -q --depth 1 -b ${branch} https://gitlab.manjaro.org/profiles-and-settings/iso-profiles.git ${_workdir}/iso-profiles/
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue