Loading repository data…
Loading repository data…
ergebnis / repository
❤️ Provides default community health files and composite actions for the @ergebnis organization.
A transparent discovery signal based on current public GitHub metadata.
This score does not audit code, security, maintainers, documentation quality, or suitability. Verify the repository and its current documentation before adoption.
This project provides community health files and composite actions for the @ergebnis organization.
This project provides the following composite actions:
ergebnis/.github/actions/composer/determine-cache-directoryergebnis/.github/actions/composer/determine-root-versionergebnis/.github/actions/composer/installergebnis/.github/actions/github/pull-request/add-assigneeergebnis/.github/actions/github/pull-request/add-label-based-on-branch-nameergebnis/.github/actions/github/pull-request/approveergebnis/.github/actions/github/pull-request/mergeergebnis/.github/actions/github/pull-request/request-reviewergebnis/.github/actions/github/release/createergebnis/.github/actions/github/release/publishergebnis/.github/actions/oh-dear/check/request-runergebnis/.github/actions/oh-dear/maintenance-period/startergebnis/.github/actions/oh-dear/maintenance-period/stopergebnis/.github/actions/phive/installergebnis/.github/actions/composer/determine-cache-directoryThis action determines the cache directory for composer and exports it as COMPOSER_CACHE_DIR environment variable.
This is useful for caching dependencies installed with composer using actions/cache.
name: "Integrate"
on:
pull_request: null
push:
branches:
- "main"
jobs:
tests:
name: "Tests"
runs-on: "ubuntu-latest"
steps:
- name: "Checkout"
uses: "actions/checkout@v5.0.0"
- name: "Set up PHP"
uses: "shivammathur/setup-php@2.35.4"
with:
coverage: "none"
php-version: "8.1"
- name: "Determine composer cache directory"
uses: "ergebnis/.github/actions/composer/determine-cache-directory@1.9.3"
- name: "Cache dependencies installed with composer"
uses: "actions/cache@v4.2.4"
with:
path: "${{ env.COMPOSER_CACHE_DIR }}"
key: "composer-${{ hashFiles('composer.lock') }}"
restore-keys: "composer-"
For details, see actions/composer/determine-cache-directory/action.yaml.
working-directory, optional: The working directory to use. Defaults to ".".none
COMPOSER_CACHE_DIR environment variable contains the path to the composer cache directory.ergebnis/.github/actions/composer/determine-root-versionThis action determines the composer root version and exports it as COMPOSER_ROOT_VERSION environment variable.
This is useful for a package that depends on itself, for example, phpunit/phpunit
name: "Integrate"
on:
pull_request: null
push:
branches:
- "main"
jobs:
tests:
name: "Tests"
runs-on: "ubuntu-latest"
steps:
- name: "Checkout"
uses: "actions/checkout@v5.0.0"
- name: "Set up PHP"
uses: "shivammathur/setup-php@2.35.4"
with:
coverage: "none"
php-version: "8.1"
- name: "Determine composer root version"
uses: "ergebnis/.github/actions/composer/determine-root-version@1.9.3"
For details, see actions/composer/determine-root-version/action.yaml.
branch, optional: The name of the branch, defaults to "main".working-directory, optional: The working directory to use, defaults to ".".none
The COMPOSER_ROOT_VERSION environment variable contains the root version if it has been defined as branch-alias in composer.json.
{
"extra": {
"branch-alias": {
"dev-main": "10.0-dev"
}
}
}
ergebnis/.github/actions/composer/installThis action installs or updates dependencies with composer.
name: "Integrate"
on:
pull_request: null
push:
branches:
- "main"
jobs:
tests:
name: "Tests"
runs-on: "ubuntu-latest"
strategy:
matrix:
dependencies:
- "lowest"
- "locked"
- "highest"
steps:
- name: "Checkout"
uses: "actions/checkout@v5.0.0"
- name: "Set up PHP"
uses: "shivammathur/setup-php@2.35.4"
with:
coverage: "none"
php-version: "8.1"
- name: "Determine composer cache directory"
uses: "ergebnis/.github/actions/composer/determine-cache-directory@1.9.3"
- name: "Cache dependencies installed with composer"
uses: "actions/cache@v4.2.4"
with:
path: "${{ env.COMPOSER_CACHE_DIR }}"
key: "composer-${{ matrix.dependencies }}-${{ hashFiles('composer.lock') }}"
restore-keys: "composer-${{ matrix.dependencies }}-"
- name: "Install ${{ matrix.dependencies }} dependencies with composer"
uses: "ergebnis/.github/actions/composer/install@1.9.3"
with:
dependencies: "${{ matrix.dependencies }}"
For details, see actions/composer/install/action.yaml.
dependencies, optional: Which dependencies to install, one of "lowest", "locked", "highest"working-directory, optional: The working directory to use, defaults to ".".none
When dependencies is set to "lowest", dependencies are installed in the directory specified by working-directory with
composer update --ansi --no-interaction --no-progress --prefer-lowest
When dependencies is set to "locked", dependencies are installed in the directory specified by working-directory with
composer install --ansi --no-interaction --no-progress
When dependencies is set to "highest", dependencies are installed in the directory specified by working-directory with
composer update --ansi --no-interaction --no-progress
ergebnis/.github/actions/github/pull-request/add-assigneeThis action adds an assignee to a pull request.
This is useful when you want to automatically merge a pull request, but prefer to assign a bot user beforehand.
name: "Merge"
on:
workflow_run:
types:
- "completed"
workflows:
- "Integrate"
jobs:
merge:
name: "Merge"
runs-on: "ubuntu-latest"
if: >
github.event.workflow_run.event == 'pull_request' &&
github.event.workflow_run.conclusion == 'success' &&
github.actor == 'dependabot[bot]' && (
startsWith(github.event.workflow_run.head_commit.message, 'composer(deps-dev)') ||
startsWith(github.event.workflow_run.head_commit.message, 'github-actions(deps)')
)
steps:
- name: "Assign @ergebnis-bot"
uses: "ergebnis/.github/actions/github/pull-request/add-assignee@1.9.3"
with:
assignee: "ergebnis-bot"
github-token: "${{ secrets.ERGEBNIS_BOT_TOKEN }}"
For details, see actions/github/pull-request/add-assignee/action.yaml.
assignee, required: The username of a user to add as an assignee to a pull request.github-token, required: The GitHub token of a user with permission to add assignees to a pull requestnone
assignee input is assigned to the pull request.PULL_REQUEST_NUMBER environment variable contains the number of the pull request.ergebnis/.github/actions/github/pull-request/add-label-based-on-branch-nameThis action adds a label to a pull request based on the name of the branch.
# https://docs.github.com/en/actions
name: "Triage"
on: # yamllint disable-line rule:truthy
pull_request_target:
types:
- "opened"
jobs:
label:
name: "Label"
runs-on: "ubuntu-latest"
steps:
- name: "Add labels based on branch name"
uses: "ergebnis/.github/actions/github/pull-request/add-label-based-on-branch-name@1.9.3"
with:
github-token: "${{ secrets.ERGEBNIS_BOT_TOKEN }}"
For details, see actions/github/pull-request/add-label-based-on-branch-name/action.yaml.
github-token, required: The GitHub token of a user with permission to add labels to to a pull request.none
feature/, the label enhancement is added to the pull request by the user who owns the GitHub token specified with the github-token input.fix/, the label bug is added to the pull request by the user who owns the GitHub token specified with the github-token input.PULL_REQUEST_BRANCH_NAME environment variable contains the name of the head branch of the pull request.PULL_REQUEST_NUMBER environment variable contains the number of the pull request.ergebnis/.github/actions/github/pull-request/approveThis action approves a pull request.
This is useful when you want to automatically merge a pull request, but prefer to let a bot user approve the pull request beforehand.
name: "Merge"
on:
workflow_run:
types:
- "completed"
workflows:
- "Integrate"
jobs:
merge:
name: "Merge"
runs-on: "ubuntu-latest"
if: >
github.event.workflow_run.event == 'pull_request' &&
github.event.workflow_run.conclusion == 'success' &&
github.actor == 'dependabot[bot]' && (
startsWith(github.event.workflow_run.head_commit.message, 'composer(deps-dev)') ||
startsWith(github.event.workflow_run.head_commit.message, 'github-actions(deps)')
)
steps:
- name: "Approve pull request"
uses: "ergebnis/.github/actions/github/pull-request/approve@1.9.3"
with:
github-token: "${{ secrets.ERGEBNIS_BOT_TOKEN }}"
For details, see actions/github/pull-request/merge/action.yaml.
github-token, required: The GitHub token of a user with permission to approve a pull requestnone