Wow, I've just learned from a podcast about a new #shell called #Elvish: https://elv.sh/. Seems very promising!
Wow, I've just learned from a podcast about a new #shell called #Elvish: https://elv.sh/. Seems very promising!
Update: derp, just use readlink, derp. XD
In the #iDontKnowWhyIdidntWriteThisYearsAgo category:
~ $ type deref
deref is a function
deref ()
{
stat -c "%N" "$*" | cut -f4 -d\'
}
~ $ which gcc
/usr/bin/gcc
~ $ deref $(which gcc)
gcc-14
~ $ deref $(which $(deref $(which gcc)))
x86_64-linux-gnu-gcc-14
Super excited about atuin desktop. Atuin is at least in my top 5 list of most useful tools in my daily work. Join me on the waiting list using the link https://wt.ls/atuin/qoQy7Rqk
Suite des vidéos de dev de modules kernel, on voit ici comment utiliser exécuter du shell dans un module Linux
Les codes et slides disponibles sur le serveur discord de l'association Kingdown : https://discord.gg/kingdown
A bash surprise: https://www.gnu.org/software/bash/manual/html_node/Shell-Functions.html says:
Functions are declared using this syntax:
fname () compound-command [ redirections ]
Usually curly braces are used for the compound command. Yet parentheses work too. And those go into a sub-shell. Run this and carefully inspect the output.
function fun() ( # parenthesis!
echo hallo
echo fun has $$ $BASHPID
)
fun
echo main has $$ $BASHPID
By using () in a function definition, we force it into a subshell.
What if bash was written in Rust? I think it's time.
**brush** — Bash/POSIX-compatible shell implemented in Rust
Bo(u)rn(e) RUsty SHell
Built & tested on Linux/macOS/Windows
GitHub: https://github.com/reubeno/brush
Today I learned about Control-S and Control-Q… better late than never, I guess
And just got me thinking about that helpful “scroll?” at the bottom of my ZX Spectrum after printing a screenful of content in BASIC…
#TIL #TodayILearned #Terminal #shell #suspend #ControlS #CtrlS https://social.jvns.ca/@b0rk/114354742870242559
I've probably tooted about this before, but I don't know why this isn't standard.
It's just so obvious, at least to me. ;)
~ $ type mcd
mcd is a function
mcd ()
{
[[ -n $1 ]] && mkdir "$1" && cd "$1"
}
Bulgaria signs Black Sea oil, gas exploration deal with energy giant Shell https://www.byteseu.com/925556/ #AnadoluAjansı #BlackSea #Bulgaria #BulgarianEEZInBlackSea #OilAndGasExploration #Shell
CSV Hell: When Your Data Gets All Philosophical About Line Breaks
Just a quick and dirty script for when your csv files looks like something only a blind poet could put together.
https://schulz.dk/2025/04/15/csv-hell-when-your-data-gets-all-philosophical-about-line-breaks/
I think I won't bother anymore with writing (bash) shell scripts that are longer than a few lines. I find the syntax too unintuitive and there are better programming languages like PHP that produce more readable code.
In the last two hours, I translated a bash shell script with ~250 lines to a PHP CLI script. The latter is nearly 400 lines long but definetly more readable and it also has more user-friendly output.
1/2
[05:45] De vervuiler verzaakt. Door deze vier fabrieken raken de klimaatdoelen uit zicht
Om het klimaatdoel van 2030 te halen, beloofden Nederlandse olieraffinaderijen – grote vervuilers – hun CO2-uitstoot tot wel 60 procent te reduceren. Maar van die beloftes komt bar weinig terecht.
Olietanks op het terrein van de raffinaderij van Shell bij Pernis. Foto: Flip Franssen / ANP.
Nog maar vijf jaar te gaan tot Nederland het klimaatdoel van 2030 gehaald moet hebben: een CO2-reductie van 55 procent ten opzichte van 1990. En laten we positief beginnen: we zijn goed op weg. De verduurzaming is in volle gang en de CO2-uitstoot daalt al jaren.
De Correspondent en maak meer verhalen mogelijk voorbij de waan van de dag.
Dankzij onze leden kunnen wij verhalen blijven maken voor zoveel mogelijk mensen.
Word ook lid!
Zakelijk lid worden is ook mogelijk,
dit kan al vanaf 5 medewerkers.
Steun ons en vraag direct een zakelijk lidmaatschap aan.
Wil je eerst kennismaken met onze verhalen?
Schrijf je dan in voor de proefmail en ontvang een selectie van onze beste verhalen in je inbox.
https://open.decorrespondent.nl/16033/app-open?pk_campaign=rss-feed&pk_medium=rss&pk_source=publication&pk_kwd=all&pk_cid=eccbc87e4b5ce2fe28308fd9f2a7baf3
#2030 #Nederlandse #60procent #Shell #FlipFranssen #ANP #vijfjaar #Nederland #55procent #1990 #5
Should've made this a long time ago:
function ciglob {
#case-insensitive glob generator
echo "$*" |while read -N1 c; do
case "$c" in
[a-zA-Z]) echo -n "[${c^^}${c,,}]";;
*) echo -n "$c"
esac
done
}
~ $ ciglob "Hello, world!"
[Hh][Ee][Ll][Ll][Oo], [Ww][Oo][Rr][Ll][Dd]!
~ $ ls -ld $(ciglob documents)
drwxr-xr-x 52 ~~~ ~~~ 20,480 Apr 10 11:45 Documents
(Not the most useful example, but I did have a use case in mind when I wrote it ;)
P.S. (This is a valid way to close a parenthesis. Fight me ;)
#shell : the case which holds the powder, or charge of powder and shot, used with breechloading small arms
- French: coquille
- German: die Muschel
- Italian: guscio
- Portuguese: concha
- Spanish: concha
------------
Thank you so much for being a member of our community!
[16:07] Dutch stocks slump again as trade war with the US heats up
Chip machinery maker Besi, medical technology company Philips, oil giant Shell and semiconductor specialist ASM International were among the biggest...
https://www.dutchnews.nl/2025/04/dutch-stocks-slump-again-as-trade-war-with-the-us-heats-up/
#Besi #Philips #Shell
Only #bp, #Eni, Expand Energy, #Repsol, #Shell, and #TotalEnergies have disclosed their executive remuneration
plans prospectively https://carbontracker.org/reports/crude-intentions-3/