-
Notifications
You must be signed in to change notification settings - Fork 38
153 lines (144 loc) · 5.17 KB
/
publish.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
name: Publish to pub.dev
on:
workflow_dispatch:
inputs:
mix:
type: boolean
description: publish mix
default: false
mix_lint:
type: boolean
description: publish mix_lint
default: false
mix_annotations:
type: boolean
description: publish mix_annotations
default: false
mix_generator:
type: boolean
description: publish mix_generator
default: false
remix:
type: boolean
description: publish remix
default: false
jobs:
test-mincompat:
runs-on: ubuntu-latest
steps:
- name: Checkout mix repo
uses: actions/checkout@v4
- name: Run Tests
uses: ./.github/actions/test/
with:
token: ${{ secrets.GITHUB_TOKEN }}
flutter-version: 'mincompat'
test-stable:
runs-on: ubuntu-latest
steps:
- name: Checkout mix repo
uses: actions/checkout@v4
- name: Run Tests
uses: ./.github/actions/test/
with:
token: ${{ secrets.GITHUB_TOKEN }}
publish_mix_lint:
needs: [test-mincompat, test-stable]
if: ${{ github.event.inputs.mix_lint }}
environment: Production
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: '>> publish Mix Lint package to pub.dev <<'
id: publish_mix_lint
uses: k-paxian/dart-package-publisher@master
with:
accessToken: ${{ secrets.OAUTH_ACCESS_TOKEN }}
refreshToken: ${{ secrets.OAUTH_REFRESH_TOKEN }}
relativePath: packages/mix
# - name: 'Commit release tag'
# if: steps.publish_mix_lint.outputs.success
# uses: hole19/git-tag-action@master
# env:
# TAG: ${{steps.publish_mix_lint.outputs.package}}-${{steps.publish_mix_lint.outputs.localVersion}}
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
publish_mix_annotations:
needs: [test-mincompat, test-stable]
if: ${{ github.event.inputs.mix_annotations }}
environment: Production
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: '>> publish Mix Annotations package to pub.dev <<'
id: publish_mix_annotations
uses: k-paxian/dart-package-publisher@master
with:
accessToken: ${{ secrets.OAUTH_ACCESS_TOKEN }}
refreshToken: ${{ secrets.OAUTH_REFRESH_TOKEN }}
relativePath: packages/mix_annotations
# - name: 'Commit release tag'
# if: steps.publish_mix_annotations.outputs.success
# uses: hole19/git-tag-action@master
# env:
# TAG: ${{steps.publish_mix_annotations.outputs.package}}-${{steps.publish_mix_annotations.outputs.localVersion}}
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
publish_mix_generator:
needs: [test-mincompat, test-stable]
if: ${{ github.event.inputs.mix_generator }}
environment: Production
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: '>> publish Mix Generator package to pub.dev <<'
id: publish_mix_generator
uses: k-paxian/dart-package-publisher@master
with:
accessToken: ${{ secrets.OAUTH_ACCESS_TOKEN }}
refreshToken: ${{ secrets.OAUTH_REFRESH_TOKEN }}
relativePath: packages/mix_generator
# - name: 'Commit release tag'
# if: steps.publish_mix_generator.outputs.success
# uses: hole19/git-tag-action@master
# env:
# TAG: ${{steps.publish_mix_generator.outputs.package}}-${{steps.publish_mix_generator.outputs.localVersion}}
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
publish_mix:
needs: [test-mincompat, test-stable]
if: ${{ github.event.inputs.mix }}
environment: Production
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@main
- name: '>> publish Mix package to pub.dev <<'
id: publish_mix
uses: k-paxian/dart-package-publisher@master
with:
accessToken: ${{ secrets.OAUTH_ACCESS_TOKEN }}
refreshToken: ${{ secrets.OAUTH_REFRESH_TOKEN }}
relativePath: packages/mix
# - name: 'Commit release tag'
# if: steps.publish_mix.outputs.success
# uses: hole19/git-tag-action@master
# env:
# TAG: ${{steps.publish_mix.outputs.package}}-${{steps.publish_mix.outputs.localVersion}}
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
publish_remix:
needs: [test-mincompat, test-stable]
if: ${{ github.event.inputs.remix }}
environment: Production
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: '>> publish Remix package to pub.dev <<'
id: publish_remix
uses: k-paxian/dart-package-publisher@master
with:
accessToken: ${{ secrets.OAUTH_ACCESS_TOKEN }}
refreshToken: ${{ secrets.OAUTH_REFRESH_TOKEN }}
relativePath: packages/remix
# - name: 'Commit release tag'
# if: steps.publish_remix.outputs.success
# uses: hole19/git-tag-action@master
# env:
# TAG: ${{steps.publish_remix.outputs.package}}-${{steps.publish_remix.outputs.localVersion}}
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}