Sane Strategies for Smarter (& Safer!) Shell Scripting—III: The Mindset

Description

One morning, when you wake from your troubled dreams, you find yourself transformed into a horrible vermin. You lie on your armour-like back, and if you lift your head a little you can see your brown belly, slightly domed and divided by arches into stiff sections.
“What has happened to me?” you think. It wasn't a dream.
Tonight, you go to bed an innocent data scientist, a data analyst, a physical scientist, a machine learning expert… but the world is not designed to save you from its horrors, and by the time you awake, you must become an expert in shell!

This Session

In this session, we'll talk about the mindset behind shell scripting, including when we abandon the shell for other tools (and when does the shell do a superior job than these alternatives)?

We'll discuss:

  • how do I encode workflows?
  • what is a job? what is job control?
  • when do I use shell? when do I not use shell?

Discussion Questions (tentative)

  1. “How do I encode workflows?”
  2. “What is a job? What is job control?”
  3. “When do I use shell? When do I avoid shell?”
  4. How do I use pipelines to pass data and coördinate processes?”
  5. “What else do I have to know to be effective?”
  6. “How do I keep my life simple?”

Keywords

make, ssh, tmux, jobs, disown, pstree, awk, sed, patch, jq, fork, exec, dup2, pipe, systemctl, SystemD

Series Overview

Though many of us are not sysadmins, notice how much of our time is consumed with using or designing tools that are written for the command-line! How often do we need to put together what, at first, appears to be an ad hoc script but quickly grows to become a critical part of our infrastructure?

In this three session seminar series, we will introduce a better, saner way of thinking of shell programming. And, rather than recite commands at you, we will dismantle the core concepts and mental models that underlie this (dangerously!) powerful tool, to allow you to confidently & safely navigate its complexity!

This seminar series is split into three sessions (plus a bonus session!)

In session I (Thu Feb 10,) we'll talk about building complex functionality by composing common commands while avoiding common pitfalls when using these tools. After this session, attendees will have a fundamental understanding of shell scripting, the design of command-line tools, and how to approach and effectively solve many common, complex scripting problems. If you're using these commands all the time, isn't it worth learning how to use them well?

In the bonus session (Fri Feb 11,) we'll compare some of the oldest shell tools with their modern counterparts. Is it worth ditching grep for ripgrep or ag, the Silver Searcher? What benefits does this new generation of tooling provide (other than bragging rights that your `ls`-replacement is written in Rust)? If these tools are a big part of your daily work, isn't it worth staying up-to-date with the latest & greatest?

In session II (Thu Feb 17,) we'll discuss the underlying design of your standard Linux system, focusing on the designing tooling to make use of the various isolation and “container” mechanisms (from docker/podman-style containers to virtualenv/conda env-style isolation.) After this session, attendees will have an understanding of how to write safer, better isolated scripts & frameworks. If you're building tools to be deployed throughout your production environment, isn't it worth learning how to make them more robust?

In session III (Fri Feb 24,) we'll discuss the mindset of building and using command-line tooling. We'll discuss how to design scripts that work seamlessly with existing tools and frameworks, and how to avoid fighting with system-level and design-level decisions core to the command-line. Composability and flexibility are the strongest selling points of the shell—a simple set of commands can be combined in infinite ways to accomplish infinite tasks. After this session, attendees will have an understanding of when to use shell, when not to use shell, and how to capitalise on its unique design. If you've committed to bringing shell into your life, isn't it worth appreciating its strengths and learning how to come to terms with its quirks and limitations?

FAQ

I can’t attend the seminar live. Should I still register?

Yes! The week after a seminar, everyone who registered will receive:

  • A professionally produced video of the presentation
  • A PDF copy of the code and notes from the session

I missed the first seminar in a series. Can I still benefit from attending the subsequent sessions?

Yes! If you sign up for later sessions in a series, send us an email at info@dutc.io and we can send you the video and materials for the sessions you missed.

Will the seminar be recorded? Are recordings available?

Yes, the seminar will be recorded and professionally produced. In the week following the seminar, we will send you a link to the video at the email address associated with your EventBrite account.

Can I get a detailed receipt to submit for a corporate training reimbursement?

Yes! Email us at info@dutc.io and we will provide you with an invoice.

What is your refund policy?

Receive a full refund if you cancel your ticket 24 hours in advance.

However! If you have to cancel because you can’t attend live, know that we send the videos out to everyone who has registered.