Skip to content

Commit 8ad7667

Browse files
committed
tnntsync - npcdata permissions
1 parent 35ed083 commit 8ad7667

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

tnntsync.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/bin/sh
2-
DEBUG=1
2+
DEBUG=0
33
TNNTVAR=tnnt/var
44
bail()
55
{
@@ -50,6 +50,9 @@ do
5050
then
5151
echo "npcdata from $TAG ($NEWDATE) newer than local ($MYDATE) - replacing"
5252
MYDATE=$NEWDATE # So we don't copy it multiple times needlessly
53+
# Set perms first, so we don't try to read it before permissions are right.
54+
chown games:games npcdata.$TAG
55+
chmod 644 npcdata.$TAG
5356
[ -f npcdata ] && mv npcdata npcdata.old #mv will not disrupt open file descriptors
5457
mv npcdata.$TAG npcdata
5558
fi

0 commit comments

Comments
 (0)