Home

Awesome

Shortify git revision

[!NOTE] A GitHub Action that generates shortened Git revision identifiers from full-length commit hashes and exposes them as environment variables.

Features

Behavior

Usage

Inputs

name

When providing a revision through the revision input, the action will use this environment variable name to store the shortened hash.

If no environment variable is specified, the action automatically creates one using the name input (converted to uppercase) to store the provided revision value.

revision

The revision to shortify into an environment variable named <NAME>_SHORT.

This input is Optional.

continue-on-error

If the input is set to true, this action will not fail on a bad revision

The default value is false.

short-on-error

If the input is set to true, this action will short a bad revision

The default value is false.

[!WARNING]

prefix

The value will be prepend to each generated variable.

This input is Optional.

length

the short sha produce will have the length defined by the input.

This input is Optional.

Outputs

OutputDescription
revisionThe revision to be shortify
shortRevision Short