Skip to content

Instantly share code, notes, and snippets.

@hamiltont
Created July 3, 2014 23:31
Show Gist options
  • Save hamiltont/b6f336792793f91cbbca to your computer and use it in GitHub Desktop.
Save hamiltont/b6f336792793f91cbbca to your computer and use it in GitHub Desktop.
temp
===============FILE 1 - test.sh==================
#!/bin/bash
test_function () {
echo hi there
}
bash subshell.sh
===============FILE 2 - subshell.sh==================
#!/bin/bash
test_function
===============OUTPUT==================
$ bash test.sh
subshell.sh: line 3: test_function: command not found
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment