(I tend to post all that retrocomputing stuff on Mastodon lately. đ€)
This morningâs task: Making the thumbnails in my blog compatible with IBM WebExplorer 1.0 on OS/2 Warp 3. đ€Ș
Before:
https://movq.de/v/b7443c8873/a.jpg
After:
https://movq.de/v/b7443c8873/b.jpg
And the fix was using -define jpeg:sampling-factor=2x1
when creating the thumbnails using ImageMagick.
Iâm not really sure, though, whatâs going on. đ€
More context: https://tilde.zone/@movq/112981572946464025
(This is probably the first time Iâve seen the word âconfluenceâ being used outside of an Atlassian-related context. đ„Ž)
@xuu@txt.sour.is Which account, the ânormalâ Facebook one? đ€
(Regarding Musk: He bought Twitter, ruined it and people mass-migrated to Mastodon. So letâs let him buy Meta and do the same thing! đ€Ș)
@prologic@twtxt.net I guess Iâm more âstrictâ than you are, probably. DNS queries tell me very little about which data is actually sent to those servers.
On the other hand, this is probably a reasonable argument: The vast majority of users have no idea what a DNS query even is (and they donât care to begin with), so trying to hide something here is probably not worth the effort for Google/Apple. This would make filtering DNS requests more meaningful after all.
(But you canât be sure and that is driving me nuts. I donât want to deal with this in the first place.)
@prologic@twtxt.net Yeah, this whole thing of pre-installed third-party apps doesnât exist on the iPhone. So that appears to be a bit better. Youâre still sharing data with Apple and itâs next to impossible to tell what exactly the device does or does not do (just like with Android). If you canât easily install your own OS, then itâs a lost cause.
Best you can do with any of these devices is disconnect them from the Internet.
@prologic@twtxt.net I guess any Android phone is like that, except maybe for the Google Pixel stuff. Itâs a shit ecosystem. And so is the iPhone world. Itâs all proprietary garbage.
@lyse@lyse.isobeef.org Theyâre just playing and having fun right? đ€Ș
@prologic@twtxt.net Whoohoo! đ„ł (Table tennis, I guess?)
Just realized that phone came with a bunch of âhiddenâ Meta/Facebook services pre-installed and they cannot be uninstalled, so I guess me trying to âfightâ WhatsApp is pointless anyway. đ€Ș
⊠and then people call me a âludditeâ. đ€Łđ
@stigatle@yarn.stigatle.no Oh, I know that feeling all too well. Go for it! âïž
Also:
https://movq.de/v/8cdad1ae3a/s.png
đ
@bender@twtxt.net Sigh. đ«€ Elon Musk should buy Meta. Problem solved. đ€Ł
WhatsApp locked me out of my test account for violating their TOS. Huh? I hardly even used it? Or is that the violation â not immediately feeding them with all available data about my private life? đ€Ł
dash
or ash
, very nice POSIX Sh compliant shells:
@prologic@twtxt.net Yeah, that is part of the problem. Bash is so dominant on Linux, itâs hard to avoid. When I use #!/bin/sh
, it still gets me a Bash that does NOT enter strict POSIX mode. đ«€ The script below uses Bashisms and requests #!/bin/sh
but still runs happily âŠ
#!/bin/sh
foo=1
if [[ "$foo" == 1 ]]
then
echo match
fi
They promised rain. I ainât seeing any rain so far. đ«€
@rrraksamam@twtxt.net So ready for winter. đ„”
@falsifian@www.falsifian.org Exactly! đ„ł
So this works:
$ bash -c 'set -u; bar=1; foo=$bar; if [[ "foo" -eq "bar" ]]; then echo it matches; fi'
it matches
Without the misleading quotes:
$ bash -c 'set -u; bar=1; foo=$bar; if [[ foo -eq bar ]]; then echo it matches; fi'
it matches
As does this:
$ bash -c 'set -u; bar=1; foo=$bar; if (( foo == bar )); then echo it matches; fi'
it matches
What the person originally meant was what bender said:
$ bash -c 'set -u; foo=bar; if [[ "$foo" = "bar" ]]; then echo it matches; fi'
it matches
Itâs all rather easy once youâve understood it ⊠but the initial error message of the initial version can be quite unexpected.
@bender@twtxt.net So far, so good! And why did it complain about bar
being a variable?
I love shell scripts because theyâre so pragmatic and often allow me to get jobs done really quickly.
But sadly theyâre full of pitfalls. Pitfalls everywhere you look.
Today, a coworker â whoâs highly skilled, not a newbie by any means â ran into this:
$ bash -c 'set -u; foo=bar; if [[ "$foo" -eq "bar" ]]; then echo it matches; fi'
bash: line 1: bar: unbound variable
Whyâs that happening? I know the answer. Do you? đ
Stuff like that made me stop using shell scripts at work, unless theyâre just 4 or 5 lines of absolutely trivial code. Itâs now Python instead, even though the code is often much longer and clunkier, but at least people will understand it more easily and not trip over it when they make a tiny change.
@lyse@lyse.isobeef.org Neato! Too bad theyâre in the northern sky. Canât see that from my bedroom. đ
@johanbove@johanbove.info Allegedly itâs supposed to cool down mid-week, yeah. If we consider ~28°C âcoolâ, that is. đ
Fan = Miefquirl. đ
@prologic@twtxt.net 35°C outside. đ«€ Iâm just gonna sit here and wait for November. đ
It is too hot to think. đ„”