Skip to content

new-pre-release

new-pre-release #70

Workflow file for this run

name: new-pre-release
on:
workflow_dispatch:
inputs:
new-version:
description: 'New version to be set.'
type: string
required: true
release-date:
description: 'Release date.'
type: string
required: true
jobs:
run-lint-on-dev:
runs-on: ubuntu-latest
if: ${{ github.event.inputs.new-version }}
steps:
- uses: actions/checkout@v3
with:
ref: dev
- name: Install project dependencies
run: npm install
- name: Run build
run: npm run build
create-rc:
needs: run-lint-on-dev
runs-on: ubuntu-latest
if: ${{ github.event.inputs.new-version }}
steps:
- uses: actions/checkout@v3
with:
ref: dev
- name: Create branch rc${{ github.event.inputs.new-version }}
run: |
git checkout -b rc${{ github.event.inputs.new-version }}
git push -u origin rc${{ github.event.inputs.new-version }}
set-tag:
needs: create-rc
runs-on: ubuntu-latest
if: ${{ github.event.inputs.new-version }}
steps:
# TODO
- name: Configure Git with the GitHub Token
run: |
git config --global user.email "sa_git_uicomponents@outsystems.com"
git config --global user.name "UiComponentsBot"
git config --global credential.helper store
- uses: actions/checkout@v3
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
ref: rc${{ github.event.inputs.new-version }}
fetch-depth: 0
# token: ${{ secrets.PAT }}
- name: Set tag
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
git tag v${{ github.event.inputs.new-version }} HEAD -m "New v${{ github.event.inputs.new-version }}"
git push origin --tags
set-pre-release:
needs: set-tag
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Create Release
id: create_release
uses: softprops/action-gh-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: v${{ github.event.inputs.new-version }}
name: Release of version ${{ github.event.inputs.new-version }} (${{ github.event.inputs.release-date }})
body: |
### What's New
- First
- ...
### Fixed Issues and Improvements
- First
- ...
draft: false
prerelease: true