Skip to content
Latchkey

Looking for Contributors workflow (wix/Detox)

The Looking for Contributors workflow from wix/Detox, explained and optimized by Latchkey.

A

CI health: A - excellent

Point runs-on at Latchkey and get job timeouts, self-healing for flaky steps, and up to 58% lower cost, applied automatically.

Grade your own workflow free or run it on Latchkey →
Source: wix/Detox.github/workflows/looking-for-contributors.ymlLicense MITView source

What it does

This is the Looking for Contributors workflow from the wix/Detox repository, a real project running GitHub Actions. It is shown here with attribution under its MIT license.

Below, Latchkey shows a faster, safer version produced by its optimization engine.

The workflow

workflow (.yml)
name: Looking for Contributors
on:
    issues:
        types:
            - labeled
jobs:
    add-comment:
        if: contains(github.event.label.name, 'looking for contributors')
        runs-on: ubuntu-latest
        permissions:
            issues: write
        steps:
            - name: Add comment
              run: |
                gh issue comment ${{ github.event.issue.number }} --body "Hello! We appreciate you bringing this issue to our attention.
                It looks like this could be a valuable addition or fix to our project.
                We believe that this feature would benefit greatly from contributions from the community,
                even from first-time contributors.

                If you're interested in contributing to this feature,
                please take a look at our [contribution guide](https://wix.github.io/Detox/docs/next/contributing).
                It has all the information you need to know about how to submit a pull request and contribute to our project.

                You're also welcome to join our [Discord server](https://discord.gg/CkD5QKheF5)
                and discuss this feature with the collaborators or other contributors under the channel 'contributions'.

                Please feel free to reach out to us if you have any questions, or need help with anything.
                We appreciate your feedback and look forward to working with you!"
              env:
                GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

The same workflow, on Latchkey

Removes redundant runs and caps runaway jobs. Added and changed lines are highlighted.

name: Looking for Contributors
on:
    issues:
        types:
            - labeled
jobs:
    add-comment:
        timeout-minutes: 30
        if: contains(github.event.label.name, 'looking for contributors')
        runs-on: latchkey-small
        permissions:
            issues: write
        steps:
            - name: Add comment
              run: |
                gh issue comment ${{ github.event.issue.number }} --body "Hello! We appreciate you bringing this issue to our attention.
                It looks like this could be a valuable addition or fix to our project.
                We believe that this feature would benefit greatly from contributions from the community,
                even from first-time contributors.
 
                If you're interested in contributing to this feature,
                please take a look at our [contribution guide](https://wix.github.io/Detox/docs/next/contributing).
                It has all the information you need to know about how to submit a pull request and contribute to our project.
 
                You're also welcome to join our [Discord server](https://discord.gg/CkD5QKheF5)
                and discuss this feature with the collaborators or other contributors under the channel 'contributions'.
 
                Please feel free to reach out to us if you have any questions, or need help with anything.
                We appreciate your feedback and look forward to working with you!"
              env:
                GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
 

What changed

This workflow runs 1 job per trigger. On Latchkey the same minutes cost up to 58% less than GitHub-hosted, with zero queue time.