1.0.13 • Published 7 months ago

renovate-automatic-branch v1.0.13

Weekly downloads
-
License
MIT
Repository
github
Last release
7 months ago

renovate-automatic-branch

Create automatic branch to merge Renovate PRs.

Prerequisites

Configure your renovate with:

{
  "baseBranches": [
    "chore/renovateBaseBranch"
  ],
}

Usage

Github Action

# With Github Action
jobs:
  renovate:
    runs-on: ubuntu-latest
    steps:
      - name: Renovate Automatic Branch
        uses: bodinsamuel/renovate-automatic-branch@v1
        with:
          github-token: YOUR_GITHUB_TOKEN
          repo-owner: YOUR_ORG
          repo-name: YOUR_REPO
# With Docker image
jobs:
  renovate:
    runs-on: ubuntu-latest
    steps:
      - name: Test
        run: |
          docker run --rm -i \
            -e RAB_GH_TOKEN='${{ secrets.PERSONAL_GITHUB_TOKEN }}' \
            -e RAB_OWNER='${{ github.repository_owner }}' \
            -e RAB_REPO='renovate-automatic-branch' \
            ghcr.io/bodinsamuel/renovate-automatic-branch:latest
# To automate
name: Renovate
on:
  schedule:
    - cron: '0 14 * * 5' # e.g: Every friday afternoon

Optional parameters

You can customize the behavior of the action by providing the following parameters:

parameterdescriptiondefault value
branch-to-createThe name of the branch that will be createdchore/renovateBaseBranch
branch-baseThe name of the branch that will be used as basemain
empty-commit-msgThe commit msg that will be created by the scriptchore: automatic empty commit
pull-request-titleThe title of the pull request opened by the actionfix: dependencies
pull-request-bodyThe body (description) of the pull request opened by the actionWeekly dependencies update.

Docker image

docker run --rm -i \
  -e RAB_GH_TOKEN='${{ secrets.PERSONAL_GITHUB_TOKEN }}' \
  -e RAB_OWNER='${{ github.repository_owner }}' \
  -e RAB_REPO='renovate-automatic-branch' \
  ghcr.io/bodinsamuel/renovate-automatic-branch:latest

Available environment variables: constants.ts

Programmatic

npm install -ED renovate-automatic-branch
import { run } from 'renovate-automatic-branch/run';

run({
  ghToken: process.env.TOKEN,
  // [...]
})
1.0.13

7 months ago

1.0.11

8 months ago

1.0.10

9 months ago

1.0.9

11 months ago

1.0.12

8 months ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.0

2 years ago