Generating random passwords with Keyboard Maestro

Even though there are a dozen tools and a dozen ways to generate a password, it’s possible to do that very thing using Keyboard Maestro. Why use Keyboard Maestro? Don’t be silly. The answer is obviously, well, why not? This is a simple macro that uses a dialog to get the length of the password, uses a List (Array) to set up the password, the RAND function to pick a letter, and indexing the List to find characters. It may not be practical, but it’s educational. I use this for generating test passwords. I test account generation on a regular basis and this makes sure we can handle special character and passwords of a certain length. It automates the process so I don’t have to switch apps, copy, then paste. As you can see from the example, the first step is to prompt for the length of the password. This is stored and used in the Repeat function later on. […]

Monitoring the Downloads folder with Keyboard Maestro

When you search for folder organization, you can’t help but find Hazel. It’s a great program to help organize your files and put them where they belong. Only problem is, at $42, it’s expensive. That’s more than Keyboard Maestro, Scrivener, and a few other tools. Since I have Keyboard Maestro, I can emulate a lot of that functionality. Enter the Monitor Download Folder macro. With a combination of Keyboard Maestro and some Shell Scripting, I can move downloaded files around to keep things tidy. The first thing to do is set up a “Folder Trigger.” For this example, it’s on the Downloads folder. We also want to choose, “Ignore partial or changing files.” For most applications this works fine. But, not always for a browser. The macro may trigger before the file is done. To compensate, we can add some scripting. Borrowing a very cool solution from Jeff Hester on the Keyboard Maestro forums, we can use LSOF (List of […]

Random IP Address from Keyboard Maestro into AdGuard

The first question you may ask is, why?To retort, why not? AdGuard for Mac is the best Ad/Tracker blocker I’ve used. Among it’s great features is the ability to send a bogus IP address to servers. This helps to obscure your location. It throws of advertising and tracking data. While not foolproof, it works well enough that I have it turned on and change my IP address on a regular basis. To that end, I made an amusing Keyboard Maestro macro to generate a random IP for somewhere in the world and copy it to the clipboard. All I have to do is paste it into AdGuard and let the confusion ensue. I could type a random address or increment one of the octets, but where’s the fun in that? This is a job for Keyboard Maestro. The macro has 3 parts. It picks the first octet using the RAND function. Since there are reserved addresses, if it happens to […]

How To Create a Ram Drive Using Keyboard Maestro

While it may not be common on most computers, I am a fan of using a RAM drive. For my work Mac, this is where all my music plays from. I also play desktop videos such as beach scenes to create a festive atmosphere. I use the RAM drive to save wear on the spinning disk. Although I have a 3TB data drive for the purpose, there is no reason to play 8 hours of music, all day, every day, from a disk when memory is more efficient. In order to create a RAM drive, you need a lot of RAM. Setting one up on an 8GB machine will lead to tears. Lots of RAM is one of the reasons I love these older model Mac Pros. I can allocate 6-8GB of RAM without issue. Although it’s a rarity, when the Mac needs to reboot, such as a security update, the RAM drive disappears. After the reboot, the RAM drive […]

Prompt for User Input in Keyboard Maestro

One of the great things about Keyboard Maestro is the ability to design a UI for your macro. Using the `Prompt for User Input` block, the macro can be dynamic in how it works, or perform different functions based on user choice. The prompt can contain an entry field, checkbox, dropdown, or buttons selections. The result is stored in a variable. I have several macros with prompts, such as the size of a RAM drive, the number of times to click the mouse, a folder name, and what to rename a file. Those results are then used later in the macro or passed to the shell to move files, or create volumes. A broad list of examples can be found at the Keyboard Maestro Wiki: Keyboard Maestro- Prompt for User Input The following examples are the ones I use most: Text field: Variable and default value Checkbox: Variable and 0|1 indicating checked or not (value must be 0 or 1, […]