io/file
This commit is contained in:
parent
cafc65bf4d
commit
4d734e50ac
1 changed files with 0 additions and 0 deletions
|
@ -1,26 +0,0 @@
|
|||
# ╭──────╮
|
||||
# │ file │
|
||||
# ╰──────╯
|
||||
|
||||
rwx_file_append() {
|
||||
local file="${1}"
|
||||
local text="${2}"
|
||||
if [ -n "${file}" ]; then
|
||||
printf "%s" "${text}" >>"${file}"
|
||||
fi
|
||||
}
|
||||
|
||||
rwx_file_empty() {
|
||||
local file="${1}"
|
||||
if [ -n "${file}" ]; then
|
||||
rwx_file_write "${file}" ""
|
||||
fi
|
||||
}
|
||||
|
||||
rwx_file_write() {
|
||||
local file="${1}"
|
||||
local text="${2}"
|
||||
if [ -n "${file}" ]; then
|
||||
printf "%s" "${text}" >"${file}"
|
||||
fi
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue