I’ve been using idioms like
find . -name \*.foo | while read f; do mv $f ${f%%.foo}.bar; done
for decades. Now I’m preparing an exercise where students are to rename all files that do not end in .txt; so something like this should do the trick:
find . -not -name \*.txt | while read f; do mv $f ${f%%.*}.txt; done
Except... ${f%%.*} is empty! ${f%.*} works, but why!?
Finding the obvious took me an hour… And why do I only stumble upon such things when preparing exe…
I’ve been using idioms like
find . -name \*.foo | while read f; do mv $f ${f%%.foo}.bar; done
for decades. Now I’m preparing an exercise where students are to rename all files that do not end in .txt; so something like this should do the trick:
find . -not -name \*.txt | while read f; do mv $f ${f%%.*}.txt; done
Except... ${f%%.*} is empty! ${f%.*} works, but why!?
Finding the obvious took me an hour… And why do I only stumble upon such things when preparing exe…
I’ve been using idioms like
find . -name \*.foo | while read f; do mv $f ${f%%.foo}.bar; done
for decades. Now I’m preparing an exercise where students are to rename all files that do not end in .txt; so something like this should do the trick:
find . -not -name \*.txt | while read f; do mv $f ${f%%.*}.txt; done
Except... ${f%%.*} is empty! ${f%.*} works, but why!?
Finding the obvious took me an hour… And why do I only stumble upon such things when preparing exe…
The Polar Climate Space:
Our next hackathon/bootcamp on polar climate processes is now open for applications.
Funded by European Space Agency - ESA's climate programe under the #ESApisco project, and in association with the Horizon Europe project #SnowPI, we are looking for talented ECRs and senior researchers who are interested in working with them on small group problems tackling key processes in the #Arctic and #Antarctic.
We will bring together Earth Observation data with high resolution regional climate models to get deeper insights into polar climate processes.
Deadline to apply is 1st May, more details here:
https://climate.esa.int/en/observations-and-modelling/PISCO/news-events/news/the-polar-climate-space-hackathon-save-the-date-and-pre-registration/
So I joined a gym, the local YMCA, for the 1st time in my life. Yesterday I participated in my 1st drop-in exercise class and discovered I'm not as fit as I thought I was. I'm now committed to attending at least one exercise session each week. I might need my wife to drag me there occasionally.
#StayActiveStayHealthy
An Evercore ISI economist criticizes Citrini's AI report, calling its assumptions "extreme and improbable", but says it's a thought-provoking exercise (Robin Wigglesworth/Financial Times)
https://www.ft.com/content/597ea81c-184f-45ab-a8c1-4306a3579ceb…
Heute liegt auf den #Solarmodulen eine 5 mm dicke Eisschicht. Der #Eisregen hat ganze Arbeit geleistet. Aber das Eis ist transparent, also lasse ich das jetzt einfach mal so und kratze nicht herum.
#Balkonsolaranlage