The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,862 other subscribers

Archive for the ‘Software Development’ Category

Quick batch file hack to download a file calling PowerShell to do the heavy lifting

Posted by jpluimers on 2025/08/12

I needed this download-file.bat a while ago, but forgot how I found out.

It’s in this gist too: [Wayback/Archive] Quick batch file hack to download a file calling PowerShell to do the heavy lifting.

Here we go: Read the rest of this entry »

Posted in .NET, Batch-Files, CommandLine, Development, Power User, PowerShell, PowerShell, Scripting, Software Development, Windows, Windows 10, Windows 11, Windows 8.1 | Leave a Comment »

html – What can cause Chrome to give an net::ERR_FAILED on cached content against a server on localhost? – Stack Overflow

Posted by jpluimers on 2025/08/07

On my research list [Wayback/Archive] html – What can cause Chrome to give an net::ERR_FAILED on cached content against a server on localhost? – Stack Overflow

The reason what that back then this would fail (but worked in Firefox and Safari, and because I was in a hurry I didn’t research further): [Wayback/Archive] https://www.office.com/

This site can’t be reached

The webpage at https://www.office.com/ might be temporarily down or it may have moved permanently to a new web address.

ERR_FAILED

Thanks [Wayback/Archive] Mason Wheeler and [Wayback/Archive] Joel Davey.

Details:

Read the rest of this entry »

Posted in Chrome, Communications Development, Development, Encryption, HTTP, https, HTTPS/TLS security, Power User, Security, TCP, TLS, Web Browsers, Web Development | Leave a Comment »

Looking for an alternative to the (now dead) ZXing Barcode Scanner – Apps on Google Play

Posted by jpluimers on 2025/08/07

Edit 20250807: (thanks [Wayback/Archive] twm/dummzeuch!) at [Wayback/Archive] dummzeuch: “@wiert yeah, I found out about…” – Mastodon

@wiert yeah, I found out about this a few weeks ago, when I wanted to install it on my new phone.
I switched to this one:

gitlab.com/Atharok/BarcodeScan

But I haven’t used it enough to be able to make a final evaluation.

So I will try [Wayback/Archive] Atharok / Barcode Scanner · GitLab with the install from the Android App-store [Wayback/Archive] Scanner: QR Code and Products – Apps on Google Play.

Original post:

Read the rest of this entry »

Posted in Android, Development, Mobile Development, Software Development | Tagged: | Leave a Comment »

linux – Get final URL after curl is redirected – Stack Overflow (plus some Twitter scraping tricks)

Posted by jpluimers on 2025/08/06

Sometimes I need [Wayback/Archive] Redirect Checker | Check your Statuscode 301 vs 302 on the command-line, so cURL to the rescue: [Wayback/Archive] linux – Get final URL after curl is redirected – Stack Overflow. The relevant portions of answers and comments further below.

TL;DR:

Since I prefer verbose command-line arguments (you can find them at the [Wayback/Archive] curl – How To Use on-line man page) especially in scripts this HTTP GET request is what works with Twitter:

% curl --location --silent --output /dev/null --write-out "%{url_effective}\n" https://twitter.com/anyuser/status/20
https://x.com/anyuser/status/20

This failed (twitter dislikes HTTP HEAD requests):

% curl --head --location --silent --output /dev/null --write-out "%{url_effective}\n" https://twitter.com/anyuser/status/20
https://twitter.com/anyuser/status/20

Notes

Given so many of my scripts now run on zsh, I added the new-line because of command line – Why does a cURL request return a percent sign (%) with every request in ZSH? – Stack Overflow. You can strip that bit.

Note that these do not perform client side redirects, so they do not return the ultimate originating URL https://x.com/jack/status/20 (which was the first ever Tweet on what was back then called twttr) as Twitter on the client-side overwrites window.location.href with the final URL. Similar behaviour for getting the Twitter user handle of a Twitter user ID, more on Twitter tricks below.

Tweet by TweetID trick via [Wayback/Archive] Accessing a tweet using only its ID (and without the Twitter API) – Bram.us.

Further reading (thanks [Wayback/Archive] vise, [Wayback/Archive] Daniel Stenberg, [Wayback/Archive] Ivan, [Wayback/Archive] AndrewF, [Wayback/Archive] Roger Campanera, and [Wayback/Archive] Dave Baird):

Read the rest of this entry »

Posted in *nix, *nix-tools, bash, Batch-Files, Bookmarklet, Communications Development, Conference Topics, Conferences, CSS, cURL, Development, Event, HTTP, Internet protocol suite, JavaScript/ECMAScript, Power User, Scripting, SocialMedia, Software Development, TCP, Twitter, Web Browsers, Web Development | Tagged: | Leave a Comment »

Tootski, a sharing bookmarklet for Mastodon · GitHub

Posted by jpluimers on 2025/08/05

For my research list: [Wayback/Archive] Tootski, a sharing bookmarklet for Mastodon · GitHub

--jeroen

Posted in Bookmarklet, Development, JavaScript/ECMAScript, Mastodon, Power User, Scripting, SocialMedia, Software Development, Web Browsers | Leave a Comment »

Figuring out the version of a GitLab instance

Posted by jpluimers on 2025/08/05

The easiest way to figure out the version number of a GitLab instance is to browse to the /help bage.

But be aware the version number only shows when you are signed in.

At the time of writing [Wayback/Archive] Help · GitLab (gitlab.com/help) showed this:

GitLab Enterprise Edition 15.7.0-pre ff1158094d6

The link showed [Wayback/Archive] Commits · ff1158094d6 · GitLab.org / GitLab · GitLab.

When nog logged on, the help page showed this:

GitLab Enterprise Edition

Via [Wayback/Archive] Markdown rendering of double indented lists fails (#33471) · Issues · GitLab.org / GitLab FOSS · GitLab.

Confirmed by [Wayback/Archive] How to check the version of GitLab? – Stack Overflow (thanks [Wayback/Archive] Maxim).

–jeroen

Posted in Development, DVCS - Distributed Version Control, git, GitLab, Software Development, Source Code Management | Leave a Comment »

Some notes on testing locally modified chocolatey packages

Posted by jpluimers on 2025/08/01

A few notes after I helped updating [Wayback/Archive] Chocolatey Software | SetACL (Portable) 3.0.6.0 to version 3.1.2.0 and [Wayback/Archive] Updates glab from 1.22.0 to 1.24.1; fixes #2 by jpluimers · Pull Request #3 · corbob/ChocoPackages.

As the burden on maintainers (not just Chocolatey ones) is high, not all packages get updated soon after new underlying software versions arrive.

Which means the maintainers are often very happy when an occasional user helps and preferably sends in a pull request.

That brings me to the an important point IN DOCUMENTATION DO NOT LIMIT EXAMPELS TO ONLY ABBREVIATED PARAMETERS OR VERBS as that scares away occasional and novice users of your software.

Chocolatey documentation is no exception on this, hence this blog post meant for people other than maintaining chocolatey packages on a day to day base.

Read the rest of this entry »

Posted in CertUtil, Chocolatey, CommandLine, Conference Topics, Conferences, Development, Event, Power User, PowerShell, PowerShell, Scripting, Software Development, Windows | Tagged: , , , , | Leave a Comment »

command line – Why does a cURL request return a percent sign (%) with every request in ZSH? – Stack Overflow

Posted by jpluimers on 2025/07/31

I try to stay on the default shells of environments as much as possible, especially as that makes life easier when needing to work on an non-customised system.

Apple switched back from an ancient latest GPLv2 version 3.2 of bash (they regard newer GPLv3 as toxic to their revenue stream¹), introduced MIT-license based zsh and introduced a bash nag screen a few years ago forcing users to switch. Suppressing that message reliably is trickier than you might think².

After so many years of bash, I still stumble over things that zsh does differently: [Wayback/Archive] command line – Why does a cURL request return a percent sign (%) with every request in ZSH? – Stack Overflow (thanks [Wayback/Archive] Travis and [Wayback/Archive] zaTricky) is a “feature” with a simple workaround for cURL:

This is a zsh feature that prints a percent-and-newline after a command completes if that command does not already include a newline at the end of its output. If zsh did not do this, you would either not ever notice the fact that the command didn’t print a newline – or you’d see zsh’s command prompt not start on the margin and think it was a bug in zsh.

$ curl http://api.macvendors.com/0015c7   
Cisco Systems, Inc%     
$ curl -w '\n' http://api.macvendors.com/0015c7
Cisco Systems, Inc

Since the above example now writes a redirect messages (good bye HTTP, welcome HTTPS), and I very much dislike short command-line parameters, here is version with the long form of the [Wayback/Archive] curl -w or --write-out parameter :

Read the rest of this entry »

Posted in *nix, *nix-tools, Apple, bash, bash, Development, Mac OS X / OS X / MacOS, macOS 14 Sonoma, macOS 15 Sequoia, Power User, Scripting, Software Development, zsh | Leave a Comment »

Kevlin Henney on “configuration is code” in his essay “Out of Control. An essay on paradigms, refactoring…”

Posted by jpluimers on 2025/07/31

For my link archive [Wayback/Archive] Out of Control. An essay on paradigms, refactoring… | by Kevlin Henney | Dec, 2020 | Medium.

Neither because Kevlin describes how to refactor a basic algorithm to convert Roman numerals into Hindu-Arabic numerals (in part by using the fact that an if statement can be considered a bounded case of a while loop), nor because he splits the resulting algorithm in coded data and coded statements, or because he mentions the [Wayback/Archive] Gilded Rose Kata but because well, you should just read it in full.

Remember though: Read the rest of this entry »

Posted in Configuration Management, Development, DevOps, Power User, Python, Scripting, Software Development | Leave a Comment »

Not just for Delphi, but any environment: Why You Should Use NowUTC Instead of Now in Delphi: A Quick Guide

Posted by jpluimers on 2025/07/30

The video is from a while back, but very relevant and shows in Delphi what I have been advocating to software developers for a very long time:

  • when timestamping use UTC
  • when storing the timestamp store both the UTC timestamp and optionally the UTC timezone/offset and optionally daylight saving indicator of the region it was recorded from

This holds for any environment, so .NET / C#, Python, Delphi and many others as well:

Read the rest of this entry »

Posted in Conferences, Delphi, Development, EKON, Event | Leave a Comment »