https://github.com/fabasoad/setup-enry-action
This GitHub action installs enry CLI tool.
https://github.com/fabasoad/setup-enry-action
enry github-action github-actions language-detection language-detector linguist
Last synced: 2 months ago
JSON representation
This GitHub action installs enry CLI tool.
- Host: GitHub
- URL: https://github.com/fabasoad/setup-enry-action
- Owner: fabasoad
- License: mit
- Created: 2022-05-10T06:14:30.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2025-03-11T22:03:21.000Z (2 months ago)
- Last Synced: 2025-03-11T23:19:14.724Z (2 months ago)
- Topics: enry, github-action, github-actions, language-detection, language-detector, linguist
- Language: Shell
- Homepage:
- Size: 151 KB
- Stars: 5
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
# Setup Enry GitHub Action
[](https://stand-with-ukraine.pp.ua)



This action sets up an [enry](https://github.com/go-enry/enry) tool.
## Supported OS
| OS | |
|---------|--------------------|
| Windows | :white_check_mark: |
| Linux | :white_check_mark: |
| macOS | :white_check_mark: |## Prerequisites
The following tools have to be installed for successful work of this GitHub Action:
[curl](https://curl.se).## Inputs
```yaml
- uses: fabasoad/setup-enry-action@v0
with:
# (Optional) enry version. Defaults to the latest version.
version: "1.3.0"
# (Optional) If "false" skips installation if enry is already installed.
# If "true" installs enry in any case. Defaults to "false".
force: "false"
# (Optional) GitHub token that is used to send requests to GitHub API such
# as getting latest release. Defaults to the token provided by GitHub Actions
# environment.
github-token: "${{ github.token }}"
```## Outputs
| Name | Description | Example |
|-----------|-----------------------------------|---------|
| installed | Whether enry was installed or not | `true` |## Example usage
```yaml
name: Setup Enryon: push
jobs:
example:
name: Example
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: fabasoad/setup-enry-action@v0
- name: Run CLI
run: |
echo "Text format:"
enry
echo "JSON format:"
enry --json | jq
```### Result
```shell
Text format:
79.74% HTML
9.90% TypeScript
6.44% JavaScript
3.93% CSS
JSON format:
[
{
"color": "#e34c26",
"language": "HTML",
"percentage": "79.74%",
"type": "unknown"
},
{
"color": "#3178c6",
"language": "TypeScript",
"percentage": "9.90%",
"type": "unknown"
},
{
"color": "#f1e05a",
"language": "JavaScript",
"percentage": "6.44%",
"type": "unknown"
},
{
"color": "#563d7c",
"language": "CSS",
"percentage": "3.93%",
"type": "unknown"
}
]
```