1 2 3 4 5 6
#!/bin/bash #create $TMP and $TMPDIR [ -n "$TMP" -a ! -d "$TMP" ] && mkdir "$TMP" [ -n "$TMPDIR" -a ! -d "$TMPDIR" ] && mkdir "$TMPDIR"