Skip to content

Create tech stack docs (techstack.yml and techstack.md) #13

Create tech stack docs (techstack.yml and techstack.md)

Create tech stack docs (techstack.yml and techstack.md) #13

Workflow file for this run

# ~~ Generated by projen. To modify, edit .projenrc.ts and run "npx projen".
name: build
on:
pull_request: { }
workflow_dispatch: { }
jobs:
analyze:
runs-on: ubuntu-latest
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
- uses: sonarsource/sonarqube-scan-action@master
with:
args: |
-Dsonar.projectName=${{ github.event.repository.name }}
-Dsonar.projectKey=${{ github.event.repository.name }}
-Dsonar.links.scm=https://github.com/${{ github.repository }}
-Dsonar.links.ci=https://github.com/${{ github.repository }}/actions
- uses: sonarsource/sonarqube-quality-gate-action@master
timeout-minutes: 5
with:
args: |
-Dsonar.projectName=${{ github.event.repository.name }}
-Dsonar.projectKey=${{ github.event.repository.name }}
-Dsonar.links.scm=https://github.com/${{ github.repository }}
-Dsonar.links.ci=https://github.com/${{ github.repository }}/actions
build:
runs-on: ubuntu-latest
permissions:
contents: write
outputs:
self_mutation_happened: ${{ steps.self_mutation.outputs.self_mutation_happened }}
env:
CI: "true"
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.ref }}
repository: ${{ github.event.pull_request.head.repo.full_name }}
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 18.0.0
- name: Install dependencies
run: yarn
- name: build
run: npx projen build
- name: Find mutations
id: self_mutation
run: |-
git add .
git diff --staged --patch --exit-code > .repo.patch || echo "self_mutation_happened=true" >> $GITHUB_OUTPUT
- name: Upload patch
if: 'steps.self_mutation.outputs.self_mutation_happened'
uses: actions/upload-artifact@v3
with:
name: .repo.patch
path: .repo.patch
- name: Fail build on mutation
if: 'steps.self_mutation.outputs.self_mutation_happened'
run: |-
echo "::error::Files were changed during build (see build log). If this was triggered from a fork, you will need to update your branch."
cat .repo.patch
exit 1
- name: Create js artifact
if: '! steps.self_mutation.outputs.self_mutation_happened'
run: npx projen package