Skip to content

Commit

Permalink
Updated workflows, codeowner, .gitignore (#65)
Browse files Browse the repository at this point in the history
  • Loading branch information
tbarnes94 committed Feb 4, 2022
1 parent 5876560 commit 2998c83
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 265 deletions.
51 changes: 5 additions & 46 deletions .github/workflows/release-pr.yml
@@ -1,4 +1,4 @@
name: "Create release PR"
name: Create release PR

on:
workflow_dispatch:
Expand All @@ -8,48 +8,7 @@ on:
required: true

jobs:
createPullRequest:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Check if remote branch exists
env:
BRANCH: releases/${{ github.event.inputs.release }}
run: |
echo "##[set-output name=exists;]$(echo $(if [[ -z $(git ls-remote --heads origin ${BRANCH}) ]]; then echo false; else echo true; fi;))"
id: extract-branch-status
# these two only need to occur if the branch exists
- name: Checkout proper branch
if: ${{ steps.extract-branch-status.outputs.exists == 'true' }}
env:
BRANCH: releases/${{ github.event.inputs.release }}
run: git checkout ${BRANCH}
- name: Reset promotion branch
if: ${{ steps.extract-branch-status.outputs.exists == 'true' }}
run: |
git fetch origin main:main
git reset --hard main
- name: Install packages
run: |
rm -rf node_modules/
npm install --no-bin-links
npm run build
- name: Remove node_modules from gitignore
run: |
sed -i '/node_modules/d' ./.gitignore
- name: Create branch
uses: peterjgrainger/action-create-branch@v2.0.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
branch: releases/${{ github.event.inputs.release }}
- name: Create pull request
uses: peter-evans/create-pull-request@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: Add node modules and new code for release
title: ${{ github.event.inputs.release }} new release
base: releases/${{ github.event.inputs.release }}
branch: create-release
release-pr:
uses: OliverMKing/javascript-release-workflow/.github/workflows/release-pr.yml@main
with:
release: ${{ github.event.inputs.release }}
10 changes: 10 additions & 0 deletions .github/workflows/tag-and-draft.yml
@@ -0,0 +1,10 @@
name: Tag and create release draft

on:
push:
branches:
- releases/*

jobs:
tag-and-release:
uses: OliverMKing/javascript-release-workflow/.github/workflows/tag-and-release.yml@main
77 changes: 0 additions & 77 deletions .github/workflows/tag-and-release.yml

This file was deleted.

3 changes: 3 additions & 0 deletions .gitignore
Expand Up @@ -62,3 +62,6 @@ typings/

node_modules
coverage

# Transpiled JS
lib/
142 changes: 0 additions & 142 deletions lib/run.js

This file was deleted.

0 comments on commit 2998c83

Please sign in to comment.