7,427 karma · joined February 3, 2014
[ my public key: https://keybase.io/jnrowe; my proof: https://keybase.io/jnrowe/sigs/orH3nyNqAK4vkIpcxn2HRihHPV2HX80SyDwM9cR5xnw ]
I'm purposely being careful too. Big backoff on any error, curl's --time-cond from git commit timestamp, etag where possible, etc.
I'm not particularly concerned about an actual DoS'ing issue, more being on the end of one of those stories that pops up every so often("website owner sics lawyers on F12").
Have you had any pushback from the sources you've been scraping with actions? I can't imagine how lightly hitting GitHub from this action is a problem, but a few of the other scrapers you've discussed are hitting resources in ways we've definitely seen website operators get upset about before.
I ask because I've been playing with a couple of scrapers for info I'm interested in, but I'm a little reluctant to toggle the repo visibility switch. Partly, because I don't want the grief and selfishly because I don't want the source to disappear.
The situation - as I see it - is that we have a spec, and we have systems that ship a /bin/sh that implements something like it. If people are targetting their system's /bin/sh, then they're writing scripts for their /bin/sh implementation not posix compliant shells. For example, my install uses dash which has features beyond the posix spec which I have to eschew to produce portable scripts.
As a sibling comment points out shellcheck will point out a lot problems, but it requires people choosing to use it. You only have to dive around /usr/bin for a little while to see its usage isn't universal ;)
Of course, if the differences in implementation don't affect your usecase then it simply doesn't matter.
Although making such an error in my example doesn't seem to invalidate my point. It takes an already odd syntax and makes it subtly different, instead of tightening it up.
Still, if bash works for you keep using bash ;)
¹ https://www.oilshell.org/blog/2021/01/why-a-new-shell.html
And that also feels like the problem with extending a script with a few bashisms too, as you're suddenly trying to remember when that feature appeared. Off the top of my head I'm wondering what things won't be available to Mac users because it ships with a pre-GPLv3 bash for example.
I think I'd prefer bash's noclobber behaviour to be the default redirection style. The explicitness of being forced to >| always feels like a nice safety feature to me, which would tie in nicely with their other defaults for safer scripting.
Also, not sure I'm keen on their minor change to the redirection syntax¹. It suggests that "2>1" and "2> 1" have very different results, which feels like an odd change to make when you're keeping the other aspects of that syntax. Probably says more about me though, I want 100% match or a complete break to force me to think.
I think it is interesting to compare the approach of oil², which has overlapping goals but is attacking the problem of improving shell scripting while attempting to keep the syntax.
¹ https://hush-shell.github.io/cmd/basic.html
(note: if - like me - you're not seeing syntax highlighting for hush then enable JS)
¹ https://hush-shell.github.io/error-handling.html#try-operato...
It would be nice if there wasn't an early exit when a matching directory is found in `def.config`. That way you could have multiple matches for a directory, and it would make simple stacking work for subdirectories too. The current behaviour makes subdirectory matches odd insofar as the behaviour is dependent on the order of entries in `def.config`.
A couple of minor notes in the spirit of helpful commentary:
• You're creating a global `line` variable while reading the config, using `setopt warn_create_global` is a great built-in feature to highlight these during development.
• You can perform tilde expansion with `${~var}` instead of needing to run sed(see GLOB_SUBST in the zsh docs). This would also make zsh's named directory support work in the config.
• There are shell constructs to remove the need for cut too: First word `${line%% *}`, other words `${line#* }`.
¹ https://www.gnu.org/software/rcs/manual/html_node/Concepts.h...
² https://lists.gnu.org/archive/html/info-gnu/2022-02/msg00001...
Much like the emacs feature it is useful outside this specific use case too, and it can be a great way to perform heavy edits without needing to care about boundaries and such.
Most attempts at vim modes in other applications seem to be insert or "move" mode, with practically no functionality in what they call normal mode. Whereas evil emulates largely most of vim(far behind normal and insert modes too), but when it does eventually fall down you're really not expecting it. My go-to example for this is using the expression register, the number of times I've typed a vim expression in to emacs when using the expression register is ridiculous.
When tools aren't so functional you're basically always expecting them to fail, so it isn't such a shock when you can't even ciw or whatever. My point -- or perhaps question -- is what is really the better solution; one which almost 100% seamless or one which is practically useless from the outset.
"Note: The existence of unsnap is merely a tool to enable users to switch from snapped applications to flatpak applications. This is not intended as a commentary or slight against any software. It's just a utility."
I seem to recall there being some really intriguing TGV tunnel hoods with various suppressor designs to reduce the noise to surrounding villages, but I can't find them now. Anyone know of a good gallery or site for them?
"Maintenance status: The xi-editor project is not currently under active development. Although we will happily accept bug fixes, no new features are currently planned. We would like to revisit writing a text editor again at some point in the future, but for the time being our attention is elsewhere." — The Editors
The dump-html function also exists in xterm, should you want to remember what XHTML looks like ;)
It would be amazing if either could be used to make quick animated and automated session logs for demos or to attach to bug reports.
¹ https://invisible-island.net/xterm/manpage/xterm.html#Main-O...
$ zmodload -F zsh/datetime p:EPOCHSECONDS
$ printf "%'d" $EPOCHSECONDS
1,648,943,504Even watching it again now the World 1 section is like "what? okay", and then the World 7 part hits in me in the face again. It feels like there is magician about to pull a rabbit from a hat, but it turns out the rabbit is a actual esquilax and the hat was a rainbow unicorn nest and the magician was a ghost from the outset.