Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update twoslash workflow #50738

Merged
merged 2 commits into from Sep 12, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
27 changes: 10 additions & 17 deletions .github/workflows/twoslash-repros.yaml
Expand Up @@ -8,35 +8,28 @@ on:
- cron: '0 8 * * *'
repository_dispatch:
types: run-twoslash-repros
issues:
types:
- labeled
workflow_dispatch:
inputs:
bisect_issue:
description: Triggers a bisect request on the given issue number instead of updating repros on all issues
issue:
description: Limits run to a single issue.
required: false
type: string
bisect:
description: If set, runs a git bisect on an existing repro. Requires 'issue' to be set. Value can be revision labels (e.g. `good v4.7.3 bad main`) or `true` to infer bisect range.
required: false
type: string

jobs:
run:
if: ${{ github.repository == 'microsoft/TypeScript' && !github.event.label && !github.event.inputs.bisect_issue }}
runs-on: ubuntu-latest
steps:
- uses: actions/setup-node@v3
- uses: microsoft/TypeScript-Twoslash-Repro-Action@master
with:
github-token: ${{ secrets.TS_BOT_GITHUB_TOKEN }}

bisect:
if: ${{ github.event.label.name == 'Bisect Repro' || github.event.inputs.bisect_issue }}
if: ${{ github.repository == 'microsoft/TypeScript' }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
fetch-depth: ${{ github.events.input.bisect && '0' || '1' }}
andrewbranch marked this conversation as resolved.
Show resolved Hide resolved
- uses: actions/setup-node@v3
- uses: microsoft/TypeScript-Twoslash-Repro-Action@master
with:
github-token: ${{ secrets.TS_BOT_GITHUB_TOKEN }}
bisect: ${{ github.event.issue.number || github.event.inputs.bisect_issue }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made that comment, but I can see here that it was previously used; maybe it does actually work.

issue: ${{ github.event.inputs.issue }}
bisect: ${{ github.event.inputs.bisect }}