Skip to content

Commit

Permalink
Enforce using lockfile and patch rive_common.
Browse files Browse the repository at this point in the history
  • Loading branch information
braniii committed Nov 14, 2023
1 parent 794db35 commit 28e33fe
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 2 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/build-flutter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,11 @@ jobs:
run: |
cd app
flutter --disable-telemetry
flutter pub get
flutter pub get --enforce-lockfile
- name: Patch Packages
run: |
cd app
bash patch_pubdev.sh
- name: 🤖📦 Create Android release
run: |
cd app
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/flutter-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,11 @@ jobs:
run: |
cd app
flutter --disable-telemetry
flutter pub get
flutter pub get --enforce-lockfile
- name: Patch Packages
run: |
cd app
bash patch_pubdev.sh
- name: 🤖📦 Create Android release
run: |
cd app
Expand Down
13 changes: 13 additions & 0 deletions app/patch_pubdev.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# This file is intendet to patch packages from pub.dev
#
# Path rive_common to remove build-id
RIVE_COMMON_VERSION="$(grep -A7 -P '^..rive_common' pubspec.lock | sed -E -n -e 's/^.*version:\ "([0-9.]+)"/\1/p')"

# get path to pub_cache directory
if [[ -v PUB_CACHE ]]; then
PUB_PATH="$PUB_CACHE"
else
PUB_PATH="$HOME/.pub_cache"
fi

patch "${PUB_PATH}/hosted/pub.dev/rive_common-${RIVE_COMMON_VERSION}/premake5_rive_plugin.lua" "rive_common.patch"
22 changes: 22 additions & 0 deletions app/rive_common.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
--- premake5_rive_plugin.lua 2023-11-08 21:16:37.466026217 +0100
+++ premake5_rive_plugin.lua 2023-11-08 21:36:12.735951780 +0100
@@ -101,7 +101,8 @@
linkoptions {
'-Oz',
'-g0',
- '-flto'
+ '-flto',
+ '--build-id=None'
}
end
filter {'system:macosx', 'options:arch=arm64'}
@@ -452,7 +453,8 @@
linkoptions {
'-Oz',
'-g0',
- '-flto'
+ '-flto',
+ '--build-id=None'
}
end

0 comments on commit 28e33fe

Please sign in to comment.