From de9da4b18f3f4581d780d42ff681e0f72945e8a8 Mon Sep 17 00:00:00 2001 From: Nikita Sirovskiy Date: Wed, 22 Nov 2023 09:22:34 +0300 Subject: [PATCH 1/2] Create push_to_pubdev_on_tag.yml --- .github/workflows/push_to_pubdev_on_tag.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 .github/workflows/push_to_pubdev_on_tag.yml diff --git a/.github/workflows/push_to_pubdev_on_tag.yml b/.github/workflows/push_to_pubdev_on_tag.yml new file mode 100644 index 0000000..bfa6c20 --- /dev/null +++ b/.github/workflows/push_to_pubdev_on_tag.yml @@ -0,0 +1,14 @@ +name: Publish to pub.dev + +on: + push: + tags: + - '[0-9]+.[0-9]+.[0-9]+*' # tag-pattern on pub.dev: '' + +jobs: + publish: + permissions: + id-token: write # Required for authentication using OIDC + uses: dart-lang/setup-dart/.github/workflows/publish.yml@v1 + with: + environment: pub.dev From cb82b478ecc1705d1c6d3d346dd9d959ea39cd3c Mon Sep 17 00:00:00 2001 From: Nikita Sirovskiy Date: Wed, 22 Nov 2023 09:28:21 +0300 Subject: [PATCH 2/2] docs: Add instructions --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index 415b691..29c3895 100644 --- a/README.md +++ b/README.md @@ -30,6 +30,10 @@ Modify your [`analysis_options.yaml`](https://dart.dev/tools/analysis#the-analys include: package:monstarlab_lints/analysis_options.yaml ``` +## Maintaining + +To publish a new version to pub.dev, create a new tag with required version used as a title. For example, creating a tag `1.0.3` will result in pushing the package to pub.dev with version `1.0.3`. + [pub-version-img]: https://img.shields.io/badge/pub-v1.0.2-0175c2?logo=flutter