diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2017-01-02 15:50:52 +1300 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2017-01-02 15:50:52 +1300 |
commit | ca20e3e759d168a9f4dacdb05dad2a2b295f458b (patch) | |
tree | 687b7c6c983933e0e7fa04c8a631dbc7a0386e58 /sh/shrc.d/pmd.sh | |
parent | Remove an unnecessary trailing slash from ad() (diff) | |
download | dotfiles-ca20e3e759d168a9f4dacdb05dad2a2b295f458b.tar.gz dotfiles-ca20e3e759d168a9f4dacdb05dad2a2b295f458b.zip |
Add marked-dir tools
Diffstat (limited to 'sh/shrc.d/pmd.sh')
-rw-r--r-- | sh/shrc.d/pmd.sh | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sh/shrc.d/pmd.sh b/sh/shrc.d/pmd.sh new file mode 100644 index 00000000..03f18b7b --- /dev/null +++ b/sh/shrc.d/pmd.sh @@ -0,0 +1,8 @@ +# Print the marked directory +pmd() { + if ! [ -n "$PMD" ] ; then + printf >&2 'pmd(): Mark not set\n' + return 2 + fi + printf '%s\n' "$PMD" +} |