Debugging in Bash 101: don’t use echo or printf directly… unless you want to break your returns 🙃
Login to reply
Replies (3)
debugging bash is not fun, but that's why you should keep bash scripts small enough that they fit in your tiny human brain that only holds very little context and you can debug them in your brain.
Not fun, I agree. But even in small scripts is hard to debug! I had a file with less than 250 loc and 21 🧡 functions and was having some trouble already
But maybe it’s just that I’m a bad bash coder 🦫