I have a job where a part of our job is to write comments on some entries. Such as if we have edited it. This same string can get quite repetitive. Writing out initials followed by the current date. It would be amazing to have a script so each time you press a shortcut command, this script will fire and type out in the looks of "ABC YYYY-MM-DD: ". Making that process simpler. I’m quite new to Linux and thought maybe the community has some ideas. (We aren’t allowed to install any type of software due to security purposes. So if something already comes pre-baked within Ubuntu, would be quite neat! :P)

  • Maiq@lemy.lol
    link
    fedilink
    arrow-up
    0
    ·
    9 days ago

    You could write a simple python script using datetime and pyperclip. Datetime would supply the date format and pyperclip to copy that to your clipboard. You could setup a key binding to call the script then [Ctrl + v] to paste.

    I believe all linix distros have python installed OTB.

    There are probably a bash solution but my bash is rubbish.