fix: Configure the post install redirect for BitBucket #113
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
name: lint-test-stage | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
# Only run on PRs against main | |
branches: | |
- main | |
jobs: | |
# Run linter and tests against JS, TS, and YAML files | |
linttest: | |
runs-on: ubuntu-latest | |
permissions: | |
checks: write # Needed for GHA to write the checks for the job | |
contents: read | |
steps: | |
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4.0.0 | |
- uses: denoland/setup-deno@61fe2df320078202e33d7d5ad347e7dcfa0e8f31 # v1.1.2 | |
with: | |
deno-version: v1.37.1 | |
- name: Cache Deno dependencies | |
uses: actions/cache@704facf57e6136b1bc63b828d79edcd491f0ee84 # v3.3.2 | |
with: | |
key: denoDeps-${{ hashFiles('deno.lock') }} | |
path: ~/.cache/deno | |
- name: fmt | |
run: deno fmt --check | |
- name: lint | |
run: deno lint | |
- name: test | |
run: | | |
deno test \ | |
--parallel --unstable --allow-net --allow-env --allow-read \ | |
--ignore=deployments/release \ | |
--junit-path=./report.xml | |
env: | |
FENSAK_GITHUB_WEBHOOK_SECRET: ${{ secrets.FENSAK_GITHUB_WEBHOOK_SECRET }} | |
FENSAK_GITHUB_APP_ID: ${{ secrets.FENSAK_GITHUB_APP_ID }} | |
FENSAK_GITHUB_APP_PRIVATE_KEY: ${{ secrets.FENSAK_GITHUB_APP_PRIVATE_KEY }} | |
TEST_FENSAK_GITHUB_INSTALLATION_ID: ${{ secrets.TEST_FENSAK_GITHUB_INSTALLATION_ID }} | |
FENSAK_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: report | |
uses: mikepenz/action-junit-report@75b84e78b3f0aaea7ed7cf8d1d100d7f97f963ec # v4.0.0 | |
if: always() | |
with: | |
report_paths: "report.xml" | |
check_name: "deno test report" | |
# Deploy to staging environment on merges to main. | |
deploystage: | |
runs-on: ubuntu-latest | |
needs: linttest | |
if: github.ref == 'refs/heads/main' | |
permissions: | |
id-token: write # Needed to auth to Deno Deploy | |
checks: write # Needed for GHA to write the checks for the job | |
contents: read | |
steps: | |
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4.0.0 | |
with: | |
fetch-depth: 0 | |
- uses: denoland/deployctl@b841621a76eae438b09e1bce5e74549678c24e7f # v1.8.2 | |
with: | |
project: fensak-stage | |
entrypoint: main.ts |