Skip to content

Commit fcd6656

Browse files
committed
fix: release.yml
1 parent 6bd24fc commit fcd6656

2 files changed

Lines changed: 35 additions & 2 deletions

File tree

.github/workflows/release.yml

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ jobs:
3939
runs-on: ubuntu-latest
4040
permissions:
4141
contents: write # push version bump commit
42-
id-token: write # pub.dev OIDC trusted publisher
4342
outputs:
4443
tag: ${{ steps.meta.outputs.tag }}
4544
version: ${{ steps.meta.outputs.version }}
@@ -103,5 +102,39 @@ jobs:
103102
body_path: /tmp/release_notes.md
104103
prerelease: ${{ steps.meta.outputs.prerelease }}
105104

105+
publish:
106+
name: Publish to pub.dev
107+
needs: prepare
108+
runs-on: ubuntu-latest
109+
permissions:
110+
id-token: write # pub.dev OIDC trusted publisher
111+
steps:
112+
# `main` at this point already has the version bump `prepare` pushed —
113+
# the pushed tag itself still points at the pre-bump commit, so we
114+
# can't just let this default to `github.ref`.
115+
- uses: actions/checkout@v7
116+
with:
117+
ref: main
118+
submodules: recursive
119+
120+
# dart-lang/setup-dart requests and configures the OIDC token pub.dev's
121+
# trusted-publisher flow needs — this is the piece that was missing
122+
# before; subosito/flutter-action (below) never provisions it.
123+
- uses: dart-lang/setup-dart@v1
124+
125+
# Flutter SDK is required to resolve `flutter: sdk: flutter` in
126+
# pubspec.yaml. Its bundled `dart` binary shadows the one from
127+
# setup-dart on PATH, but both read the same pub credentials that
128+
# setup-dart just wrote.
129+
- uses: subosito/flutter-action@v2
130+
with:
131+
channel: stable
132+
133+
- name: Install dependencies
134+
run: dart pub get
135+
136+
- name: Publish - dry run
137+
run: dart pub publish --dry-run
138+
106139
- name: Publish to pub.dev
107140
run: dart pub publish --force

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: dart_bclibc
22
description: "Dart FFI bindings for the bclibc ballistics engine. Provides a thin, zero-copy Dart wrapper around libbclibc_ffi with full trajectory integration, zero-finding, and apex/max-range solvers."
3-
version: 0.1.0-beta.1
3+
version: 0.1.0-beta.2
44
repository: https://github.com/ballistics-lab/dart-bclibc
55

66
environment:

0 commit comments

Comments
 (0)