Skip to content

Commit

Permalink
updating yaml for authentication
Browse files Browse the repository at this point in the history
  • Loading branch information
Wahab-Khan committed Feb 19, 2025
1 parent 7a1f3f3 commit 8b40a8e
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/simple_workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,12 @@ jobs:

- name: Authenticate & Publish
env:
PUB_CREDENTIALS: ${{ secrets.PUB_CREDENTIALS }} # 🔑 Store credentials in GitHub Secrets
PUB_CREDENTIALS: ${{ secrets.PUB_CREDENTIALS }} # 🔑 Uses stored credentials
run: |
echo "$PUB_CREDENTIALS" > credentials.json
flutter pub publish --force # ✅ Fixed command for Flutter packages
rm credentials.json # 🧹 Clean up credentials file
mkdir -p ~/.config/dart
echo "$PUB_CREDENTIALS" > ~/.config/dart/pub-credentials.json
flutter pub publish --force # ✅ Publishes the package
rm ~/.config/dart/pub-credentials.json # 🧹 Clean up
- name: Success Message
if: success()
Expand Down

0 comments on commit 8b40a8e

Please sign in to comment.