Skip to content

Commit

Permalink
flat puts object
Browse files Browse the repository at this point in the history
  • Loading branch information
mrehan27 committed Aug 6, 2024
1 parent 03e632c commit 49766b5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
4 changes: 0 additions & 4 deletions .github/workflows/build-sample-apps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,6 @@ jobs:
subdirectory: "apps/${{ matrix.sample-app }}"
lane: "generate_new_version"
options: '{"branch_name":"${{ github.ref_name }}", "pull_request_number":"${{ github.event.pull_request.number }}"}'
env:
SDK_VERSION_NAME: ${{ env.SDK_VERSION_NAME }}
APP_VERSION_NAME: ${{ env.APP_VERSION_NAME }}
APP_VERSION_CODE: ${{ env.APP_VERSION_CODE }}

- name: Update Flutter SDK Version
uses: maierj/fastlane-action@v3.1.0
Expand Down
9 changes: 4 additions & 5 deletions apps/amiapp_flutter/fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,7 @@ lane :generate_new_version do |options|
app_version_code = time_in_millis
UI.message("Generated new versions => SDK: #{sdk_version_name}, App: #{app_version_name} (#{app_version_code})")

puts ({
SDK_VERSION_NAME: sdk_version_name,
APP_VERSION_NAME: app_version_name,
APP_VERSION_CODE: app_version_code.to_s
})
puts SDK_VERSION_NAME: sdk_version_name, APP_VERSION_NAME: app_version_name, APP_VERSION_CODE: app_version_code.to_s
end

# Helper method to update pubspec version
Expand Down Expand Up @@ -89,6 +85,9 @@ lane :update_flutter_sdk_version do |options|
project_path = options[:project_path] || File.join(Dir.pwd, '../../..')
version_name = options[:version_name] || ENV['SDK_VERSION_NAME']

UI.message("Updating sdk version to #{sdk_version_name} in #{project_path}")
UI.message("Env vars => SDK_VERSION_NAME: #{ENV['SDK_VERSION_NAME']}, APP_VERSION_NAME: #{ENV['APP_VERSION_NAME']}, APP_VERSION_CODE: #{ENV['APP_VERSION_CODE']}")

update_pubspec_version(project_path, version_name)
end

Expand Down

0 comments on commit 49766b5

Please sign in to comment.