mv
This commit is contained in:
parent
ade538dc14
commit
281bb2bf37
1 changed files with 12 additions and 12 deletions
24
spcd/main.sh
24
spcd/main.sh
|
@ -298,6 +298,18 @@ spcd_os_rm() {
|
||||||
fi
|
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 │
|
# │ functions │ python │
|
||||||
# ╰───────────┴────────╯
|
# ╰───────────┴────────╯
|
||||||
|
@ -1230,18 +1242,6 @@ spcd_sed() {
|
||||||
fi
|
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
|
|
||||||
}
|
|
||||||
|
|
||||||
#╶──────────────────────────────────────╴
|
#╶──────────────────────────────────────╴
|
||||||
|
|
||||||
# ╭──────╮
|
# ╭──────╮
|
||||||
|
|
Loading…
Reference in a new issue