BASH as a Modern Programming Language

Jason Brittain (eBay Inc.)
Programming
Location: Portland 255
Average rating: **...
(2.33, 18 ratings)
Slides:   1-PPT 

Consider using BASH, a simple and powerful programming language. In this presentation, you’ll be surprised at what modern BASH is capable of. I’ll discuss how to choose when BASH is the right tool for the job over other programming languages such as Perl, Python, Ruby, and Java. Do you work with programming languages that have deep dependencies that take too long for users to download? Does the language’s runtime usually have to be reinstalled by users because the OS comes with an unacceptably outdated version? Is the language becoming too complex? In this presentation, we’ll take a fresh look at BASH.

I’ll also show you BASH code examples for common programming tasks:

  • Conditionals: simple, checking for a defined value, string regex
  • Looping: for, while
  • Strings: assignment tricks, length, trim, substring, substring replacement
  • Arrays: scope, store, sort, find, iterate, remove elements, associative
  • Files: normalize paths, read files, write files
  • OO: functions, classes, packages
  • Debugging
  • SOA: writing HTTP REST API clients, parsing JSON data
  • Introspection: detecting the presence of a function or a variable
  • Automating otherwise manual typing tasks
  • GUI: code UI apps in Bash using zenity
Photo of Jason Brittain

Jason Brittain

eBay Inc.

Jason Brittain is a Software Engineer and Software Architect, author, and speaker, best known as author of the book Tomcat: The Definitive Guide (O‚ÄôReilly), now in its second edition. Jason was previously a Software Architect at MuleSoft Inc. on the Tcat Server product. Before working at MuleSoft, Jason was Senior Architect at Spigit, Inc. where he led a team of software engineers writing an idea management and prediction markets social networking web application for the enterprise. Before joining Spigit, Jason was a Senior Principal Software Engineer for Orbital Sciences Corporation, working at NASA’s Ames Research Center on the Kepler Space Telescope mission, where his software still runs and is discovering exoplanets (105 confirmed planet discoveries, and tracking more than 2,700 new planet candidates). Jason’s specialties include the Apache Tomcat servlet container, server-side Java programming, Java servlet web application development and deployment, Linux operating systems, modern shell script programming, building social networking web applications, scalability and fault tolerance, Java build systems, and virtual machines.

Sponsors

Sponsorship Opportunities

For information on exhibition and sponsorship opportunities at the conference, contact Sharon Cordesse at (707) 827-7065 or scordesse@oreilly.com.

Contact Us

View a complete list of OSCON contacts