[README] create template file if it doesn't exist
This commit is contained in:
parent
e42afb7d99
commit
be2e54c0fc
1 changed files with 1 additions and 0 deletions
|
@ -52,6 +52,7 @@ by following the instructions below:
|
||||||
setopt EXTENDED_GLOB
|
setopt EXTENDED_GLOB
|
||||||
for template_file ( ${ZDOTDIR:-${HOME}}/.zim/templates/* ); do
|
for template_file ( ${ZDOTDIR:-${HOME}}/.zim/templates/* ); do
|
||||||
user_file="${ZDOTDIR:-${HOME}}/.${template_file:t}"
|
user_file="${ZDOTDIR:-${HOME}}/.${template_file:t}"
|
||||||
|
touch ${user_file}
|
||||||
( print -n "$(<${template_file})\n$(<${user_file})" >! ${user_file} ) 2>/dev/null
|
( print -n "$(<${template_file})\n$(<${user_file})" >! ${user_file} ) 2>/dev/null
|
||||||
done
|
done
|
||||||
```
|
```
|
||||||
|
|
Loading…
Reference in a new issue