On migrating from Pocket, file conversions and link rot.
Learned a few things about #awk and #gawk and ended up picking #python to get it done.
https://tiagoafpereira.net/blog/posts/2025-06-04-migrating-from-pocket/
On migrating from Pocket, file conversions and link rot.
Learned a few things about #awk and #gawk and ended up picking #python to get it done.
https://tiagoafpereira.net/blog/posts/2025-06-04-migrating-from-pocket/
TIL that modifying NF in #awk has an instant effect, so if you do
$ echo a b c | awk '{while (NF){print $(NF--)}}'
the post-decrementing removes the entry before the variable gets accessed, resulting in it printing blanks, so instead you have to access the variable before doing the post-decrement:
$ echo a b c | awk '{while (NF){print $NF; NF--}}'
to print each item in reverse.
Which seems weird given what I understand about how post-decrement is *supposed* to work.
(HT: @drscriptt whose #awk sent me down this rabbit-hole of learning)
Well I did a thing.
I created a #DNS zone; .oid, on my DNS server #OIDs.
I can now easily look up OID values with dig (et al.):
% dig +short txt 2.3.7.5.5.1.6.3.1.oid.
To look up OIS 1.3.6.1.5.5.7.3.2.
I also wrote a one* line shell script to make doing the lookups easier:
\dig +short txt $(echo ${1} | awk -F. '{for (C=NF; C>1; C--){printf "%s.", $C}; printf "%s.oid.", $1}') | sed 's/"//g' #awk
So I can now run:
% oidlookup 1.3.6.1.5.5.7.3.2
and get the following output:
{iso(1) identified-organization(3) dod(6) internet(1) security(5) mechanisms(5) pkix(7) kp(3) id-kp-clientAuth(2)}
Hey beloved #noGooMe users,
A quick reminder that you *must* have the proxy image option unchecked when using this #SearxNG instance. It can be disabled, if you previously had it enabled, browsing to /preferences, then selecting the "privacy" tab and uncheck the "image proxy" switch.
It is disabled by default so any first connection to this instance has the proper setting set up.
If you do have it enabled, you’ll quickly be blocked at the firewall level by our #awk AI agent
My reason for disabling this feature is that it generates loads of requests from the instance IP to the external engines. And this makes those block us really fast.
This means that the engines will have *your IP* logged when you search for images, only. Classical text search are still masqueraded with our instance IP.
I still can't believe that most programming systems we use today are preoccupied with numbers. AFAIK, half of (R5RS?) #Scheme standard is numbers and operations on them. Same for #C, #CommonLisp, #Java—ten different types of numbers and huge libraries for them.
Humans think in images and words. Structured text-oriented languages feel like a much better fit for everyone not corrupted by C. Yet we have little to no popular attempts in that space. Structured Regular Expressions didn't catch up; #ed1 and #awk are considered mere #regex automation tools. Modal and the term rewriting systems have their Merveilles Town, but not much beyond. sh/#bash and the like are quite successful, but aren't considered real programming languages either.
Why.
I am in urgent job search mode, so I'm gonna throw this out here and see if anything comes of it.
I am a #Canadian, fluent in both #English and #French. I have experience with several programming languages. My strongest proficiency is with #Haskell and #C. I also have a reasonable grasp of #HTML, #JavaScript, #SQL, #Python, #Lua, #Linux system administration, #bash scripting, #Perl, #AWK, some #Lisp (common, scheme, and emacs), and probably several others I've forgotten to mention.
I am not necessarily looking for something in tech. I just need something stable. I have done everything from software development, to customer support, to factory work, though my current circumstances make in-person work more difficult than remote work. I have been regarded as a hard worker in every job I have ever held.
Do you find awk one-liners cryptic? Stuff like !a[$0]++, 1, $1=$1, NR==FNR and -v RS=? I wrote a blog post to explain such idioms.
Remind me, the awk package manager is called what?
#awk
Quick list of all git repositories URLs, you have locally:
<code>
awk '/url/{print $3}' */.git/config
</code>
<code>
find . -name ".git" -type d | sed 's/\/.git//' | xargs -P42 -I% git -C % config --get remote.origin.url
</code>
I’m looking for a template based way of reformatting data from a text form to some variables.
Does any #sysadmin have an idea how to approach this in 2024, with as little additional tools as possible?
I didn’t touch that territory for a long time so I’m not coming up with a good idea except intuitively using #awk but I feel that there should be better approaches by now.
#admin
Por si quieres ampliar tus conocimientos en #Bash y #Scripting, algo de #Python, #grep y herramientas tan “intuitivas" como #sed y #awk, tienes una colección interesante por pocos l€uros aquí:
https://www.humblebundle.com/books/shells-and-scripting-for-seasoned-admins-oreilly-books
#Microsoft #Excel is what happens when you don't know how to use #awk. Change my mind.
@neil The new edition of The AWK Programming Language
https://awk.dev
is a great gift for any occasion!
#awk
This month, you should use a special-purpose programming language that makes it easy to handle simple data-reformatting jobs.
That's right.
It's.... awktober!