summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortv <tv@iiso>2011-09-24 22:43:09 +0200
committertv <tv@iiso>2011-09-24 22:43:09 +0200
commit52ca584dcd00236a6fe605121cc1b2f0f580e692 (patch)
treeeb2417bd670e21e87a805586ad50e0b0a69224e6
parentba96a0a78c46bdaedc1c3ffcda0cc5c8525dd967 (diff)
//util magic: simplify create
-rwxr-xr-xutil/bin/magic12
1 files changed, 5 insertions, 7 deletions
diff --git a/util/bin/magic b/util/bin/magic
index 8f3c7e04..874a8883 100755
--- a/util/bin/magic
+++ b/util/bin/magic
@@ -14,13 +14,11 @@ has() {
create() {
destroy "$@"
- cache="`cat $3`"
- {
- echo "$cache"
- echo "$bs"
- cat
- echo "$es"
- } >$3
+ cat>>$3<<EOF
+$bs
+`cat`
+$es
+EOF
}
#retrieve() {