Live data from Hacker News

In Praise of AutoHotKey

hillelwayne.com

161–170 of 220 posts

Re: In Praise of AutoHotKey

#161
post #87

Earlier quoted context omitted.

Not at all. He could have written his own program and just used it, and IT would never have gotten involved. Because it was using a 3rd party tool, IT got lazy. My company, BTW, not only explicitly allows AHK, they actually encourage it. I mean, if you're going to give people compilers to write arbitrary code, this is not worse.

It seems weird to expect someone with no programming training (an IT guy) to either build or sign off on something they have no understanding of. In large/high stakes settings, being risk averse and knowing the limits of your understanding are very good traits. Imho, this IT guy did his job, more or less. What was the testing plan for this AHK script? What edge cases were considered? Unit tests, integ tests.... was t…

> It seems weird to expect someone with no programming training (an IT guy) to either build or sign off on something they have no understanding of. In large/high stakes settings, being risk averse and knowing the limits of your understanding are very good traits.

Which raises the question, why does such a person even have the authority to make calls on what software can or can not be used within the company? You shouldn't have the right to make these kind of decisions without basic understanding of how software works (beyond "I click stuff and things happen, magic!").

> What was the testing plan for this AHK script? What edge cases were considered? Unit tests, integ tests.... was there a preprod environment for it? A trial run? Can you safely roll back if / when bad data shows up? What's the retry strategy for network or up/downstream fault tolerance? Is there alarm or monitor coverage for bad scenarios?

Without understanding of how software is built, those are questions the IT guy can't possibly ask thoughtfully. They become a mere checkbox ticking exercise. And most of them don't apply anyway.

> If I were an IT guy with low level skills, I'd be proud of myself for making that hard call.

It's not a hard call. It's the easy call. The ass-covering, responsibility-mitigating, work-minimizing, consequence-free default deny call.

Re: In Praise of AutoHotKey

#162

Earlier quoted context omitted.

It seems weird to expect someone with no programming training (an IT guy) to either build or sign off on something they have no understanding of. In large/high stakes settings, being risk averse and knowing the limits of your understanding are very good traits. Imho, this IT guy did his job, more or less. What was the testing plan for this AHK script? What edge cases were considered? Unit tests, integ tests.... was t…

why even have programmers if they have to convince someone that doesn't understand what they're doing that it's been implemented correctly? the justification of an ignorant person not understanding it (assuming, i guess(?), that they are also incapable of learning it, apparently?) and thus not allowing a massively more efficient improvement to be put in place as somehow a job well done seems crazy to me. (at least in…

Everyone wants innovation, but no one wants responsibility. So anything can go as long as someone else signs off on it.

Re: In Praise of AutoHotKey

#163

Earlier quoted context omitted.

Same that would happen with the manual typing process. The workflow either includes a process for auditing data quality or it doesn't, regardless of how it was entered in.

Okay, is that a manual process or not? Why not start with automating the testing and not the entry?

Because testing is probably not done at all. And even if it was, it isn't the bottleneck in this story.

Re: In Praise of AutoHotKey

#164
post #17

I've started[1] to do similar things on macOS using Hammerspoon[2]. So far I've set it up to let me: 1. Use shift when pasting something to simulate typing in the text instead, getting around websites that block pasting. 2. Use ";" as a hyper key. By holding it down and pressing another key, I can switch between specific programs without cycling. I can also use hjkl as arrow keys. 3. Automatically switch audio input…

Why macos doesn't offer something like this by default is beyond me.

Really, there are some really smart people at apple. You know some of them have customized their environment. You know apple has internal tools.

Why don't they get it and support customization of their os?

They're also not very supportive of "outside" tools. Say you want to use python on macos. Apple has only the most passing support for it. Same with bash or anything else that could put up a dialog box or whatever without having to compile/use xcode/other barrier to entry.

applescript doesn't count.

I know you can add software like macports or homebrew, but I mean first class support from apple.

Re: In Praise of AutoHotKey

#165

I had a low paid data entry job one summer at university well over a decade ago that involved a tortuous process for digitising gas mains installation information. I discovered ahk and found I was able to install it, so I began to script the repetitive entry screens spread between multiple different programs. It allowed you to write a simple GUI form to collect various data up front. There was a lot of window picking…

> It was really quite depraved but it worked > but alas the overworked, underskilled, and somewhat frightened IT person couldn't stomach the risk this seems like a reasonable call to me.

Perhaps. It certainly wouldn't have been me that had to live with it. It might have been hard to stop using it.

To give some context this was a utility company. The gas pipes were consumer and commercial supply lines. You need to know where they are buried so people don't blow themselves up digging them up. It was safety critical.

>> It was really quite depraved but it worked

The baseline context for this, though, is a very error prone process. It was common for me to register a pipe in the technical specification (size depth etc) system and map that (by rekeying the handwritten ID) and accidentally pick a different location in the system for indicating connection of service to main pipes. You could have a service pipe (to someone's house) registered to a main in a completely different area. My script eliminated these types of errors.

The other thing to note is it didn't change the underlying process. You could, and I did, check the underlying form fills (something I wouldn't bother doing when it took 6 times as long).

I'm not trying to denigrate the individual here, he might have been doing his best given his knowledge and level of autonomy (he might also have been chickenshit) but as an organisation they let some value fall on the floor from an employee because they had no mechanism to capture and integrate it.

Re: In Praise of AutoHotKey

#167
post #87

Earlier quoted context omitted.

> It was really quite depraved but it worked > but alas the overworked, underskilled, and somewhat frightened IT person couldn't stomach the risk this seems like a reasonable call to me.

Not at all. He could have written his own program and just used it, and IT would never have gotten involved. Because it was using a 3rd party tool, IT got lazy. My company, BTW, not only explicitly allows AHK, they actually encourage it. I mean, if you're going to give people compilers to write arbitrary code, this is not worse.

So actually he didn't want to be responsible for deploying more widely. I kept on using it. I was probably not meant to.

Re: In Praise of AutoHotKey

#168
post #87

Earlier quoted context omitted.

Not at all. He could have written his own program and just used it, and IT would never have gotten involved. Because it was using a 3rd party tool, IT got lazy. My company, BTW, not only explicitly allows AHK, they actually encourage it. I mean, if you're going to give people compilers to write arbitrary code, this is not worse.

It seems weird to expect someone with no programming training (an IT guy) to either build or sign off on something they have no understanding of. In large/high stakes settings, being risk averse and knowing the limits of your understanding are very good traits. Imho, this IT guy did his job, more or less. What was the testing plan for this AHK script? What edge cases were considered? Unit tests, integ tests.... was t…

Some good points. Some more context: this made a manual process semi manual. You still had to enter the data and the target programs still flew around (on screen) on the background. I think the risk profile was similar.

> Unit tests, integ tests.... was there a preprod environment for it? A trial run? Can you safely roll back if / when bad data shows up?

Nothing of the sort :)

But... Let the adequate be the enemy of the less awful?

Re: In Praise of AutoHotKey

#169
post #26

I've started programming using Autohotkey, I just wanted a script for age of empire 2 to manage where catapult can efficiency dispatch attacks. After that I made a bot that can auto fold poker hands, it worked, with AHK you can search image on the screen and get position of the matched image. After that I made a fully functional and autonomous poker bot many years later I am now a software engineer, I just wanted to…

Yeah. I think it's also a perfect example of scope creep done right. As I understand, its original purpose was closer to remapping Caps Lock to CTRL, not to let you write a whole tiling window manager[0] for Windows in it. But now it can do both, and established itself as the unofficial Windows scripting language.

--

[0] - https://github.com/fuhsjr00/bug.n

Re: In Praise of AutoHotKey

#170
AutoHotKey!!! It single-handedly spurred my interest in software development.

I still remember my favorite scripts and miss them dearly:

- a smart "spell check" of sorts that could look at previous characters or words to contextually fix typos and expand abbreviations, powered by regex. For instance it would recognize common typos like `AUtohotkey` where your finger would linger on shift for too long. Or auto-add a closing parentheses, if the previous character wasn't a colon (in case you wanted to type `:(` etc.

- I was a huge fan of OSX and specifically wanted to have something like Quicksilver back then but could not afford a Mac. So I built Quicksilver with AutoHotKey and used that. It had a cache, contextual actions, periodic rescanning, would search not only files but also Preferences and fuzzy search with custom scoring. God I loved this thing.

Fun fact, the current logo was contributed by me waaaaay back in the day :)

Post reply on HN