|author||Tom Ryder <firstname.lastname@example.org>||2016-08-17 17:38:45 +1200|
|committer||Tom Ryder <email@example.com>||2016-08-17 17:38:45 +1200|
|parent||Only pull if rebase possible (diff)|
Move simple Bash/pdksh functions into POSIX sh
Have only translated the scripts that translate readily into POSIX sh for now. More complex stuff like that bd/pd/sd/ud navigation for Bash doesn't port as easily, mostly because there isn't an analogue for the "local" keyword in POSIX.
Diffstat (limited to 'sh/shrc')
1 files changed, 7 insertions, 0 deletions
diff --git a/sh/shrc b/sh/shrc
new file mode 100644
@@ -0,0 +1,7 @@
+# Load all the POSIX-compatible functions from ~/.shrc.d; more advanced shells
+# like bash will have their own functions
+for shrc in "$HOME"/.shrc.d/*.sh ; do
+ [ -e "$shrc" ] || continue
+ . "$shrc"
+unset -v shrc