tempsh ~> scratsh - scripts - various script and utils
HTML git clone git://z3bra.org/scripts
DIR Log
DIR Files
DIR Refs
---
DIR commit 8db675f0718bb7590e5b45b954872a2bcb4a7904
DIR parent 5a91b75eb90e6069d0ebb8ae5ad3061cf9bdfcb7
HTML Author: Willy Goiffon <dev@z3bra.org>
Date: Thu, 20 Aug 2026 22:13:28 +0000
tempsh ~> scratsh
Diffstat:
A scratsh | 5 +++++
D tempsh | 7 -------
2 files changed, 5 insertions(+), 7 deletions(-)
---
DIR diff --git a/scratsh b/scratsh
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+cd $(mktemp -d)
+trap "rm -rf $PWD" EXIT QUIT TERM INT
+${SHELL:-sh} -l
DIR diff --git a/tempsh b/tempsh
@@ -1,6 +0,0 @@
-#!/bin/sh
-
-TMP=$(mktemp -d)
-cd $TMP
-mksh -l
-rm -rf $TMP
-\ No newline at end of file