Merge pull request #1254 from microsoftgraph/fix/gh-actions #75
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright (c) Microsoft Corporation. All rights reserved. | |
# Licensed under the MIT License. | |
# Adds a tag to main after a PR is merged succesfully. | |
name: "tag release" | |
on: | |
push: | |
branches: | |
- feat/kiota-preview | |
defaults: | |
run: | |
shell: bash | |
jobs: | |
create-tag: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Get SDK version and set environment variable | |
run: | | |
SDK_VERSION=$(grep 'SDK_VERSION' src/GraphConstants.php | grep -oE '[0-9]+\.[0-9]+\.([0-9]+|[0-9]+-[a-z]+)') | |
echo "SDK_VERSION=$SDK_VERSION" >> $GITHUB_ENV | |
- name: Create and publish tag | |
run: | | |
echo "SDK_VERSION is:"$SDK_VERSION | |
git tag $SDK_VERSION && git push origin $SDK_VERSION |