Advanced Bash-Scripting GuideMendel Cooper

Advanced Bash-Scripting Guide

by Mendel Cooper · first published 2014

33mentions
16recommended by
30HN commenters
2011–2026first – last mentioned

53% recommend27% neutral20% critical

Why HN recommends it

Free, book-length bash tutorial that assumes no prior scripting knowledge and works up to advanced topics; handy as a reference for looking up syntax and also useful for daily interactive shell work.

Common criticism: Some experts say it teaches buggy habits and bad practices

Summarised by Claude from recommending comments

Affiliate links. As an Amazon Associate I earn from qualifying purchases.

Mentions per year

50 2007: 0 mentions2008: 0 mentions2009: 0 mentions2010: 0 mentions2011: 2 mentions2012: 1 mention2013: 4 mentions2014: 3 mentions2015: 2 mentions2016: 0 mentions2017: 1 mention2018: 3 mentions2019: 5 mentions2020: 3 mentions2021: 4 mentions2022: 0 mentions2023: 3 mentions2024: 0 mentions2025: 1 mention2026: 1 mention200720172026

What Hacker News says

  • samaraga · Feb 4, 2012 · Recommends

    …for small tasks, if I come across any problem. Just in case, does anyone know a place(website,book etc.) where such small task scripts are collated so that anyone can use them like small assignments? Advanced Bash Scripting Guide by Mendel Cooper(http://tldp.org/LDP/abs/html/) has some good scripts which I have come across for some practice but it isn't ordered. Any others ?

    on “How I Learned to Program” ↗
  • foob · Sep 7, 2011 · Recommends

    I would like to add the Advanced Bash-Scripting Guide (http://tldp.org/LDP/abs/html/) as an incredible resource. It's obviously geared towards scripting but most of what it teaches is extremely useful for working in an interactive shell as well. I had been…

    on “Miguel de Icaza: Learning Unix” ↗
  • beobab · May 23, 2019 · Recommends

    If you read, execute and understand all the code in "The Advanced Bash Scripting Guide", you will suddenly find yourself in the top 10% of people who use bash. https://www.tldp.org/LDP/abs/html/ (as a pdf: http://tldp.org/LDP/abs/abs-guide.pdf )

    on “The Art of Command Line (2015)” ↗
  • coolj · Aug 14, 2013 · Recommends

    http://www.tldp.org/LDP/abs/html/ TLDP's Advanced Bash-Scripting Guide is a great resource for learning bash. For example, this section talks about the meaning of "$*": http://www.tldp.org/LDP/abs/html/internalvariables.html#ARGL...

    on “What I learned from others' shell scripts” ↗
  • xorcist · Jan 8, 2019 · Recommends

    There used to be this great resource called Linux Documentation Project. It's not as active as it used to be but it produced some really book-quality documents, including the Advanced Bash Scripting Guide at https://www.tldp.org/LDP/abs/html/ . Read it! It's great. But know that a lot of bash scripting isn't really in bash, it's really required to be proficient with grep, sed, cut, dc and a few other…

    on “Bash 5.0 released” ↗
  • teddyh · May 11, 2019 · Recommends

    Instead of some proprietary book, I would suggest people read the classic Advanced Bash-Scripting Guide: http://tldp.org/guides.html#abs Beginners might prefer the Bash Guide for Beginners: http://tldp.org/guides.html#bbg The Bash manual page is concise because it is a Unix manual page. Unix manual…

    on “Surprising Bash Variables” ↗
  • teddyh · Jan 12, 2020 · Recommends

    Advanced Bash-Scripting Guide, working link: https://www.tldp.org/LDP/abs/html/ (Your link, without “www”, gives me a certificate error.)

    on “Bash $* and $@ (2017)” ↗
  • zcw100 · Dec 13, 2020 · Recommends

    I’d recommend the Advanced Bash Scripting Guide https://tldp.org/LDP/abs/html/ and make peace with the fact that you’ll never know it all and enjoy the journey. Years later you’ll still be stumbling across new stuff.

    on “Ask HN: How do I become a shell god?” ↗
  • npongratz · Nov 2, 2021 · Recommends

    The Advanced Bash-Scripting Guide also has some (IMO) good advice, with a footnoted mention of sysexits.h: https://tldp.org/LDP/abs/html/exitcodes.html > The author of this document proposes restricting user-defined exit codes to the…

    on “Sysexits – preferable exit codes for programs” ↗
  • tristor · Sep 8, 2021 · Recommends

    …https://www.amazon.com/Linux-Command-Shell-Scripting-Bible/d... UNIX Shell Programming: https://www.amazon.com/Unix-Shell-Programming-Stephen-Kochan... BASH Hackers Wiki: https://wiki.bash-hackers.org/ TLDP Advanced BASH Scripting Guide: https://tldp.org/LDP/abs/html/ The Debian Administrator's Handbook: https://debian-handbook.info/browse/stable/ TLDP Linux System Administrator's Guide: https://tldp.org/LDP/sag/html/index.html Performance…

    on “My £4 a month server can handle 4.2M requests a day” ↗
  • a3n · Dec 5, 2013 · Recommends

    …find things but you should know your way around it: $ man bash Intro, Fundamentals: BASH Programming - Introduction HOW-TO: http://tldp.org/HOWTO/Bash-Prog-Intro-HOWTO.html You'll get here soon enough: Advanced Bash-Scripting Guide: http://www.tldp.org/LDP/abs/html/ Ideas: http://www.bashoneliners.com/ http://www.commandlinefu.com/commands/browse http://www.catonmat.net/sitemap/

    on “Ask HN: Best Open Source Beginners Book for learning Shell” ↗
  • julie1 · Sep 27, 2014 · Recommends

    …scripts. With PAM we could have even be able to use kerberos to control the security... I could have done lots of things... I still can ... Bash I still hate you for not documenting this, and more YOU Advanced Bash Scripting guide for being so awesome and missing that. ABS you failed me. http://www.tldp.org/LDP/abs/html/functions.html

    on “Not a bash bug” ↗
  • benj2240 · Aug 12, 2015 · Recommends

    You might like the Advanced Bash Scripting Guide. To quote: "This tutorial assumes no previous knowledge of scripting or programming, yet progresses rapidly toward an intermediate/advanced level of instruction... It serves as a textbook, a manual for…

    on “Ask HN: How to be a good bash script writer?” ↗
  • ProfDreamer · Dec 15, 2015 · Recommends

    The Advanced Bash-Scripting Guide is a good resource as well: http://www.tldp.org/LDP/abs/html/abs-guide.html

    on “Bash Academy” ↗
  • chuckmcknight · Jul 1, 2017 · Recommends

    Work through the Advanced Bash Scripting Guide (http://freecode.com/projects/advancedbashscriptingguide/). It's a great resource and is one that I turn to when I need to remind myself of how to do something.

    on “Ask HN: How can I get better at bash?” ↗

Keyboard shortcuts

/
Focus search
j / k
Next / previous book
Enter
Open focused book
Esc
Close / go back
g h
Go to Home
g t
Go to Top all-time
g m
Go to Most recommended
g r
Go to Rising
g f
Go to For You
?
Show this help