• Agent641@lemmy.world
    link
    fedilink
    arrow-up
    7
    ·
    edit-2
    1 year ago

    Download Autohotkey, and create a new script. Paste these shortcuts into the script and restart the script:

    #NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.

    ; #Warn ; Enable warnings to assist with detecting common errors.

    SendMode Input ; Recommended for new scripts due to its superior speed and reliability.

    SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.

    :R*?:ddd::

    FormatTime, CurrentDateTime, yyyy-MM-dd

    SendInput %CurrentDateTime%

    return

    :R*?:dtt::

    FormatTime, CurrentDateTime, yyMMddHHmm

    SendInput %CurrentDateTime%

    Return

    Now, if you type ‘ddd’ on your keyboard, the current date will be typed out, eg ‘2023-11-23’.

    If you type ‘dtt’ tgen the datetime stamp will be typed out in YYMMDDhhmm format, eg 2311231012

    There are so many cool things you van do with AHK to make your work more productive. For example, rather tgan typing your email address a billion times, add the shortcut:

    ::add1::your.email.address@domainname.com

    And then you can type ‘add1’ and hit space, and your email address will be typed out in full. Of course, the string ‘add1’ can be whatever you want.