GNU social JP
  • FAQ
  • Login
GNU social JPは日本のGNU socialサーバーです。
Usage/ToS/admin/test/Pleroma FE
  • Public

    • Public
    • Network
    • Groups
    • Featured
    • Popular
    • People

"errors" comic strip by Julia Evans @b0rk panel 1: "by default, bash will continue after errors" beneath is a bash-box saying "oh, was that an error? who cares, let's keep running!!!" and a programmer saying "uh that is NOT what I wanted" "set -e stops the script on errors" with a programmer beneath saying "this makes your scripts WAY more predictable" next to words "set -e /n unzip fle zip" and a note pointing to the .zip line "typo! script stops here!" panel 2: "by default, unset variables don't error" followed by "rmb-r "$HOME/$SOMEPTH" and a bash box "$SOMEPTH doesn't exist? no problem, I'll just use an empty string!" and a programmer "OH NOOOO that means rm -rf $HOME" then "set -u stops the script on unset variables" followed by "set -u /n rm -r "$HOME/$SOMEPTH" and a bash box saying "I've never heard of $SOMEPTH! STOP EVERYTHING!!!" panel 3: "by default, a command failing doesn't fail the whole pipeline" followed by "curl yxqzq.ca | grep 'panda'" and a bash box saying "curl failed but grep succeeded so it's fine! success!" then "set -o pipefail makes the pipe fail if any command fails" followed by "you can combine set -e, set -u, and set -o pipefail into one command I put at the top 9f all my scripts: 'set -euo pipefail'"

Download link

https://cijber.social/system/media_attachments/files/113/032/882/092/889/836/original/1d878ab74bfe3604.jpg

Notices where this attachment appears

  1. Embed this notice
    Gremlins, Inc. (it/its) ♿ 🖕 (gremlins@cijber.social)'s status on Tuesday, 03-Sep-2024 08:24:30 JST Gremlins, Inc. (it/its) ♿ 🖕 Gremlins, Inc. (it/its) ♿ 🖕
    in reply to

    @darkuncle @b0rk #altText4u

    In conversation about 9 months ago from cijber.social permalink
  • Help
  • About
  • FAQ
  • TOS
  • Privacy
  • Source
  • Version
  • Contact

GNU social JP is a social network, courtesy of GNU social JP管理人. It runs on GNU social, version 2.0.2-dev, available under the GNU Affero General Public License.

Creative Commons Attribution 3.0 All GNU social JP content and data are available under the Creative Commons Attribution 3.0 license.