Show pageOld revisionsBacklinksAdd to bookCopy this pageExport to PDFFold/unfold allODT exportBack to top You've loaded an old revision of the document! If you save it, you will create a new version with this data. Media FilesToggle syntax ⬌ visual editor====== HammerSpoon ====== [[https://www.hammerspoon.org/|HammerSpoon]] is a handy automation app for Mac Once you have downloaded you should then see the hammer icon in your taskbar {{:misc:tools:pasted:20241122-201013.png}} * Right click on the hammer and go to preferences * You will first need to enable accessibility option for hammerspoon in your Mac before you can use it (you will probably need to restart hammerspoon after this to see the pref enabled) {{:misc:tools:pasted:20241122-201131.png}} * Next right the hammer and choose Open Config. This is where you add any of your automation commands. It uses a programming language called Lua. Some possible commands are listed below * Once you have added your commands and saved the config file you will need to right click on the hammer icon and choose reload config, for those commands to be loaded ---- ===== Example commands ===== === Type out contents of ClipBoard === Simulates typing of text saved in your clipboard. This is particularly useful when using Teamviewer where Windows login screens will not let you use standard paste functionality for entering passwords This code use ALT + SHIFT + V to execute the automation (but you can change the key combination used): <code> hs.hotkey.bind({"alt", "shift"}, "V", function() hs.eventtap.keyStrokes(hs.pasteboard.getContents()) end) </code> ---- === Open specific url in Chrome tab === Open a Chrome tab to a specific webpage using a key command (ALT + SHIFT + J) - in this case the TMF Jobsheets Web-app <code> hs.hotkey.bind({"alt", "shift"}, "J", function() hs.urlevent.openURLWithBundle('https://accounts.msupply.org:6710/#/daily-jobsheets-add', 'com.google.Chrome') end) </code> ---- ===== Trouble shooting ===== **Launch Hammerspoon at login preference does not stay enabled** 1) Go to System Settings > General > Login Items > Select Hammerspoon.app from Open at login list > Click minus button (-) \\ 2) Inside Hammerspoon.app click Launch at login again and it should persist. SavePreviewCancel Edit summary Links InterWiki wpwpfrwpdewpeswpplwpjpwpruwpmetadokurfcmanamazonamazon.deamazon.ukpaypalphpfnskypegooglegoogle.degousercalltotelthis Link target Link Type A page in this wiki An interwiki link An email address An link to an external page Other Link Name Type Automatic title Custom title Use an image as title Link name OKCancel Media or file Image or document file Caption / link text Image propertiesDimensions Width (px) Height (px) Alignment Default Left Center Right Linking Default Direct No link Link only Caching Default Recache Nocache OKCancel misc/tools/hammerspoon.1736468629.txt.gz Last modified: 2025/01/10 00:23by Nick Pendergrast