
CommunityNews
Bash Strict Mode
Use Bash Strict Mode (Unless You Love Debugging)
Let’s start with the punchline. Your bash scripts will be more robust, reliable and maintainable if you start them like this:
1#!/bin/bash set -euo pipefail IFS=$'\n\t'
I call this the unofficial bash strict mode. This causes bash to behave in a way that makes many classes of subtle bugs impossible. You’ll spend much less time debugging, and also avoid having unexpected complications in production.
There is a short-term downside: these settings make certain common bash idioms harder to work with. Most have simple workarounds, detailed below: jump to Issues & Solutions. But first, let’s look at what these obscure lines actually do.
http://redsymbol.net/articles/unofficial-bash-strict-mode/
This thread was posted by one of our members via one of our news source trackers.
Popular General Dev topics

https://permission.site/
This thread was posted by one of our members via one of our news source trackers.
New

TOKYO (Kyodo) – Japan’s government plans to encourage firms to let their employees choose to work four days a week instead of five, aimin...
New

Last night I re-read this Steve Yegge article about learning to type as a programmer. I can touch type, but I don’t usually manage to bre...
New

Developing Godot Projects with Neovim.
When I started using Godot Engine, what surprised me the most is the built-in Language Server Pro...
New

…or, “why make programming even harder?”
Learning functional programming is an opportunity to discover a new way to represent programs, t...
New

Rewrite it in Rust by ridiculousfish · Pull Request #9512 · fish-shell/fish-shell.
(Sorry for the meme; also this is obligatory.)
I thi...
New

The Definitive PHP 7.2, 7.3, 7.4, 8.0, and 8.1 Benchmarks (2023).
We tested the performance of 14 PHP platforms (WordPress, Drupal, Lara...
New

A Brief Review of the Minisforum V3 AMD Tablet.
Update: I have created an awesome-minisforum-v3 GitHub repository to list information fo...
New

SLUM: The Shadow Library Uptime Monitor.
This dashboard tracks the availability of popular shadow libraries in real time from a US-based...
New

There are countless articles why developers should not focus on Frameworks too much and instead learn to understand the underlying langua...
New
Other popular topics

Hello Devtalk World!
Please let us know a little about who you are and where you’re from :nerd_face:
New

If it’s a mechanical keyboard, which switches do you have?
Would you recommend it? Why?
What will your next keyboard be?
Pics always w...
New

I know that -t flag is used along with -i flag for getting an interactive shell. But I cannot digest what the man page for docker run com...
New
New

Thanks to @foxtrottwist’s and @Tomas’s posts in this thread: Poll: Which code editor do you use? I bought Onivim! :nerd_face:
https://on...
New

I ended up cancelling my Moonlander order as I think it’s just going to be a bit too bulky for me.
I think the Planck and the Preonic (o...
New

Oh just spent so much time on this to discover now that RancherOS is in end of life but Rancher is refusing to mark the Github repo as su...
New

Build efficient applications that exploit the unique benefits of a pure functional language, learning from an engineer who uses Haskell t...
New

Author Spotlight
Jamis Buck
@jamis
This month, we have the pleasure of spotlighting author Jamis Buck, who has written Mazes for Prog...
New

Curious what kind of results others are getting, I think actually prefer the 7B model to the 32B model, not only is it faster but the qua...
New
Categories:
Sub Categories:
- All
- In The News
- Dev Chat (202)
- Questions (33)
- Resources (119)
- Blogs/Talks (26)
- Jobs (3)
- Events (15)
- Code Editors (58)
- Hardware (57)
- Reviews (5)
- Sales (16)
- Design & UX (5)
- Marketing & SEO (2)
- Industry & Culture (14)
- Ethics & Privacy (19)
- Business (4)
- Learning Methods (4)
- Content Creators (7)
- DevOps & Hosting (9)
Popular Portals
- /elixir
- /rust
- /wasm
- /ruby
- /erlang
- /phoenix
- /keyboards
- /rails
- /js
- /python
- /security
- /go
- /swift
- /vim
- /clojure
- /emacs
- /haskell
- /java
- /onivim
- /typescript
- /svelte
- /kotlin
- /crystal
- /c-plus-plus
- /tailwind
- /gleam
- /react
- /ocaml
- /elm
- /flutter
- /vscode
- /ash
- /html
- /opensuse
- /centos
- /php
- /deepseek
- /zig
- /scala
- /textmate
- /sublime-text
- /lisp
- /nixos
- /debian
- /react-native
- /agda
- /kubuntu
- /arch-linux
- /django
- /revery
- /ubuntu
- /spring
- /manjaro
- /nodejs
- /diversity
- /lua
- /julia
- /c
- /slackware
- /neovim