Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
org.benoitharrault.random
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
android
org.benoitharrault.random
Merge requests
!8
Resolve "Skip build / release if version is not changed"
Code
Review changes
Check out branch
Download
Patches
Plain diff
Expand sidebar
Merged
Resolve "Skip build / release if version is not changed"
12-skip-build-release-if-version-is-not-changed
into
master
Overview
0
Commits
1
Pipelines
2
Changes
1
Merged
Resolve "Skip build / release if version is not changed"
Benoît Harrault
requested to merge
12-skip-build-release-if-version-is-not-changed
into
master
Jun 29, 2021
Overview
0
Commits
1
Pipelines
2
Changes
1
Closes
#12 (closed)
Edited
Jun 29, 2021
by
Benoît Harrault
0
0
Merge request reports
Compare
master
master (base)
and
latest version
latest version
b0986c87
1 commit,
Jun 29, 2021
1 file
+
13
−
3
Side-by-side
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
.gitlab-ci.yml
+
13
−
3
View file @ b0986c87
Edit in single-file editor
Open in Web IDE
Show full file
@@ -63,9 +63,19 @@ android:build-release:
@@ -63,9 +63,19 @@ android:build-release:
-
echo keyAlias=$ANDROID_KEY_ALIAS >> android/key.properties
-
echo keyAlias=$ANDROID_KEY_ALIAS >> android/key.properties
-
echo keyPassword=$ANDROID_KEY_PASSWORD >> android/key.properties
-
echo keyPassword=$ANDROID_KEY_PASSWORD >> android/key.properties
# build flutter app
# build flutter app
-
flutter packages get
-
VERSION_FILE="$(find . -name 'gradle.properties' | head -n1)"
-
flutter clean
-
VERSION_NAME="$(grep '^app.versionName=' "${VERSION_FILE}" | cut -d'=' -f2)"
-
flutter build apk --release
-
VERSION_CODE="$(grep '^app.versionCode=' "${VERSION_FILE}" | cut -d'=' -f2)"
-
TAG_NAME="Release_${VERSION_NAME}_${VERSION_CODE}"
-
echo "${TAG_NAME}"
-
>
if [ $(git tag -l "${TAG_NAME}") ]; then
echo "Tag ${TAG_NAME} already exists. Skipping build release."
else
flutter packages get
flutter clean
flutter build apk --release
fi
# prepare artifact
# prepare artifact
-
find . -name "*.apk"
# where is my apk?
-
find . -name "*.apk"
# where is my apk?
artifacts
:
artifacts
:
Loading