forked from mirrored-repos/manjaro-tools
rm trailing whitespace
This commit is contained in:
parent
6054f09efc
commit
3917a6818e
1 changed files with 53 additions and 53 deletions
106
lib/util.sh
106
lib/util.sh
|
@ -246,10 +246,10 @@ init_buildpkg(){
|
|||
|
||||
get_iso_label(){
|
||||
local label="$1"
|
||||
#label="${label//_}" # relace all _
|
||||
label="${label//-}" # relace all -
|
||||
label="${label^^}" # all uppercase
|
||||
label="${label::32}" # limit to 32 characters
|
||||
#label="${label//_}" # relace all _
|
||||
label="${label//-}" # relace all -
|
||||
label="${label^^}" # all uppercase
|
||||
label="${label::32}" # limit to 32 characters
|
||||
echo ${label}
|
||||
}
|
||||
|
||||
|
@ -316,16 +316,16 @@ init_buildiso(){
|
|||
[[ -z ${iso_compression} ]] && iso_compression='zstd'
|
||||
|
||||
[[ -z ${kernel} ]] && kernel="linux54"
|
||||
|
||||
|
||||
load_run_dir "${profile_repo}"
|
||||
|
||||
|
||||
if [[ -d ${run_dir}/.git ]]; then
|
||||
current_path=$(pwd)
|
||||
cd ${run_dir}
|
||||
branch=$(git rev-parse --abbrev-ref HEAD)
|
||||
cd ${current_path}
|
||||
current_path=$(pwd)
|
||||
cd ${run_dir}
|
||||
branch=$(git rev-parse --abbrev-ref HEAD)
|
||||
cd ${current_path}
|
||||
else
|
||||
[[ -z ${branch} ]] && branch="v18.0" #current branch release
|
||||
[[ -z ${branch} ]] && branch="v18.0" #current branch release
|
||||
fi
|
||||
|
||||
[[ -z ${gpgkey} ]] && gpgkey=''
|
||||
|
@ -334,26 +334,26 @@ init_buildiso(){
|
|||
}
|
||||
|
||||
init_calamares(){
|
||||
|
||||
[[ -z ${welcomestyle} ]] && welcomestyle=false
|
||||
|
||||
[[ -z ${welcomelogo} ]] && welcomelogo=true
|
||||
|
||||
[[ -z ${windowexp} ]] && windowexp=noexpand
|
||||
|
||||
[[ -z ${windowsize} ]] && windowsize="800px,520px"
|
||||
|
||||
[[ -z ${windowplacement} ]] && windowplacement="center"
|
||||
|
||||
[[ -z ${sidebarbackground} ]] && sidebarbackground=#454948
|
||||
|
||||
[[ -z ${sidebartext} ]] && sidebartext=#efefef
|
||||
|
||||
[[ -z ${sidebartextselect} ]] && sidebartextselect=#4d915e
|
||||
|
||||
[[ -z ${sidebartexthighlight} ]] && sidebartexthighlight=#1a1c1b
|
||||
[[ -z ${welcomestyle} ]] && welcomestyle=false
|
||||
|
||||
[[ -z ${welcomelogo} ]] && welcomelogo=true
|
||||
|
||||
[[ -z ${windowexp} ]] && windowexp=noexpand
|
||||
|
||||
[[ -z ${windowsize} ]] && windowsize="800px,520px"
|
||||
|
||||
[[ -z ${windowplacement} ]] && windowplacement="center"
|
||||
|
||||
[[ -z ${sidebarbackground} ]] && sidebarbackground=#454948
|
||||
|
||||
[[ -z ${sidebartext} ]] && sidebartext=#efefef
|
||||
|
||||
[[ -z ${sidebartextselect} ]] && sidebartextselect=#4d915e
|
||||
|
||||
[[ -z ${sidebartexthighlight} ]] && sidebartexthighlight=#1a1c1b
|
||||
}
|
||||
|
||||
|
||||
|
||||
init_deployiso(){
|
||||
|
||||
|
@ -386,8 +386,8 @@ load_config(){
|
|||
|
||||
init_buildiso
|
||||
|
||||
init_calamares
|
||||
|
||||
init_calamares
|
||||
|
||||
init_deployiso
|
||||
|
||||
return 0
|
||||
|
@ -611,7 +611,7 @@ load_pkgs(){
|
|||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
|
||||
# We can reuse this code
|
||||
local _edition _edition_rm
|
||||
case "${edition}" in
|
||||
|
@ -660,7 +660,7 @@ load_pkgs(){
|
|||
| sed "$_extra" \
|
||||
| sed "$_extra_rm" \
|
||||
| sed "$_office" \
|
||||
| sed "$_office_rm" \
|
||||
| sed "$_office_rm" \
|
||||
| sed "$_clean")
|
||||
|
||||
if [[ $1 == "${packages_mhwd}" ]]; then
|
||||
|
@ -824,25 +824,25 @@ create_chksums() {
|
|||
sha256sum $1 > $1.sha256
|
||||
}
|
||||
|
||||
init_profiles() {
|
||||
_workdir='/usr/share/manjaro-tools'
|
||||
if [[ -d ${_workdir}/iso-profiles ]]; then
|
||||
rm -Rf ${_workdir}/iso-profiles ]]
|
||||
fi
|
||||
git clone -q --depth 1 -b ${branch} https://gitlab.manjaro.org/profiles-and-settings/iso-profiles.git ${_workdir}/iso-profiles/
|
||||
|
||||
#Check if git clone is done
|
||||
if [[ -d ${_workdir}/iso-profiles/manjaro ]] && [[ -d ${_workdir}/iso-profiles/community ]]; then
|
||||
|
||||
for i in ${_workdir}/iso-profiles/.gitignore ${_workdir}/iso-profiles/README.md; do
|
||||
rm -f $i
|
||||
done
|
||||
|
||||
for i in ${_workdir}/iso-profiles/.git ${_workdir}/iso-profiles/sonar; do
|
||||
rm -Rf $i
|
||||
done
|
||||
else msg2 "Impossible to initialize iso-profiles, please check internet connection or browse at 'https://gitlab.manjaro.org/profiles-and-settings/iso-profiles'"
|
||||
exit 1
|
||||
fi
|
||||
init_profiles() {
|
||||
_workdir='/usr/share/manjaro-tools'
|
||||
if [[ -d ${_workdir}/iso-profiles ]]; then
|
||||
rm -Rf ${_workdir}/iso-profiles ]]
|
||||
fi
|
||||
git clone -q --depth 1 -b ${branch} https://gitlab.manjaro.org/profiles-and-settings/iso-profiles.git ${_workdir}/iso-profiles/
|
||||
|
||||
#Check if git clone is done
|
||||
if [[ -d ${_workdir}/iso-profiles/manjaro ]] && [[ -d ${_workdir}/iso-profiles/community ]]; then
|
||||
|
||||
for i in ${_workdir}/iso-profiles/.gitignore ${_workdir}/iso-profiles/README.md; do
|
||||
rm -f $i
|
||||
done
|
||||
|
||||
for i in ${_workdir}/iso-profiles/.git ${_workdir}/iso-profiles/sonar; do
|
||||
rm -Rf $i
|
||||
done
|
||||
else msg2 "Impossible to initialize iso-profiles, please check internet connection or browse at 'https://gitlab.manjaro.org/profiles-and-settings/iso-profiles'"
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue