mirror of
https://github.com/aseprite/aseprite.git
synced 2025-01-01 00:23:35 +00:00
Fix running Lua scripts that use temp dir ($t) on Windows
This commit is contained in:
parent
47b3098c8b
commit
e857b0e3e5
@ -2,7 +2,7 @@
|
|||||||
# Copyright (C) 2018-2019 Igara Studio S.A.
|
# Copyright (C) 2018-2019 Igara Studio S.A.
|
||||||
|
|
||||||
function list_files() {
|
function list_files() {
|
||||||
oldwd=$(pwd)
|
oldwd=$(pwd $PWDARG)
|
||||||
cd $1 && ls -1 *.*
|
cd $1 && ls -1 *.*
|
||||||
cd $oldwd
|
cd $oldwd
|
||||||
}
|
}
|
||||||
@ -162,7 +162,7 @@ $ASEPRITE -b -script "$d/compare.lua" || exit 1
|
|||||||
|
|
||||||
d=$t/save-as-without-path
|
d=$t/save-as-without-path
|
||||||
mkdir $d
|
mkdir $d
|
||||||
oldwd=$(pwd)
|
oldwd=$(pwd $PWDARG)
|
||||||
cd $d
|
cd $d
|
||||||
$ASEPRITE -b -split-layers $oldwd/sprites/abcd.aseprite -save-as issue591.png || exit 1
|
$ASEPRITE -b -split-layers $oldwd/sprites/abcd.aseprite -save-as issue591.png || exit 1
|
||||||
if [[ ! -f "issue591 (a).png" ||
|
if [[ ! -f "issue591 (a).png" ||
|
||||||
|
@ -33,6 +33,12 @@ if [[ "$filter" != "" ]]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
t=$(mktemp -d)
|
t=$(mktemp -d)
|
||||||
|
if [[ "$(uname)" =~ "MINGW32" ]] || [[ "$(uname)" =~ "MSYS_NT-10.0" ]] ; then
|
||||||
|
PWDARG=-W
|
||||||
|
t=$(cd "$t" && pwd $PWDARG)
|
||||||
|
else
|
||||||
|
PWDARG=
|
||||||
|
fi
|
||||||
echo Temp dir: $t
|
echo Temp dir: $t
|
||||||
export ASEPRITE_USER_FOLDER=$t
|
export ASEPRITE_USER_FOLDER=$t
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user