@@ -183,17 +183,242 @@ jobs:
183183 android-artifacts/stack_wallet-android-armeabi-v7a-${VERSION}.apk
184184 cp build/app/outputs/flutter-apk/app-x86_64-release.apk \
185185 android-artifacts/stack_wallet-android-x86_64-${VERSION}.apk
186- cp build/app/outputs/bundle/release/app-release.aab \
187- android-artifacts/stack_wallet-android-${VERSION}.aab
188186
189187 - uses : actions/upload-artifact@v4
190188 with :
191189 name : stack_wallet-android-${{ steps.ver.outputs.version }}
192190 path : android-artifacts/
193191
192+ build-windows :
193+ runs-on : windows-latest
194+ defaults :
195+ run :
196+ shell : bash
197+ steps :
198+ - uses : actions/checkout@v6
199+ with :
200+ fetch-depth : 0
201+ submodules : recursive
202+
203+ - name : Set version
204+ id : ver
205+ run : |
206+ if [ "${{ github.ref_type }}" = "tag" ]; then
207+ VERSION="${{ github.ref_name }}"
208+ VERSION="${VERSION#v}"
209+ BUILD_NUMBER="${{ github.run_number }}"
210+ else
211+ VERSION="${{ inputs.version }}"
212+ BUILD_NUMBER="${{ inputs.build_number }}"
213+ fi
214+ echo "version=${VERSION}" >> $GITHUB_OUTPUT
215+ echo "build_number=${BUILD_NUMBER}" >> $GITHUB_OUTPUT
216+
217+ - uses : subosito/flutter-action@v2
218+ with :
219+ flutter-version : ' 3.38.1'
220+ channel : ' stable'
221+
222+ - name : Configure app
223+ run : |
224+ cd scripts
225+ echo "yes" | ./build_app.sh \
226+ -v "${{ steps.ver.outputs.version }}" \
227+ -b "${{ steps.ver.outputs.build_number }}" \
228+ -p windows -a stack_wallet -d -s
229+
230+ - name : Get dependencies
231+ run : flutter pub get
232+
233+ - name : Create git_versions.dart stubs
234+ run : |
235+ mkdir -p crypto_plugins/flutter_libepiccash/lib
236+ mkdir -p crypto_plugins/flutter_libmwc/lib
237+
238+ EPIC_TAG=$(git -C crypto_plugins/flutter_libepiccash describe --tags --exact-match HEAD 2>/dev/null || echo "dev")
239+ MWC_TAG=$(git -C crypto_plugins/flutter_libmwc describe --tags --exact-match HEAD 2>/dev/null || echo "dev")
240+
241+ printf 'String getPluginVersion() => "%s";\n' "$EPIC_TAG" \
242+ > crypto_plugins/flutter_libepiccash/lib/git_versions.dart
243+ printf 'String getPluginVersion() => "%s";\n' "$MWC_TAG" \
244+ > crypto_plugins/flutter_libmwc/lib/git_versions.dart
245+
246+ - name : Decode secrets
247+ env :
248+ CHANGE_NOW : ${{ secrets.CHANGE_NOW }}
249+ run : echo "$CHANGE_NOW" | base64 --decode > lib/external_api_keys.dart
250+
251+ - name : Generate app config
252+ run : dart run build_runner build --delete-conflicting-outputs
253+
254+ - name : Build
255+ run : flutter build windows --release
256+
257+ - name : Package
258+ shell : pwsh
259+ run : |
260+ Compress-Archive -Path build\windows\x64\runner\Release\* `
261+ -DestinationPath "stack_wallet-windows-x86_64-${{ steps.ver.outputs.version }}.zip"
262+
263+ - uses : actions/upload-artifact@v4
264+ with :
265+ name : stack_wallet-windows-x86_64-${{ steps.ver.outputs.version }}
266+ path : stack_wallet-windows-x86_64-${{ steps.ver.outputs.version }}.zip
267+
268+ build-macos :
269+ runs-on : macos-latest
270+ steps :
271+ - uses : actions/checkout@v6
272+ with :
273+ fetch-depth : 0
274+ submodules : recursive
275+
276+ - name : Set version
277+ id : ver
278+ run : |
279+ if [ "${{ github.ref_type }}" = "tag" ]; then
280+ VERSION="${{ github.ref_name }}"
281+ VERSION="${VERSION#v}"
282+ BUILD_NUMBER="${{ github.run_number }}"
283+ else
284+ VERSION="${{ inputs.version }}"
285+ BUILD_NUMBER="${{ inputs.build_number }}"
286+ fi
287+ echo "version=${VERSION}" >> $GITHUB_OUTPUT
288+ echo "build_number=${BUILD_NUMBER}" >> $GITHUB_OUTPUT
289+
290+ - uses : subosito/flutter-action@v2
291+ with :
292+ flutter-version : ' 3.38.1'
293+ channel : ' stable'
294+
295+ - name : Configure app
296+ run : |
297+ cd scripts
298+ echo "yes" | ./build_app.sh \
299+ -v "${{ steps.ver.outputs.version }}" \
300+ -b "${{ steps.ver.outputs.build_number }}" \
301+ -p macos -a stack_wallet -d -s
302+
303+ - name : Get dependencies
304+ run : flutter pub get
305+
306+ - name : Create git_versions.dart stubs
307+ run : |
308+ mkdir -p crypto_plugins/flutter_libepiccash/lib
309+ mkdir -p crypto_plugins/flutter_libmwc/lib
310+
311+ EPIC_TAG=$(git -C crypto_plugins/flutter_libepiccash describe --tags --exact-match HEAD 2>/dev/null || echo "dev")
312+ MWC_TAG=$(git -C crypto_plugins/flutter_libmwc describe --tags --exact-match HEAD 2>/dev/null || echo "dev")
313+
314+ printf 'String getPluginVersion() => "%s";\n' "$EPIC_TAG" \
315+ > crypto_plugins/flutter_libepiccash/lib/git_versions.dart
316+ printf 'String getPluginVersion() => "%s";\n' "$MWC_TAG" \
317+ > crypto_plugins/flutter_libmwc/lib/git_versions.dart
318+
319+ - name : Decode secrets
320+ env :
321+ CHANGE_NOW : ${{ secrets.CHANGE_NOW }}
322+ run : echo "$CHANGE_NOW" | base64 --decode > lib/external_api_keys.dart
323+
324+ - name : Generate app config
325+ run : dart run build_runner build --delete-conflicting-outputs
326+
327+ - name : Build
328+ run : flutter build macos --release
329+
330+ - name : Package
331+ run : |
332+ cd "build/macos/Build/Products/Release"
333+ zip -r "$GITHUB_WORKSPACE/stack_wallet-macos-aarch64-${{ steps.ver.outputs.version }}.zip" \
334+ "Stack Wallet.app"
335+
336+ - uses : actions/upload-artifact@v4
337+ with :
338+ name : stack_wallet-macos-aarch64-${{ steps.ver.outputs.version }}
339+ path : stack_wallet-macos-aarch64-${{ steps.ver.outputs.version }}.zip
340+
341+ build-ios :
342+ runs-on : macos-latest
343+ steps :
344+ - uses : actions/checkout@v6
345+ with :
346+ fetch-depth : 0
347+ submodules : recursive
348+
349+ - name : Set version
350+ id : ver
351+ run : |
352+ if [ "${{ github.ref_type }}" = "tag" ]; then
353+ VERSION="${{ github.ref_name }}"
354+ VERSION="${VERSION#v}"
355+ BUILD_NUMBER="${{ github.run_number }}"
356+ else
357+ VERSION="${{ inputs.version }}"
358+ BUILD_NUMBER="${{ inputs.build_number }}"
359+ fi
360+ echo "version=${VERSION}" >> $GITHUB_OUTPUT
361+ echo "build_number=${BUILD_NUMBER}" >> $GITHUB_OUTPUT
362+
363+ - uses : dtolnay/rust-toolchain@master
364+ with :
365+ toolchain : ' 1.71.0'
366+ targets : aarch64-apple-ios
367+
368+ - uses : subosito/flutter-action@v2
369+ with :
370+ flutter-version : ' 3.38.1'
371+ channel : ' stable'
372+
373+ - name : Configure app
374+ run : |
375+ cd scripts
376+ echo "yes" | ./build_app.sh \
377+ -v "${{ steps.ver.outputs.version }}" \
378+ -b "${{ steps.ver.outputs.build_number }}" \
379+ -p ios -a stack_wallet -d -s
380+
381+ - name : Get dependencies
382+ run : flutter pub get
383+
384+ - name : Create git_versions.dart stubs
385+ run : |
386+ mkdir -p crypto_plugins/flutter_libepiccash/lib
387+ mkdir -p crypto_plugins/flutter_libmwc/lib
388+
389+ EPIC_TAG=$(git -C crypto_plugins/flutter_libepiccash describe --tags --exact-match HEAD 2>/dev/null || echo "dev")
390+ MWC_TAG=$(git -C crypto_plugins/flutter_libmwc describe --tags --exact-match HEAD 2>/dev/null || echo "dev")
391+
392+ printf 'String getPluginVersion() => "%s";\n' "$EPIC_TAG" \
393+ > crypto_plugins/flutter_libepiccash/lib/git_versions.dart
394+ printf 'String getPluginVersion() => "%s";\n' "$MWC_TAG" \
395+ > crypto_plugins/flutter_libmwc/lib/git_versions.dart
396+
397+ - name : Decode secrets
398+ env :
399+ CHANGE_NOW : ${{ secrets.CHANGE_NOW }}
400+ run : echo "$CHANGE_NOW" | base64 --decode > lib/external_api_keys.dart
401+
402+ - name : Generate app config
403+ run : dart run build_runner build --delete-conflicting-outputs
404+
405+ - name : Build
406+ run : flutter build ios --release --no-codesign
407+
408+ - name : Package IPA
409+ run : |
410+ mkdir Payload
411+ cp -r build/ios/iphoneos/Runner.app Payload/
412+ zip -r "stack_wallet-ios-aarch64-${{ steps.ver.outputs.version }}.ipa" Payload/
413+
414+ - uses : actions/upload-artifact@v4
415+ with :
416+ name : stack_wallet-ios-aarch64-${{ steps.ver.outputs.version }}
417+ path : stack_wallet-ios-aarch64-${{ steps.ver.outputs.version }}.ipa
418+
194419 release :
195420 if : github.ref_type == 'tag'
196- needs : [build-linux, build-android]
421+ needs : [build-linux, build-android, build-windows, build-macos, build-ios ]
197422 runs-on : ubuntu-latest
198423 permissions :
199424 contents : write
0 commit comments