cd_cat
This commit is contained in:
parent
8e0c8a88eb
commit
903e203857
1 changed files with 2 additions and 6 deletions
8
cd.sh
8
cd.sh
|
@ -109,7 +109,6 @@ local text=""
|
||||||
"
|
"
|
||||||
done
|
done
|
||||||
cd_write "${CD_DNS_FILE}" "${text}"
|
cd_write "${CD_DNS_FILE}" "${text}"
|
||||||
cd_cat "${CD_DNS_FILE}"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
cd_set_packages_repositories () {
|
cd_set_packages_repositories () {
|
||||||
|
@ -122,7 +121,6 @@ deb https://deb.debian.org/debian bookworm-backports main
|
||||||
deb https://deb.debian.org/debian bookworm-updates main
|
deb https://deb.debian.org/debian bookworm-updates main
|
||||||
deb https://deb.debian.org/debian-security bookworm-security main
|
deb https://deb.debian.org/debian-security bookworm-security main
|
||||||
"
|
"
|
||||||
cd_cat "/etc/apt/sources.list"
|
|
||||||
;;
|
;;
|
||||||
"alma") echo "TODO" ;;
|
"alma") echo "TODO" ;;
|
||||||
*) cd_error_os "cd_set_packages_repositories" ;;
|
*) cd_error_os "cd_set_packages_repositories" ;;
|
||||||
|
@ -141,7 +139,6 @@ APT::Install-Recommends False;
|
||||||
APT::Install-Suggests False;
|
APT::Install-Suggests False;
|
||||||
Dir::Etc::SourceParts \"\";
|
Dir::Etc::SourceParts \"\";
|
||||||
"
|
"
|
||||||
cd_cat "/etc/apt/apt.conf.d/apt.conf"
|
|
||||||
;;
|
;;
|
||||||
"alma") mkdir "/etc/dnf/dnf.conf.d" || exit ;;
|
"alma") mkdir "/etc/dnf/dnf.conf.d" || exit ;;
|
||||||
*) cd_error_os "cd_set_packages_configuration" ;;
|
*) cd_error_os "cd_set_packages_configuration" ;;
|
||||||
|
@ -155,13 +152,11 @@ cd_set_https_verification_off () {
|
||||||
cd_write "/etc/apt/apt.conf.d/https" "\
|
cd_write "/etc/apt/apt.conf.d/https" "\
|
||||||
Acquire::https::Verify-Peer False;
|
Acquire::https::Verify-Peer False;
|
||||||
"
|
"
|
||||||
cd_cat "/etc/apt/apt.conf.d/https"
|
|
||||||
;;
|
;;
|
||||||
"alma")
|
"alma")
|
||||||
cd_write "/etc/dnf/dnf.conf.d/https.conf" "\
|
cd_write "/etc/dnf/dnf.conf.d/https.conf" "\
|
||||||
sslverify=False
|
sslverify=False
|
||||||
"
|
"
|
||||||
cd_cat "/etc/dnf/dnf.conf.d/https.conf"
|
|
||||||
;;
|
;;
|
||||||
*) cd_error_os "cd_set_https_verification_off" ;;
|
*) cd_error_os "cd_set_https_verification_off" ;;
|
||||||
esac
|
esac
|
||||||
|
@ -293,7 +288,7 @@ ${1}
|
||||||
|
|
||||||
cd_cat () {
|
cd_cat () {
|
||||||
if [ -f "${1}" ] ; then
|
if [ -f "${1}" ] ; then
|
||||||
echo "╭$(realpath "${1}")"
|
echo "╭ $(realpath "${1}")"
|
||||||
cat "${1}" || exit
|
cat "${1}" || exit
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
@ -342,6 +337,7 @@ local text="${2}"
|
||||||
echo -n "${text}" \
|
echo -n "${text}" \
|
||||||
> "${file}" \
|
> "${file}" \
|
||||||
|| exit
|
|| exit
|
||||||
|
cd_cat "${file}"
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue