AutoYADM commit: 2025-07-13 15:44:01

This commit is contained in:
Daniel Fichtinger 2025-07-13 15:44:01 -04:00
parent fc5c32183c
commit 7800c50eeb

View file

@ -1,13 +1,15 @@
define-command \ define-command \
-docstring %{ -docstring %{
Insert the date, with the args passed as a string Replace the selections with the date, with the args passed as a
to date -d. string to date -d.
} \ } \
insert-date -params 0.. %{ insert-date -params 0.. %{
evaluate-commands -draft -save-regs '|"' %{ evaluate-commands -draft -save-regs '|"' %{
set-register | "date -d '%arg{@}' '+%%Y-%%m-%%d' | tr -d '\n'" set-register | "date -d '%arg{@}' '+%%Y-%%m-%%d' | tr -d '\n'"
echo -debug "Inserting date: %reg{pipe}" echo -debug "Inserting date: %reg{pipe}"
# we delete the trailing newline # we delete the trailing newline
execute-keys '!<ret>' execute-keys '|<ret>'
} }
} }
alias global date insert-date