diff --git a/.gitignore b/.gitignore index 24bf1cf..49c27be 100644 --- a/.gitignore +++ b/.gitignore @@ -331,6 +331,9 @@ ASALocalRun/ # MFractors (Xamarin productivity tool) working folder .mfractor/ +# # local file +# /image/2018-12-19_16h24_46.mp4 /image/make_gif_by_ffmpeg.txt +/packaging diff --git a/100_build_exe.bat b/100_build_exe.bat new file mode 100644 index 0000000..3c952fa --- /dev/null +++ b/100_build_exe.bat @@ -0,0 +1,33 @@ +@echo off + +REM -------------------------------------------------- +REM Šeƒrƒ‹ƒhŠÂ‹«—p‚̊‹«•Ï”Ý’è +REM -------------------------------------------------- +REM https://www.appveyor.com/docs/environment-variables/ +if "%APPVEYOR%"=="True" ( + set EXTRA_CMD=/verbosity:minimal /logger:"%ProgramFiles%\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll" + set MSBUILD_PATH=msbuild + set SLN_PATH="%APPVEYOR_BUILD_FOLDER%\CompactMeter.sln" +) else ( + set EXTRA_CMD= + set MSBUILD_PATH="%ProgramFiles(x86)%\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\MSBuild.exe" + set SLN_PATH=CompactMeter.sln +) + +REM -------------------------------------------------- +REM 32bit build +REM -------------------------------------------------- +set CMD=%MSBUILD_PATH% %SLN_PATH% /p:Platform=x86 /p:Configuration=Release /t:"Build" %EXTRA_CMD% +echo. +echo %CMD% +echo. +%CMD% + +REM -------------------------------------------------- +REM 64bit build +REM -------------------------------------------------- +set CMD=%MSBUILD_PATH% %SLN_PATH% /p:Platform=x64 /p:Configuration=Release /t:"Build" %EXTRA_CMD% +echo. +echo %CMD% +echo. +%CMD% diff --git a/200_packaging.bat b/200_packaging.bat new file mode 100644 index 0000000..c16c457 --- /dev/null +++ b/200_packaging.bat @@ -0,0 +1,62 @@ +@echo off + +set BASE_DIR=%~dp0 + +REM -------------------------------------------------- +REM å„ビルド環境用ã®ç’°å¢ƒå¤‰æ•°è¨­å®š +REM -------------------------------------------------- +REM https://www.appveyor.com/docs/environment-variables/ +if "%APPVEYOR%"=="True" ( + set ZIP_CMD=7z + REM ARTIFACT_VERSION 㯠appveyor.yml ã® before_build: ã§è¨­å®šæ¸ˆ +) else ( + set ZIP_CMD="C:\Program Files\7-Zip\7z" + set ARTIFACT_VERSION=X_X_X +) + +REM -------------------------------------------------- +REM 作業ディレクトリã®æº–å‚™ +REM -------------------------------------------------- +set WORK_DIR=%BASE_DIR%packaging +rmdir /S /Q %WORK_DIR% +mkdir %WORK_DIR% +if %errorlevel% neq 0 (echo error && exit /b 1) + +REM -------------------------------------------------- +REM ファイルåŽé›† +REM -------------------------------------------------- +echo. +echo collect files +echo. +copy /Y /B Release\CompactMeter.exe %WORK_DIR% +copy /Y /B Release\register.exe %WORK_DIR% +copy /Y /B x64\Release\CompactMeter_64.exe %WORK_DIR% +copy /Y /B README.md %WORK_DIR% + +REM -------------------------------------------------- +REM コード署å +REM -------------------------------------------------- +if "%APPVEYOR%"=="True" ( + echo. + echo skip sign + echo. +) else ( + echo. + echo sign + echo. + set SIGNTOOL="C:\Program Files (x86)\Windows Kits\10\bin\10.0.17763.0\x64\signtool" + %SIGNTOOL% sign /a /fd SHA256 /v /tr http://timestamp.comodoca.com/?td=sha256 /td sha256 ^ + %WORK_DIR%\CompactMeter.exe ^ + %WORK_DIR%\CompactMeter_64.exe ^ + %WORK_DIR%\register.exe +) + +REM -------------------------------------------------- +REM ZIP +REM -------------------------------------------------- +echo. +echo ZIP +echo. +cd %WORK_DIR% +%ZIP_CMD% a CompactMeter_v%ARTIFACT_VERSION%.zip CompactMeter.exe CompactMeter_64.exe register.exe README.md +cd .. diff --git a/README.md b/README.md index f845802..a6c6d83 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,8 @@ Direct2D 対応ãªã®ã§CPUè² è·ã‚’低ã抑ãˆã¦ã„ã¾ã™ã€‚ ## 変更履歴 -### v1.2.0 (2019.01.xx) +### v1.2.0 (2019.01.18) +- 実行ファイルã«ãƒ‡ã‚¸ã‚¿ãƒ«ç½²åã™ã‚‹ã‚ˆã†ã«ã—㟠- 背景色変更機能を追加 - ドライブã®ãƒ¡ãƒ¼ã‚¿ãƒ¼ã‚’å„ドライブå˜ä½ã§On/Offã§ãるよã†ã«å¤‰æ›´ - 自動起動設定を追加 @@ -57,3 +58,20 @@ Direct2D 対応ãªã®ã§CPUè² è·ã‚’低ã抑ãˆã¦ã„ã¾ã™ã€‚ ### v1.0.0 (2018.12.27) - åˆç‰ˆãƒªãƒªãƒ¼ã‚¹ + + +## 開発メモ + +### å‰æ +- 開発環境: Visual Studio Community 2017 +- OS: Windows 10 Pro 64bit +- 7-Zip (64bit版) +- デジタル署åã™ã‚‹å ´åˆï¼šã‚³ãƒ¼ãƒ‰è¨¼æ˜Žæ›¸ãŒã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«æ¸ˆã¿ã§ã‚ã‚‹ã“㨠+ +### リリース作業 + +- 下記を順ã«å®Ÿè¡Œã™ã‚‹ + - `100_build_exe.bat` + - `200_packaging.bat` +- `packaging` 内ã®å„ファイルãŒãƒ‡ã‚¸ã‚¿ãƒ«ç½²å済ã¿ã§ã‚ã‚‹ã“ã¨ã‚’確èªã™ã‚‹ +- `packaging/CompactMeter_vXXX.zip` をリãƒãƒ¼ãƒ ã— GitHub ã® Releases ã«ã‚¢ãƒƒãƒ—ロードã™ã‚‹ diff --git a/appveyor.yml b/appveyor.yml index 15eac48..272636d 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -20,17 +20,12 @@ before_build: # "1.1.0.76" -> "1_1_0_76" - set ARTIFACT_VERSION=%APPVEYOR_BUILD_VERSION:.=_% -build: - project: CompactMeter.sln +build_script: + - 100_build_exe.bat after_build: - # 64bit build - - msbuild "%APPVEYOR_BUILD_FOLDER%\CompactMeter.sln" /p:Platform=x64 /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll" # packaging - - copy Release\CompactMeter.exe . - - copy Release\register.exe . - - copy x64\Release\CompactMeter_64.exe . - - 7z a CompactMeter_v%ARTIFACT_VERSION%.zip CompactMeter.exe CompactMeter_64.exe register.exe README.md + - 200_packaging.bat artifacts: - - path: CompactMeter_v$(ARTIFACT_VERSION).zip + - path: packaging/CompactMeter_v$(ARTIFACT_VERSION).zip