Skip to content

Commit b03604a

Browse files
build process
1 parent e720122 commit b03604a

File tree

5 files changed

+58
-7
lines changed

5 files changed

+58
-7
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ release/*
55
!release/Readme.txt
66
!release/config.ini
77
!release/build.sh
8-
!release/build.bat
8+
!release/build1.bat
9+
!release/build2.bat
910
test/*
1011
package-lock.json
1112
gui/misc/*

release/build.bat

Lines changed: 0 additions & 6 deletions
This file was deleted.

release/build.sh

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,29 @@
22

33
pkg -t node10-linux -o ./stratumproxy ../index.js
44

5+
rm -r ./stage/*
6+
7+
cp stratumproxy stage/
8+
cp config.ini stage/
9+
cp README.txt stage/
10+
11+
rm stratum-proxy-ver-linux.tar.gz
12+
13+
tar -czf stratum-proxy-ver-linux.tar.gz --directory=stage .
14+
15+
echo "."
16+
echo "."
17+
echo "."
18+
19+
if [ $? -ge 1 ] ; then
20+
echo "ERRORS WERE ENCOUNTERED!!!"
21+
echo "."
22+
echo "."
23+
echo "."
24+
exit 1
25+
fi
26+
27+
echo "script completed successfully"
28+
echo "."
29+
echo "."
30+
echo "."

release/build1.bat

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
2+
cd %~dp0
3+
4+
REM For some reason this has to be in a separate batch file. in my experience, any
5+
REM commands after pkg will not execute. it's like the batch file abruptly terminates!
6+
7+
pkg -t node10-win -o mvsp.exe ..\index.js --options title="Stratum Proxy"
8+

release/build2.bat

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
2+
cd %~dp0
3+
4+
REM copy in the most recent c# StratumProxy.exe
5+
6+
copy ..\gui\bin\Release\StratumProxy.exe .
7+
8+
REM copy to staging
9+
10+
del /Q .\stage\*.*
11+
12+
copy mvsp.exe stage
13+
copy README.txt stage
14+
copy config.ini stage
15+
copy StratumProxy.exe stage
16+
17+
REM create zip file
18+
19+
del "stratum-proxy-ver-win64.zip"
20+
21+
powershell.exe -nologo -noprofile -command "& { Add-Type -A 'System.IO.Compression.FileSystem'; [IO.Compression.ZipFile]::CreateFromDirectory('stage', 'stratum-proxy-ver-win64.zip'); }"
22+

0 commit comments

Comments
 (0)