piskel/misc/scripts/package-mac-application.cmd

56 lines
1.3 KiB
Batchfile
Raw Normal View History

2014-06-21 20:39:37 +00:00
setlocal
2014-06-21 22:05:02 +00:00
@ECHO off
2014-06-21 20:39:37 +00:00
pushd ..\..
set PISKEL_HOME=%cd%
popd
set APP_BIN=%PISKEL_HOME%\dest\desktop\cache\mac\0.9.2
set MISC_FOLDER=%PISKEL_HOME%\misc
set RELEASES_FOLDER=%PISKEL_HOME%\dest\desktop\releases
set DEST_FOLDER=%RELEASES_FOLDER%\mac
2014-06-21 22:05:02 +00:00
ECHO "Building Piskel executable for Windows ..."
2014-06-21 20:39:37 +00:00
2014-06-21 22:05:02 +00:00
ECHO "Creating release directory ..."
2014-06-21 20:39:37 +00:00
mkdir %DEST_FOLDER%
2014-06-21 22:05:02 +00:00
ECHO "DONE"
2014-06-21 20:39:37 +00:00
2014-06-21 22:05:02 +00:00
ECHO "Creating application folder ..."
2014-06-21 20:39:37 +00:00
mkdir "%DEST_FOLDER%\piskel.app"
2014-06-21 22:05:02 +00:00
ECHO "DONE"
2014-06-21 20:39:37 +00:00
2014-06-21 22:05:02 +00:00
ECHO "Unzip application ..."
2014-06-21 20:39:37 +00:00
mkdir "%APP_BIN%\node-webkit-unzipped"
7za x "%APP_BIN%\node-webkit-v0.9.2-osx-ia32.zip" -o"%APP_BIN%\node-webkit-unzipped"
2014-06-21 22:05:02 +00:00
ECHO "DONE"
2014-06-21 20:39:37 +00:00
pause
2014-06-21 22:05:02 +00:00
ECHO "Copy application ..."
2014-06-21 20:39:37 +00:00
xcopy "%APP_BIN%\node-webkit-unzipped\node-webkit.app" "%DEST_FOLDER%\piskel.app" /E
:: xcopy "%APP_BIN%\node-webkit.app" "%DEST_FOLDER%\piskel.app" /E
2014-06-21 22:05:02 +00:00
ECHO "DONE"
2014-06-21 20:39:37 +00:00
2014-06-21 22:05:02 +00:00
ECHO "Copy Info.plist ..."
2014-06-21 20:39:37 +00:00
set CONTENTS_FOLDER=%DEST_FOLDER%\piskel.app\Contents
copy "%MISC_FOLDER%\desktop\Info.plist" "%CONTENTS_FOLDER%\"
2014-06-21 22:05:02 +00:00
ECHO "DONE"
2014-06-21 20:39:37 +00:00
2014-06-21 22:05:02 +00:00
ECHO "Copy application ..."
2014-06-21 20:39:37 +00:00
set RESOURCES_FOLDER=%CONTENTS_FOLDER%\Resources
copy "%RELEASES_FOLDER%\piskel\piskel.nw" "%RESOURCES_FOLDER%\"
mv "%RESOURCES_FOLDER%\piskel.nw" "%RESOURCES_FOLDER%\app.nw"
2014-06-21 22:05:02 +00:00
ECHO "%RESOURCES_FOLDER%"
ECHO "DONE"
2014-06-21 20:39:37 +00:00
2014-06-21 22:05:02 +00:00
ECHO "Copy icon ..."
DEL "%RESOURCES_FOLDER%\nw.icns"
COPY "%MISC_FOLDER%\desktop\nw.icns" "%RESOURCES_FOLDER%\"
ECHO "DONE"
2014-06-21 20:39:37 +00:00
pause
explorer "%DEST_FOLDER%"
endlocal