Skip to content

Commit

Permalink
update build number
Browse files Browse the repository at this point in the history
  • Loading branch information
danemadsen committed Jul 6, 2024
1 parent ff9f42a commit 18f8f7d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
7 changes: 7 additions & 0 deletions .github/scripts/update_build_number.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash

# Get the number of commits
commit_count=$(git rev-list --count HEAD)

# Update the pubspec.yaml file with the new build number
sed -i '' "s/version: \(.*\)+.*/version: \1+$commit_count/" ../../pubspec.yaml
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
# In Windows, build-name is used as the major, minor, and patch parts
# of the product and file versions while build-number is used as the build suffix.
version: 1.2.9+29
version: 1.2.9+1697

environment:
sdk: '>=3.0.0 <4.0.0'
Expand Down

0 comments on commit 18f8f7d

Please sign in to comment.