944
you are viewing a single comment's thread
view the rest of the comments
[-] lil@lemy.lol 2 points 5 months ago

I guess shell languages can't do this:

export EDITOR=case "$OSTYPE" in
  linux*)
    nano
  ;;
  freebsd*)
    ee
  ;;
[-] ryannathans@aussie.zone 2 points 5 months ago* (last edited 5 months ago)

That would be too smart. Smells like kotlin's when

[-] SpaceNoodle@lemmy.world 2 points 5 months ago

Put backticks around the entire case statement, and you can.

this post was submitted on 08 Apr 2024
944 points (98.1% liked)

Programmer Humor

19292 readers
1300 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 1 year ago
MODERATORS