Skip to content

[dep|ts] Update dependencies #75

[dep|ts] Update dependencies

[dep|ts] Update dependencies #75

name: Deploy GitHub Actions
on:
push:
branches:
- main
env:
gh_actions_git_path: './gh-actions/'
main_git_path: './main/'
jobs:
deploy-typescript:
runs-on: ubuntu-latest
steps:
- name: Checkout main
uses: actions/checkout@v3
with:
path: ${{ env.main_git_path }}
- name: Checkout gh-actions
uses: actions/checkout@v3
with:
ref: 'gh-actions'
path: ${{ env.gh_actions_git_path }}
- name: npm install
working-directory: ${{ env.main_git_path }}/typescript
run: |
npm install
- name: Build gitcc
working-directory: ${{ env.main_git_path }}/typescript
run: |
npm run build
npm run package
- name: Remove old files
working-directory: ${{ env.gh_actions_git_path }}
run: |
rm -rf ./*
- name: Copy new files
run: |
mkdir -p ${{ env.gh_actions_git_path }}/typescript/dist/
cp -f ${{ env.main_git_path }}/typescript/README.rst ${{ env.gh_actions_git_path }}
cp -rf ${{ env.main_git_path }}/typescript/dist* ${{ env.gh_actions_git_path }}/typescript/
cp -f ${{ env.main_git_path }}/action.yml ${{ env.gh_actions_git_path }}
- name: Push new files
working-directory: ${{ env.gh_actions_git_path }}
run: |
git config user.name github-actions
git config user.email [email protected]
git add .
git diff-index --quiet HEAD || git commit -am "[actions] Build of ${{ github.sha }}"
git push
commit-check:
name: Commit Check
runs-on: ubuntu-latest
needs: deploy-typescript
steps:
- name: Commit Check
uses: IceflowRE/gitcc@gh-actions
with:
validator: "SimpleTag"