Intro 🔗
For some reason, I have an absolute drive for efficiency in almost everything that I do so, over the years, I’ve honed my Windows workflow to be insanely efficient and I thought I’d share some of the main ways that I’ve managed to do so.
A lot of this software I’ve mentioned previously in my blog posts “Great software” and “Great software 2” but I’ve never really posted specific details about my configuration until now.
Index 🔗
Overview of and links to sections:
AutoHotkey 🔗
AutoHotkey is a general Windows automation tool that I’ve only recently come to appreciate just how powerful it is, largely because it exposes some pretty low-level Win32 / Windows API functions in a relatively user-friendly way.
A lot of the things I wanted to accomplish I couldn’t find a solution for online so, as usual, I created almost all of these solutions from scratch myself.
Below are some excerpts from my main script that you can simply copy and paste into a .AHK
file and run yourself. Each is quite long because all pre-requisites (modes, functions, etc) are present so that they’re completely self-contained / standalone.
Note: I’ve noticed that, when editing in Notepad++, the encoding needs to be UTF-8 with BOM
in Notepad and UCS-2 LE BOM
in Notepad++ for certain things like regexes and bullet point characters to work properly for some reason.
Notepad(++): Reload edited AHK script 🔗
While not the most objectively useful, this is a small and very useful addition when making frequent changes to a single, main script (which you may very well be doing when you start reading the below) because you don’t have to right-click on the System Tray icon and click on Reload This Script
every time.
File Explorer: Automatically work around Windows' restricted characters 🔗
This is an enhanced, automated and contextual version of what I posted at https://mythofechelon.co.uk/blog/2020/3/6/how-to-work-around-windows-restricted-characters#the-workaround.
File Explorer: Copy paths or fragments of selected files / folders 🔗
There’s a well-known AutoHotkey function that uses the Windows shell COM API to get the full paths of all selected items in File Explorer which works well enough but I found it limited in that it doesn’t handle #32770 (Save As, Open, etc) windows and only returned full paths, not fragments. So, I adapted it to do so and bound it to hotkeys.
File Explorer: Automatically browse Save As / Open window to last folder open 🔗
An annoyance that I’ve had for as long as I can remember is having a folder open in File Explorer then switching to another application and having to re-browse to exactly the same folder when downloading or opening a file.
Originally, I tried to resolve this using Python and WebDriver but it seemed to be technically impossible.
Eventually, I realised that it may be possible with AutoHotkey and I successfully accomplished it!
File Explorer: Invoke rename and automatically move text cursor to end of the file name 🔗
If you have file extensions displayed in File Explorer, renaming a file is always a little bit fiddly because you have to get the cursor just before the dot. Not anymore!
(If desired, this can be massively simplified by removing the code related to toggling the end position.)
Any app: Automatically expand abbreviations for IDs 🔗
Sick of manually typing in your username, email address, phone number, etc? Hotstrings to the rescue!
(A nice simple one this time.)
Excel: Automatically expand columns for CSV files 🔗
I’d recently started regularly working with CSV files that contain long values and I got sick of having to manually expand all of the columns every single time and was surprised to find out that there’s no way to do so automatically natively.
Any app: Paste into systems that don’t support it 🔗
Every now and again, I need to paste into a system that doesn’t support it such as a web console of a server, a VM that doesn’t have host integration enabled, a web site who thinks they’re being secure, etc. This is very useful in those scenarios.
Any app: Resize window to specific resolution 🔗
Mainly due to my work with the Chrome Web Store which requires that screenshots are exactly 1280 x 800, I sometimes need to resize a window to a specific resolution which this allows me to do.
Any app: Move cursor by one pixel 🔗
I’m quite a perfectionist so, when using screenshotting tools, I don’t like to include bits outside of the section I’m capturing and this kind of pixel-level precision is difficult without things like this.
PuTTY: CTRL V to paste into console 🔗
Normally, you can only paste into a PuTTY console by right-clicking on it which is a bit annoying when you have both of your hands on the keyboard.
Excel: Tidier pasting of copied cells to other apps 🔗
Pasting copied cells from Excel tends to include all sorts of ugly trailing empty lines and unnecessary quotation marks, especially when the cell is multi-line. This corrects that.
Excel: Make Return / Enter send a new line 🔗
These days, I’m having to work with multi-line cells in Microsoft Excel a lot and, for some reason, it has a non-standard hotkey of Alt + Enter / Return to send a new line so this overrides that.
Excel: CTRL A to select all text in Find and Replace fields 🔗
Why this isn’t supported natively I have no clue.
Any app: Automatically complete function curly braces 🔗
If you work with programming / scripting such as C++, PowerShell, JavaScript, and CSS a lot, this needs no explanation.
Any app: Clear clipboard 🔗
Being ultra cybersecurity-minded and working a lot with systems that synchronise clipboards, this is quite useful.
File Explorer: Automatically close file extension rename warning prompt 🔗
Any even remotely advanced Windows user has to semi-regularly change file extensions and contend with the annoying warning window for which there’s still no option to suppress. Not anymore (kinda)!
Outlook: Automatically remove mailto: from copied email addresses 🔗
Again, why this is default behaviour in this day and age is beyond comprehension but there you go.
Any app: Disable rotation of screen 🔗
Ever accidentally pressed Alt Gr and an arrow key only to have your whole virtual world turned upside-down or on its side? This blocks that.
Outlook: Inject email’s full timestamp into preview pane 🔗
Another stupid surprise with Microsoft software: Outlook doesn’t (and can’t) allow you to see the full timestamp for an email that you’re previewing - it will only “intelligently” show the time or date. Fixed.
Any app: Enter difficult-to-type characters 🔗
Some characters are very useful but aren’t on the keyboard such as bullet points and arrows so I have hotkeys to them:
Any app: Enter current date and time 🔗
Very frequently, I need to type the current date and/or time. This allows me to do so, even in file names, thanks to my discovery I talked about in my blog post “How to work around Windows' restricted characters“!
Any app: Enter current time to nearest 5 minutes 🔗
Anyone who works in professional services is probably used to timesheets. I have my own Excel spreadsheet to automate this process but it uses start and stop times and real-life just isn’t that precise so I wrote an alternate version of the previous script to enter the current time to the nearest 5 minutes.
Outlook: Copy selected email contents with reply-like metadata 🔗
Outlook: Copy selected email headers 🔗
Keypirinha 🔗
Keypirinha can be summarised as “macOS’ Spotlight for Windows”: an extremely fast, useful, and quick-to-learn tool to launch anything from anywhere. Used correctly, this app can virtually eliminate searching for anything - files, bookmarks, apps, etc.
The only downside is that it doesn’t have an installer but I’ve created one myself, written about it in my blog post “My installer for Keypirinha”, and made them available to download at https://github.com/mythofechelon/Keypirinha/releases.
You can definitely just install this and immediately get value out of it but there are some capabilities that aren’t obvious and some tweaks that can further improve it, all of which I have detailed below.
Note: When editing configurations, you’ll probably have to refresh the configuration afterwards for it to take affect. You can do this by right-clicking on the System Tray icon and selecting Refresh Catalog…
and/or Reload Configuration
.
Keypirinha configuration 🔗
The Keypirinha app itself is extensively customisable. To see the possibilities and/or edit the config, right-click on the System Tray icon, select Configure Keypirinha
, and see the left-hand window.
Personally, I only customise a few things here:
Change the default monitor that the interface opens on from the primary to the active one.
Change the default the hotkey to open the interface from
Ctrl
+Win
+K
(which is a bit awkward to use) toCtrl
+Space
.Set the hotkey to open the interface with history (useful if you regularly perform the same actions) to
Ctrl
+Shift
+Space
.
To implement this, simply copy the below and paste into the right-hand window:
[gui]
geometry = active_monitor
[app]
hotkey_run = Ctrl+Space
hotkey_history = Ctrl+Shift+Space
Native package: Apps 🔗
The Apps package is basically responsible for indexing file system content. By default, it indexes the following locations:
Start Menu
Desktop
PATH
environment variable
This can be expanded to index entire folders and subfolders, specific files, specific file types in folders, etc.
To customise this, right-click on the System Tray icon, hover over Configure Package
, and select Apps
. Below is an example custom configuration for this:
[main]
extra_paths=
D:\Users\${env:userName}\Documents\RDP\**\*.rdp
${env:Dropbox}\IT\Knowledge Base\**\*.txt
Native package: Bookmarks 🔗
The Bookmarks package indexes bookmarks / favourites in the following web browsers (in roughly decreasing order of popularity):
Google Chrome
Internet Explorer
Firefox
Chromium (generic version)
Google Chrome Canary (experimental version)
Misc (Falkon / QupZilla, Iridium, Vivaldi, Buku)
In my experience, Chromium browsers such as Opera or the new Microsoft Edge aren’t supported by default so this can be achieved by right-clicking on the System Tray icon, hovering over Configure Package
, selecting Bookmarks
, pasting the following into the right-hand window, and saving the changes.
[provider/Chromium]
bookmarks_files =
${env:userProfile}\AppData\Roaming\Opera Software\Opera Stable\Bookmarks
${env:userProfile}\AppData\Local\Microsoft\Edge\User Data\Default\Bookmarks
Native package: Calc 🔗
This package is capable of some pretty advanced calculations (see https://keypirinha.com/packages/calc.html) but even for pretty basic stuff it’s useful to see the history, the calculation update as you go, and be able to press enter to copy the result.
Native package: GoogleTranslate 🔗
As a learner of Portuguese (European, not Brazilian), it’s very useful to immediately translate a word or phrase in either language from anywhere.
By default, it auto-detects the source language and translates to English (which can be customised, as with the other packages) but a specific source and destination language can be specified. For example, en:pt <to translate>
.
Third-party packages 🔗
Third-party packages are available from anywhere as .keypirinha-package
files and should be copied to the following folders:
If Keypirinha has been installed:
<Keypirinha folder>\default\Packages\
.
UsuallyC:\Program Files (x86)\Keypirinha\default\Packages
or%appData%\Keypirinha\InstalledPackages\
.If Keypirinha is running in portable mode:
<Keypirinha folder>\portable\Profile\InstalledPackages\
Alternatively, you can use the PackageControl third-party package available at https://github.com/ueffel/Keypirinha-PackageControl to automate the rest.
A full list of officially-recognised packages are available at https://keypirinha.com/contributions.html. The following are my favourites.
Third-party package: Currency 🔗
Available at https://github.com/AvatarHurden/keypirinha-currency/releases, by default, this app updates daily and converts between currencies.
To make the syntax easier to use, right-click on the System Tray icon, hover over Configure Package
, select Currency
, enter the below configuration in the right-hand window, and save the changes.
[aliases]
GBP = £
USD = $$
EUR = €
Third-party package: Cvt 🔗
Available at https://github.com/DrorHarari/keypirinha-cvt/releases, this package provides unit conversions for the following measures:
Data Size
Distance
Area
Volume
Mass
Speed
Time
Force
Pressure
Energy
Power
Fuel Consumption
Temperature
The syntax is <number> <unit from> <unit to>
.
Third-party package: Epoch 🔗
Available at https://github.com/prayzzz/keypirinha-epoch, if you work with Unix epoch timestamps a lot as I do, this will make your life that bit easier. By default, the package displays the current time in various formats but you can also paste an epoch timestamp to convert it into something human-readable.
Third-party package: MyIP 🔗
Available at https://github.com/Fuhrmann/keypirinha-myip, this package provides a super fast, super simple way to quickly get your PC’s private or public IP address.
Third-party package: WindowsApps 🔗
Available at https://github.com/ueffel/Keypirinha-WindowsApps, this app indexes:
Metro / Universal Windows Platform (UWP) apps such as Camera, Cortana, Mail, Microsoft Store, and Xbox Game Bar.
Windows Settings such as Apps & features, Clipboard, Default apps, Network status, and Windows Update.
Hashing and Base64 too
And the settings only get deeper! In fact, this tool so extensive that I’ve simply recreated my own configuration and made the file available to download here: https://mythofechelon.co.uk/s/mythofechelons-ShareX-1330-settings.sxb
If, like me, you need to regularly take screenshots (sometimes in rapid succession such as during a live event), annotate screenshots, and take screen recordings, I don’t think there’s a more efficient way to do so.
Be sure to set up screen recording properly:
Open the main interface
Select
Task settings…
→Screen recorder
→Screen recording options…
Under
FFmpeg path
, selectDownload
Under
Sources
, selectInstall recorder devices
and proceed through the installer
Notepad++ 🔗
Notepad++ is like Notepad on steroids. Tabs, macros, highlighting, plugins, customisable UI, spell-checking, etc etc.
Personally, I find that Notepad++ is so extensive that it can actually be counter productive so I’ve stripped back its keyboard shortcuts, context menu, language options, etc to what I actually use.
Similar to ShareX, I’ve made my configuration available to download here: https://mythofechelon.co.uk/s/mythofechelons-Notepad-settings.zip
Simply close the app (this generates the files that need to be overwritten) and then paste the .XML
files into the folder %appData%\Notepad++\
. The 3 files are as follows:
config.xml
: Includes settings for the application in general.contextMenu.xml
: Includes settings for the in-app right-click menu.shortcuts.xml
: Includes settings for the keyboard shortcuts and macros.
Macros 🔗
Included in my config are my custom macros which I’ve created over my years working as an IT, network, and cybersecurity engineer.
Below, I have listed them all, with demonstrations for the particularly useful ones:
Convert American date format to ISO 8601 date format
Convert British date format to ISO 8601 date format
Convert certificate thumbprint to hash
: Useful when working with Windows certificate managerConvert IP addresses to sortable format
. Demonstrated below:Convert IP addresses from sortable format
. Demonstrated below:
Convert MAC address from Windows ARP to standard
Convert MAC address from Windows ARP to Windows DHCP
Convert MAC address from standard to Windows ARP
Convert MAC address from standard to Windows DHCP
Convert to Exchange alias format
Convert URLs to hosts
. Demonstrated below:
Count non-blank lines (open find window before running)
Encode Splunk search
. Useful when embedding a search as a URL. Not quite the same as URL encoding due to Splunk special characters such as$
. Demonstrated below:
Find all IPv4 addresses
Find all IPv4 subnets
Remove Event Viewer XML
Remove regex group names
Replace 3 or more blank lines with 2
Replace commas with newlines
Replace commas with pipes
Replace newlines with commas
Replace newlines with pipes
Replace newlines with tabs
Replace pipes with newlines
Replace tabs with commas
Third-party plugins 🔗
Plugins can either be installed via the built-in plugin manager at Plugins
→ Plugins Admin…
or by pasting the folder or DLL file into the folder C:\Program Files (x86)\Notepad++\plugins\
.
Personally, my favourites are as follows:
Compare
: Useful for comparing two text fields for differences.DSpellCheck
. Tip: This doesn’t do anything until you download a dictionary / language which you can do viaPlugins
→DSpellCheck
→Change Current Language
→Download Languages...
Location Navigate
: Useful when regularly jumping back and forth between viewed or edited positions within the same file or between different files.jN
→ Smart Highlighter: When double-clicking on a string or searching via Find, partial and whole matches found in any view are highlighted in the editing pane and on the scrollbar.
Tips 🔗
Here are some miscellaneous useful things that I’ve learned over time:
Holding down
Alt
will allow you to select text vertically. This is useful if, for example, you want to copy a block of text without the indentations or delete the start of multiple lines that begin the same way.In the subwindow
Find result
that’s brought up by theFind All in Current Document
andFind All in All Opened Documents
options,Ctrl
+C
will retain the line numbers but right-clickCopy
will not.If you want to use a macro that simply searches then you need to open the
Find
window before you run it.
QTTabBar 🔗
QTTabBar is a very useful extension for File Explorer.
As with most of these tools, this app can do a lot more than what I use it for.
Installation 🔗
One you have run the EXE file and completed the installation wizard, you will need to:
Restart
explorer.exe
. Be aware that instances of File Explorer will not be re-opened. You can do this by:Opening File Explorer.
Right-clicking on an empty space of the Taskbar.
Selecting
Task Manager
.Under the tab
Processes
and the sectionApps
, selectWindows Explorer
then the buttonRestart
. If you can’t do this for whatever reason then it’s easier to just sign out and in or restart the PC.
Enable the toolbar(s). You can do this by:
Opening File Explorer.
Selecting the tab
View
.In the group
Show/hide
, underneath the buttonOptions
, select the downwards-pointing arrow.Select
QTTabBar
and any others you wish to show.
Navigation 🔗
QTTabBar accelerates File Explorer navigation with the following web browser-like UI improvements:
Multiple tabs per window.
Open folder in new tab via middle click.
Close tab via middle click.
Re-open closed tab via
Ctrl
+Shift
+Z
(keyboard shortcuts can be changed).Browse to parent folder via double click on empty space.
Preview 🔗
QTTabBar allows you to quickly preview the contents of folders by clicking on an overlayed button and even the contents of common file types such as text, image, and video by simply hovering over them.
Save as Shortcut 🔗
Sometimes, you can’t find a tool to do what you need so you just have to create one yourself!
Back in November 2012, I realised that it was more useful to have some shortcuts alongside the other files, rather solely in the web browser on one PC, so I started work on this Google Chrome extension to automate the process.
Nowadays, it can do a lot more:
Save the current tab as one file or all opened tabs as a ZIP file.
Supported shortcut file types:
Cross-platform .HTML
Windows-specific .URL
macOS-specific .WEBLOC
Linux-specific .DESKTOP
Save via GUI, context menu, or keyboard shortcut.
Option for custom naming formats including various variables.
Option to automatically replace Windows invalid characters.
Option to automatically strip out the site name.
Option to automatically remove notification indicators.
Option to preserve the tab order in archive / ZIP files.
Guidance on how to change browser settings and diagnose extension issues.
Sign-off 🔗
I hope that this has been useful.
Feel free to subscribe to my newsletter to be automatically notified of new blog posts in the future.
😊