Top 1K Features Creators Events Podcasts Books Extensions Interviews Blog Explorer CSV

Bash

< >

Bash is an open source programming language created in 1989 by Brian Fox.

#19on PLDB 35Years Old 2mRepos
Download source code:
git clone https://git.savannah.gnu.org/git/bash.git
Homepage · Leet Sheet · REPL · Try It Online · Source Code · Wikipedia · Subreddit · Docs

Bash is a Unix shell and command language written by Brian Fox for the GNU Project as a free software replacement for the Bourne shell. First released in 1989, it has been distributed widely as the default login shell for most Linux distributions and Apple's macOS (formerly OS X). A version is also available for Windows 10. Read more on Wikipedia...


Example from Riju:
echo "Hello, world!"
Example from hello-world:
#!/bin/sh echo "Hello World"
Example from Linguist:
#!/bin/sh echo "sh"
Example from Wikipedia:
cd "$SOMEWHERE" && ./do_something || echo "An error occurred" >&2
if then do else elif while until for in esac fi fin fil done exit set unset export function

Language features

Feature Supported Example Token
Standard Library echo "Hello, World!"
Conditionals
Functions
While Loops
File Imports source ./bash.sh
Assignment FOO="bar" =
Print() Debugging echo "Hello World" echo
Pipes echo "Hello world" > output.txt
Here Document cat <
Integers PLDB=80766866
Strings "Hello world" "
Line Comments # A comment #
Comments # A comment
Variable Substitution Syntax STR="Hello World!" echo $STR
Sets X
MultiLine Comments X
Semantic Indentation X
Units of Measure X

- Build the next great programming language · Add · Issues · About · Search · Keywords · Livestreams · Labs · Resources · Acknowledgements

Built with Scroll v164.7.0