diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 78ab69af544b..05c2e2b441fb 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -1,14 +1,14 @@ name: Lint JavaScript on: - workflow_dispatch: + workflow_call: pull_request: types: [opened, synchronize] branches-ignore: [staging, production] jobs: lint: - if: ${{ github.actor != 'OSBotify' || github.event_name == 'workflow_dispatch' }} + if: ${{ github.actor != 'OSBotify' || github.event_name == 'workflow_call' }} runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 diff --git a/.github/workflows/preDeploy.yml b/.github/workflows/preDeploy.yml index 266f998d4f03..bdfe605de7d8 100644 --- a/.github/workflows/preDeploy.yml +++ b/.github/workflows/preDeploy.yml @@ -5,17 +5,14 @@ on: branches: [main] jobs: + lint: + uses: ./.github/workflows/lint.yml + confirmPassingBuild: runs-on: ubuntu-latest + needs: lint steps: - - name: Run lint - id: lint - uses: Expensify/App/.github/actions/triggerWorkflowAndWait@main - with: - WORKFLOW: lint.yml - GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }} - - name: Run tests id: tests uses: Expensify/App/.github/actions/triggerWorkflowAndWait@main