This commit is contained in:
Marc Beninca 2024-08-25 23:12:52 +02:00
parent ade538dc14
commit 281bb2bf37
Signed by: marc.beninca
GPG key ID: 9C7613450C80C24F

View file

@ -298,6 +298,18 @@ spcd_os_rm() {
fi
}
spcd_os_write() {
spcd_os_write__file="${1}"
spcd_os_write__text="${2}"
if [ -n "${spcd_os_write__file}" ]; then
[ -f "${spcd_os_write__file}" ] &&
spcd_os_cat "${spcd_os_write__file}"
echo "${spcd_os_write__file}"
printf "%s" "${spcd_os_write__text}" >"${spcd_os_write__file}"
spcd_os_cat "${spcd_os_write__file}"
fi
}
# ╭───────────┬────────╮
# │ functions │ python │
# ╰───────────┴────────╯
@ -1230,18 +1242,6 @@ spcd_sed() {
fi
}
spcd_os_write() {
spcd_os_write__file="${1}"
spcd_os_write__text="${2}"
if [ -n "${spcd_os_write__file}" ]; then
[ -f "${spcd_os_write__file}" ] &&
spcd_os_cat "${spcd_os_write__file}"
echo "${spcd_os_write__file}"
printf "%s" "${spcd_os_write__text}" >"${spcd_os_write__file}"
spcd_os_cat "${spcd_os_write__file}"
fi
}
#╶──────────────────────────────────────╴
# ╭──────╮