AutoYADM commit: 2025-07-09 14:37:26
This commit is contained in:
parent
ee833820f0
commit
f922470828
1 changed files with 7 additions and 5 deletions
|
@ -1,11 +1,13 @@
|
||||||
define-command \
|
define-command \
|
||||||
-docstring %{
|
-docstring %{
|
||||||
Insert the date, with the args passed as a string
|
Insert the date, with the args passed as a string
|
||||||
to date -d
|
to date -d.
|
||||||
} \
|
} \
|
||||||
insert-date -params 1.. %{
|
insert-date -params 0.. %{
|
||||||
evaluate-commands -draft -save-regs '|' %{
|
evaluate-commands -draft -save-regs '|"' %{
|
||||||
set-register | "date -d '%arg{@}' -f +%%Y-%%m-%%d"
|
set-register | "date -d '%arg{@}' '+%%Y-%%m-%%d' | tr -d '\n'"
|
||||||
execute-keys '|<ret>'
|
echo -debug "Inserting date: %reg{pipe}"
|
||||||
|
# we delete the trailing newline
|
||||||
|
execute-keys '!<ret>'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue