Skip to content
box

GitHub Action

Check WIP

v1.0.0 Latest version

Check WIP

box

Check WIP

Checks for WIP patterns in Titles

Installation

Copy and paste the following snippet into your .yml file.

              

- name: Check WIP

uses: embano1/wip@v1.0.0

Learn more about this action in embano1/wip

Choose a version

About

Github Action to check the specified string, e.g. Github PR title, for work-in-progress ("WIP") patterns using regular expressions in BASH.

Usage

Simple with Defaults

name: Check "WIP" in PR Title

on:
  pull_request:
    types: [opened, synchronize, reopened, edited]

jobs:
  check:
    runs-on: ubuntu-latest
    steps:
      - name: Check WIP in PR Title
        uses: embano1/wip@v1

Custom Options

name: Check "WIP" in PR Title

on:
  pull_request:
    types: [opened, synchronize, reopened, edited]

jobs:
  check:
    runs-on: ubuntu-latest
    steps:
      - name: Check WIP in PR Title
        uses: embano1/wip@v1
        with:
          # this is also the default value
          title: "${{ github.event.pull_request.title }}"

          # only matches PRs where title is "WIP" only
          regex: "^WIP$" 

Configuration Options

Input Type Required Default Description
title string yes ${{ github.event.pull_request.title }} The title to perform regular expression pattern matching against. Typically a field from the Github context is used.
regex string yes ^[[:space:]]*(WIP)+(:)* The regular expression to perform. The default value matches the word WIP (optionally followed by :) and ignores any whitespace character(s) at the beginning of the text

⚠️ Currently regular expression pattern matching is case-insensitive, i.e. wip would also match.