This sounds oh-so-much like the AmigaOS CLI, which not only has argument parsing as part of the standard library, but human-readable arguments. To list all files (not directories) recursively updated since yesterday, you write “list all files since yesterday”. To copy a file, you write “copy from this to that”, with from and to being optional. DCL users will also understand the made-up distinction between one-shot commands and interactive use.
Oh, and the notion that GUIs can’t be scripted is preposterous.
You certainly could script GitLab through Selenium, but GitLab doesn’t actually promise a stable DOM tree the same way they promise a stable API, and I’m pretty sure it would be a lot slower, too.
and you’re just lucky it even has a stable REST API
It’s not luck. Platform lock-in is their business model; every time they break their API, they make it more expensive to stay on their service (and, thus, relatively cheap to leave). It’s the same business model that Microsoft Windows follows.
A stable DOM tree isn’t the hard part. Maybe GitLab is more static than the sites I work with, but you quickly learn that there’s a difference between what you can see on the screen, what the browser knows as its DOM, and what Selenium thinks it can click or otherwise interact with at any given instant.
DCL users will also understand the made-up distinction between one-shot commands and interactive use.
i also has this, in addition to VMS. There, programs can snarf an argv that doesn’t have just strings and free of any argument parsing, and the CLI can provide consistent parsing, structured suggestions, inline help, turning a command description into a form, etc. A lot better than the ad-hoc getopt (if it’s even that, or subtly different… or worse, hugely different like dd) soup.
edit: Re-reading the article makes me realize only DCL has this, not i. i does have structured commands/prompting that VMS lacks. FWIW, the VMS/DCL one-shot/REPL modes also make it so you can fire a bunch of commands off in a script, something like:
Honestly I think you get good enough with just a --eval flag and passing it in as a string. The next level of bash scriptability from that is treating stdin as an evaluator similar to the repl but without the interactivity and then just using a heredoc.
This sounds oh-so-much like the AmigaOS CLI, which not only has argument parsing as part of the standard library, but human-readable arguments. To list all files (not directories) recursively updated since yesterday, you write “list all files since yesterday”. To copy a file, you write “copy from this to that”, with from and to being optional. DCL users will also understand the made-up distinction between one-shot commands and interactive use.
Oh, and the notion that GUIs can’t be scripted is preposterous.
You certainly could script GitLab through Selenium, but GitLab doesn’t actually promise a stable DOM tree the same way they promise a stable API, and I’m pretty sure it would be a lot slower, too.
Gitlab is just a webpage, isn’t it? It’s not even a real GUI, and you’re just lucky it even has a stable REST API.
It’s not luck. Platform lock-in is their business model; every time they break their API, they make it more expensive to stay on their service (and, thus, relatively cheap to leave). It’s the same business model that Microsoft Windows follows.
Let me put it this way: You’re lucky they have a business incentive to have a stable REST API.
As someone who uses Selenium:
A stable DOM tree isn’t the hard part. Maybe GitLab is more static than the sites I work with, but you quickly learn that there’s a difference between what you can see on the screen, what the browser knows as its DOM, and what Selenium thinks it can click or otherwise interact with at any given instant.
i also has this, in addition to VMS. There, programs can snarf an argv that doesn’t have just strings and free of any argument parsing, and the CLI can provide consistent parsing, structured suggestions, inline help, turning a command description into a form, etc. A lot better than the ad-hoc getopt (if it’s even that, or subtly different… or worse, hugely different like dd) soup.
edit: Re-reading the article makes me realize only DCL has this, not i. i does have structured commands/prompting that VMS lacks. FWIW, the VMS/DCL one-shot/REPL modes also make it so you can fire a bunch of commands off in a script, something like:
AppleScript and VBA prove this worng. Even without native hook points, @hwayne has had great success with AHK.
When you say “i”, you mean IBM i Series, the artist formerly known as OS/400?
Yes. It reminds me I should write some kind of primer for Lobsters on interesting ideas it has…
Honestly I think you get good enough with just a
--eval
flag and passing it in as a string. The next level of bash scriptability from that is treating stdin as an evaluator similar to the repl but without the interactivity and then just using a heredoc.