When you're using ${cmd} to get the output of the command instead of $(cmd).
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.
Im eigenen Git Repository hat sich was verändert (meistens ein Update) Schau dir an was genau!
Das kurze Bash-Skript veröffentlicht das Ergebnis auf Github Gist und setzt einen Trött mit einem Link dahin ab
Das Script kann sehr einfach an eigene Repos angepasst werden.
https://gist.github.com/dewomser/743328e2b14a067f15c84b832e1ed579
case
in der #bash ist immer wieder Quell für Mißmut.Hashtable vs Array Difference in PowerShell Tip #49 #softwaredeveloper #softwareengineering #coding #CodingForBeginners #csharp #PowerShellScripting #LearnPowerShell #bash #Scripting #PowerShellTutorial #linux #windows
When you want to rerun a shell command you ran some time ago, how do you usually search for it?
Random useful linux CLI thing I just learnt.
If you don't want to see all that lengthy text after sshing to a machine, just do
touch ~/.hushlogin
(This command creates an empty file ".hushlogin" in your user home directory)
on the machine you are sshing to. Now there won't be any welcome messages to clutter your terminal, just a prompt.
External Command Errors in PowerShell Tip #48 #LearnPowerShell #PowerShellScripting #softwaredeveloper #coding #softwareengineering #CodingForBeginners #csharp #bash #Scripting
Today I (re)learned there be three ways for `date` to number weeks;
- `%U` week number of year, with Sunday as first day of week (00..53)
- `%V` ISO week number, with Monday as first day of week (01..53)
- `%W` week number of year, with Monday as first day of week (00..53)
here is a small #bash script to manually toggle an internal laptop keyboard when a #zsaVoyager is connected and using #sway
https://github.com/draptik/dotfiles/blob/main/zsa-voyager-configs/keyboard-toggle.sh
@gyptazy @BoxyBSD
As you know Tunnel Brokers does not work for me due to my current network setup without a static pingable IP
I am keenly interested
I've installed the statically linked version. Now I rock the latest version of ffmpeg
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
This error in MX Linux KDE edition is now annoying
I cant work without ffmpeg and Im NOT going to install a programming ENV: just to build one programma
>>
$ sudo apt install ffmpeg
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Suggested packages:
ffmpeg-doc
The following NEW packages will be installed:
ffmpeg
0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded.
Need to get 1,816 kB of archives.
After this operation, 2,437 kB of additional disk space will be used.
Get:1 http://deb.debian.org/debian bookworm/main amd64 ffmpeg amd64 7:5.1.6-0+deb12u1 [1,816 kB]
Fetched 1,816 kB in 2s (992 kB/s)
Selecting previously unselected package ffmpeg.
(Reading database ... 342056 files and directories currently installed.)
Preparing to unpack .../ffmpeg_7%3a5.1.6-0+deb12u1_amd64.deb ...
Unpacking ffmpeg (7:5.1.6-0+deb12u1) ...
Setting up ffmpeg (7:5.1.6-0+deb12u1) ...
Processing triggers for man-db (2.11.2-2) ...
metalloid@bugrupola:~
$ ffmpeg
ffmpeg: error while loading shared libraries: libavcodec.so.59: cannot open shared object file: No such file or directory
<<
Who knows a fix apart from compilation?
[Перевод] Лучшие практики для работы с агентным программированием от Anthropic
Claude Code — это инструмент командной строки для агентного программирования. В этой статье от Anthropic рассматриваются советы и приемы, которые доказали свою эффективность при использовании Claude Code в различных кодовых базах, языках и средах.
Directly Handling Errors in PowerShell Tip #47 #softwareengineering #coding #LearnPowerShell #softwaredeveloper #PowerShellScripting #CodingForBeginners #csharp #bash #Scripting #PowerShellTutorial #linux #windows
#Linux #Bash
Einfaches Menue
Kommandos in Bash ausführen durch Eingabe von Zahlen. Demnächst bei https://gist.github.com/dewomser verfügbar