Skip to content

Commit

Permalink
publish
Browse files Browse the repository at this point in the history
  • Loading branch information
rtmigo committed Apr 20, 2021
1 parent b9b19ef commit 88c3d80
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 29 deletions.
55 changes: 28 additions & 27 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,36 @@ jobs:
target_branch: staging
github_token: ${{ github.token }}

to-pubdev:
to-master:
if: github.event.head_commit.message=='publish'
needs: [test, analyze]
runs-on: ubuntu-latest
if: github.event.head_commit.message=='publish'
steps:
- uses: actions/checkout@v2

# UPDATING MASTER BRANCH

- name: Merge to master branch
uses: devmasx/[email protected]
with:
type: now
target_branch: master
github_token: ${{ github.token }}

# ADD GITHUB RELEASE

- name: Get version from pubspec.yaml
run: echo "PKGVER=$(sed -n "s/version://p" pubspec.yaml | xargs)" >> $GITHUB_ENV
- name: Publish GitHub release
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ env.PKGVER }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

to-pubdev:
needs: to-master
runs-on: ubuntu-latest
container:
image: google/dart:latest
steps:
Expand Down Expand Up @@ -93,28 +119,3 @@ jobs:
- name: Publish package
run: pub publish -f

release:
needs: to-pubdev
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

# UPDATING MASTER BRANCH

- name: Merge to master branch
uses: devmasx/[email protected]
with:
type: now
target_branch: master
github_token: ${{ github.token }}

# ADD GITHUB RELEASE

- name: Get version from pubspec.yaml
run: echo "PKGVER=$(sed -n "s/version://p" pubspec.yaml | xargs)" >> $GITHUB_ENV
- name: Publish GitHub release
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ env.PKGVER }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# 0.2.2-alpha
# 0.2.3-alpha

- Added TimeScheduler

Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: schedulers
description: Dart library for running asynchronous functions on time. Useful for load balancing, rate limiting, lazy execution.
repository: https://github.com/rtmigo/schedulers

version: 0.2.2-alpha
version: 0.2.3-alpha

environment:
sdk: ">=2.12.0 <3.0.0"
Expand Down

0 comments on commit 88c3d80

Please sign in to comment.