mirror of
https://codeberg.org/spire/spcomp.git
synced 2026-06-03 08:34:12 +02:00
overwrite the target without creating a new node
This commit is contained in:
parent
42f6390063
commit
21e975fd84
1 changed files with 3 additions and 2 deletions
|
|
@ -32,12 +32,13 @@ OUT="${IN%.sp}.smx"
|
||||||
chown $(stat -c '%u' "$IN"):$(stat -c '%g' "$IN") "$OUT"
|
chown $(stat -c '%u' "$IN"):$(stat -c '%g' "$IN") "$OUT"
|
||||||
|
|
||||||
if [ -d "/output" ]; then
|
if [ -d "/output" ]; then
|
||||||
cp $OUT /output
|
// copy without changing the file node
|
||||||
|
cat $OUT > /output/$OUT
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -z "$OUTPUT" ]
|
if [ ! -z "$OUTPUT" ]
|
||||||
then
|
then
|
||||||
mv $OUT /tmp/out.smx
|
mv $OUT /tmp/out.smx
|
||||||
cd "$BASEDIR"
|
cd "$BASEDIR"
|
||||||
mv /tmp/out.smx $OUTPUT
|
cat /tmp/out.smx > $OUTPUT
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue