Site Map - skip to main content

Hacker Public Radio

Your ideas, projects, opinions - podcasted.

New episodes Monday through Friday.


In-Depth Series: Bash Scripting

  • Number of episodes: 56
  • Open/closed: open
  • Date of earliest show: 2010-03-24
  • Date of latest show: 2022-11-08
  • Series RSS feeds: ogg, spx, mp3
This is an open series in which Hacker Public Radio Listeners can share their Bash scripting knowledge and experience with the community. General programming topics and Bash commands are explored along with some tutorials for the complete novice.

hpr3722 :: Bash snippet - plurals in messages hosted by Dave Morriss

2022-11-08. 00:08:33. Explicit.
.
How to use English singular and plural words in messages

hpr3713 :: Bash snippet - short-circuit evaluation in Bash Boolean expressions hosted by Dave Morriss

2022-10-26. 00:16:40. Explicit.
.
Found I could do this in Bash, so wanted to share!

hpr3625 :: Shell Tips and Snippets - Collaborative Effort hosted by Carl

2022-06-24. 00:20:25. Clean.
.
Carl and special guests provide some shell tips and examples.

hpr3551 :: Bash snippet - some possibly helpful hints hosted by Dave Morriss

2022-03-14. 00:24:35. Explicit.
.
Using 'eval', 'mapfile' and environment variables

hpr3413 :: Bash snippet - using coproc with SQLite hosted by Dave Morriss

2021-09-01. 00:45:38. Explicit.
.
Sending multiple queries to a running instance of sqlite3

hpr3071 :: Bash snippet - quotes inside quoted strings hosted by Dave Morriss

2020-05-11. 00:13:19. Explicit.
.
How to add quotes to quoted strings in Bash

hpr3013 :: Bash Tips - 21 hosted by Dave Morriss

2020-02-19. 00:41:37. Explicit.
.
Environment variables

hpr2877 :: Using Zenity with Pdmenu hosted by Dave Morriss

2019-08-13. 00:22:38. Explicit.
.
Zenity is a rather cool program that will display GTK+ dialogs from a script

hpr2807 :: Are bash local variables local? hosted by clacke

2019-05-07. 00:11:01. Clean.
.
A lesson on dynamic scope vs lexical scope

hpr2793 :: bash coproc: the future (2009) is here hosted by clacke

2019-04-17. 00:21:16. Clean.
.
clacke discovers bash's coproc keyword and explains some toy examples

hpr2756 :: Bash Tips - 20 hosted by Dave Morriss

2019-02-25. 00:32:35. Explicit.
.
Deleting arrays; positional and special parameters in Bash

hpr2739 :: Bash Tips - 19 hosted by Dave Morriss

2019-01-31. 00:25:53. Explicit.
.
Arrays in Bash (part 4)

hpr2736 :: Response to show 2720 hosted by Dave Morriss

2019-01-28. 00:18:24. Explicit.
.
Some suggestions on how to improve a Bash script

hpr2729 :: Bash Tips - 18 hosted by Dave Morriss

2019-01-17. 00:31:38. Explicit.
.
Arrays in Bash (part 3)

hpr2719 :: Bash Tips - 17 hosted by Dave Morriss

2019-01-03. 00:34:16. Explicit.
.
Arrays in Bash (part 2)

hpr2709 :: Bash Tips - 16 hosted by Dave Morriss

2018-12-20. 00:24:00. Explicit.
.
Arrays in Bash (part 1)

hpr2699 :: Bash Tips - 15 hosted by Dave Morriss

2018-12-06. 00:29:54. Explicit.
.
Some of the pitfalls when using loops in Bash

hpr2689 :: Bash Tips - 14 hosted by Dave Morriss

2018-11-22. 00:28:08. Explicit.
.
More about loops - the 'for' loop, 'break' and 'continue'

hpr2679 :: Extra ancillary Bash tips - 13 hosted by Dave Morriss

2018-11-08. 00:36:42. Explicit.
.
Making decisions in Bash (part 5)

hpr2669 :: Additional ancillary Bash tips - 12 hosted by Dave Morriss

2018-10-25. 00:28:22. Explicit.
.
Making decisions in Bash (part 4)

hpr2659 :: Further ancillary Bash tips - 11 hosted by Dave Morriss

2018-10-11. 00:28:22. Explicit.
.
Making decisions in Bash (part 3)

hpr2649 :: More ancillary Bash tips - 10 hosted by Dave Morriss

2018-09-27. 00:22:52. Explicit.
.
Making decisions in Bash (part 2)

hpr2639 :: Some ancillary Bash tips - 9 hosted by Dave Morriss

2018-09-13. 00:21:45. Explicit.
.
Making decisions in Bash (part 1)

hpr2496 :: Making a Raspberry Pi inventory hosted by Dave Morriss

2018-02-26. 00:11:10. Explicit.
.
How to collect identifying information about RPi devices

hpr2483 :: Useful Bash functions - part 4 hosted by Dave Morriss

2018-02-07. 00:39:46. Explicit.
.
A Bash function for parsing lists of numbers and ranges

hpr2469 :: A flight itinerary in Bash hosted by Dave Morriss

2018-01-18. 00:17:45. Explicit.
.
Working out dates and times in a Bash script

hpr2448 :: Useful Bash functions - part 3 hosted by Dave Morriss

2017-12-20. 00:33:53. Explicit.
.
A few more possibly useful Bash functions are discussed

hpr2349 :: Customizing my bash prompt hosted by Windigo

2017-08-03. 00:24:12. Explicit.
.
A detailed look into how, and why, to customize a bash prompt.

hpr2317 :: Bash snippet - extglob and scp hosted by Dave Morriss

2017-06-20. 00:28:27. Explicit.
.
How does scp manage extended glob patterns?

hpr2302 :: Bash snippet - nullglob hosted by Dave Morriss

2017-05-30. 00:07:08. Explicit.
.
After learning about the nullglob option I have started to use it

hpr2293 :: More supplementary Bash tips hosted by Dave Morriss

2017-05-17. 00:38:25. Explicit.
.
Finishing off the subject of expansion in Bash (part 2)

hpr2278 :: Some supplementary Bash tips hosted by Dave Morriss

2017-04-26. 00:39:35. Explicit.
.
Finishing off the subject of expansion in Bash (part 1)

hpr2135 :: Audio speedup script hosted by Dave Morriss

2016-10-07. 00:27:59. Explicit.
.
I want to speed up some of my podcasts and truncate silence in them too so I wrote a script to do it

hpr2096 :: Useful Bash functions - part 2 hosted by Dave Morriss

2016-08-15. 00:23:21. Explicit.
.
The further development of a Bash function that may be of use in your scripts

hpr2045 :: Some other Bash tips hosted by Dave Morriss

2016-06-03. 00:55:53. Explicit.
.
Yet more information about types of expansion in Bash

hpr2003 :: Using the Incron file watching daemon hosted by b-yeezi

2016-04-06. 00:11:38. Explicit.
.
I briefly introduce the incron file watching daemon, and give an example of how I use it.

hpr1990 :: Pomodoro Timer - The Evolution of a Script part deux hosted by Nacho Jordi

2016-03-18. 00:28:54. Clean.
.
Further evolutions of a pomodoro script that got a life of its own

hpr1987 :: Pomodoro Timer - The Evolution of a Script (pt 1) hosted by Nacho Jordi

2016-03-15. 00:22:07. Clean.
.
The different stages of a bash script that was created accidentally

hpr1952 :: Time now Ladies and Gents hosted by Ken Fallon

2016-01-26. 00:31:00. Clean.
.
How to get the total duration of a lot of media files.

hpr1951 :: Some additional Bash tips hosted by Dave Morriss

2016-01-25. 00:40:24. Explicit.
.
More about expansion in Bash: this time arithmetic expansion

hpr1903 :: Some further Bash tips hosted by Dave Morriss

2015-11-18. 00:29:18. Explicit.
.
Some more information about types of expansion in Bash

hpr1884 :: Some more Bash tips hosted by Dave Morriss

2015-10-22. 00:15:49. Explicit.
.
Some information about brace expansion in Bash that you might not know

hpr1843 :: Some Bash tips hosted by Dave Morriss

2015-08-26. 00:21:17. Explicit.
.
A few useful Bash features that may not be well known

hpr1838 :: Waking up with Windigo hosted by Windigo

2015-08-19. 00:15:25. Clean.
.
An overview of a terrible, hacky method of waking up.

hpr1791 :: Organizing Photos with Bash hosted by Tony Pelaez

2015-06-15. 00:31:15. Explicit.
.
Use bash to simplify the process of organizing and backing up photographs.

hpr1757 :: Useful Bash functions hosted by Dave Morriss

2015-04-28. 00:27:42. Explicit.
.
Some Bash functions that may be of use in your scripts

hpr1710 :: Windows Remote Desktop on GNU/Linux hosted by Ken Fallon

2015-02-20. 00:11:19. Clean.
.
A wrapper script for xfreerdp to make connecting to windows servers painless

hpr1648 :: Bash parameter manipulation hosted by Dave Morriss

2014-11-26. 00:40:33. Explicit.
.
A summary and aide memoire of Bash parameter expansion methods

hpr1430 :: thebestofyoutube.com download script hosted by Ken Fallon

2014-01-24. 00:38:32. Explicit.
.
A hacked script to download youtube videos

hpr1247 :: Recording Terrestrial Radio with bash scripts and cron jobs hosted by Jon Kulp

2013-05-14. 00:14:36. Explicit.
.
Using a Bash script to capture terrestrial radio

hpr1204 :: My Magnatune Downloader hosted by Dave Morriss

2013-03-14. 00:21:59. Explicit.
.
How I download albums from Magnatune with Bash and Perl scripts

hpr1197 :: What I do with bash scripts hosted by Jon Kulp

2013-03-05. 00:27:18. Explicit.
.
Some personal anecdotes on writing Bash scripts

hpr598 :: Bash Scripting: Episode 2 Command Line Basics hosted by Ken Fallon

2010-11-17. 00:38:33. Explicit.
.
Introduction to the man, info, and appropos commands, among other basics

hpr562 :: Introduction to bash scripting hosted by Ken Fallon

2010-08-11. 00:20:32. Explicit.
.
Introduction to bash scripting, with quick explanations of many adjacent concepts

hpr543 :: Xoke's Podcasting Script hosted by Xoke

2010-05-24. 00:08:55. Explicit.
.
An introduction to a script for recording podcasts

hpr531 :: bash loops hosted by Ken Fallon

2010-03-24. 00:08:32. Explicit.
.
While aboard an Airbus 320, Ken Fallon describes loops that are available in BASH