Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/actionlint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
paths:
.github/workflows/**/*.{yml,yaml}:
ignore:
- '"inputs" section is alias node but mapping node is expected'
- '"paths" section must be sequence node but got alias node with "" tag'
- '"paths-ignore" section must be sequence node but got alias node with "" tag'
2 changes: 1 addition & 1 deletion .github/disabled/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:

steps:
- name: "Checkout"
uses: actions/checkout@v5
uses: actions/checkout@v6

- name: "Docker Login"
uses: docker/login-action@v3
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
echo "env.dev: ${{ env.dev }}"

- name: "Checkout"
uses: actions/checkout@v5
uses: actions/checkout@v6

- name: "Docker Login"
uses: docker/login-action@v3
Expand All @@ -63,7 +63,7 @@ jobs:
- name: "Update Version Tags"
if: ${{ !env.dev }}
id: version
uses: cssnr/update-version-tags-action@v1
uses: cssnr/update-version-tags-action@v2
with:
prefix: ""
tags: |
Expand All @@ -79,7 +79,7 @@ jobs:

- name: "Generate Docker Tags"
id: tags
uses: cssnr/docker-tags-action@v1
uses: cssnr/docker-tags-action@v2
with:
images: "ghcr.io/${{ github.repository }}"
tags: |
Expand Down Expand Up @@ -111,6 +111,6 @@ jobs:

- name: "Send Failure Notification"
if: ${{ failure() }}
uses: sarisia/actions-status-discord@v1
uses: sarisia/actions-status-discord@eb045afee445dc055c18d3d90bd0f244fd062708 # v1.16.0
with:
webhook: ${{ secrets.DISCORD_WEBHOOK }}
2 changes: 1 addition & 1 deletion .github/workflows/draft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:

steps:
- name: "Checkout"
uses: actions/checkout@v5
uses: actions/checkout@v6

- name: "Draft Release Action"
id: draft
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/labeler.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

steps:
- name: "Checkout Configs"
uses: actions/checkout@v5
uses: actions/checkout@v6
with:
repository: cssnr/configs
ref: master
Expand Down
92 changes: 50 additions & 42 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,54 @@ jobs:

steps:
- name: "Checkout"
uses: actions/checkout@v5
uses: actions/checkout@v6

- name: "yamllint"
if: ${{ !cancelled() }}
env:
CONFIG: .github/yamllint.yaml
run: |
echo "::group::List Files"
yamllint -c "${{ env.CONFIG }}" --list-files .
echo "::endgroup::"
yamllint -c "${{ env.CONFIG }}" .

- name: "actionlint"
if: ${{ !cancelled() }}
uses: cssnr/actionlint-action@v1
with:
shellcheck_opts: -e SC2129

- name: "hadolint"
if: ${{ !cancelled() }}
uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
with:
dockerfile: Dockerfile
ignore: "DL3018"

- name: "ShellCheck"
if: ${{ !cancelled() }}
uses: ludeeus/action-shellcheck@master
env:
SHELLCHECK_OPTS: -x

#- name: "ESLint Annotate"
# if: ${{ !cancelled() && steps.eslint.outcome != 'success' }}
# continue-on-error: true
# uses: ataylorme/eslint-annotate-action@v3

npm-lint:
name: "NPM Lint"
runs-on: ubuntu-latest
timeout-minutes: 5

permissions:
pull-requests: write
checks: write

steps:
- name: "Checkout"
uses: actions/checkout@v6

- name: "Setup Node"
uses: actions/setup-node@v6
Expand All @@ -34,52 +81,13 @@ jobs:
run: |
npm ci

- name: "ESLint"
- name: "eslint"
id: eslint
if: ${{ !cancelled() }}
run: |
#npm run lint:report
npm run lint

- name: "Prettier"
- name: "prettier"
if: ${{ !cancelled() }}
run: |
npm run prettier:check

- name: "Yamllint"
if: ${{ !cancelled() }}
env:
CONFIG: "{extends: relaxed, ignore: [node_modules/], rules: {line-length: {max: 119}}}"
run: |
echo "::group::List Files"
yamllint -d '${{ env.CONFIG }}' --list-files .
echo "::endgroup::"
yamllint -d '${{ env.CONFIG }}' .

- name: "Actionlint"
if: ${{ !cancelled() }}
run: |
echo "::group::Download"
loc=$(curl -sI https://github.com/rhysd/actionlint/releases/latest | grep -i '^location:')
echo "loc: ${loc}"
tag=$(echo "${loc}" | sed -E 's|.*/tag/v?(.*)|\1|' | tr -d '\t\r\n')
echo "tag: ${tag}"
url="https://github.com/rhysd/actionlint/releases/latest/download/actionlint_${tag}_linux_amd64.tar.gz"
echo "url: ${url}"
curl -sL "${url}" | tar xz -C "${RUNNER_TEMP}" actionlint
file "${RUNNER_TEMP}/actionlint"
"${RUNNER_TEMP}/actionlint" --version
echo "::endgroup::"
"${RUNNER_TEMP}/actionlint" -color -verbose -shellcheck= -pyflakes=

- name: "Hadolint"
if: ${{ !cancelled() }}
uses: hadolint/hadolint-action@v3.3.0
with:
dockerfile: Dockerfile
ignore: "DL3018"

#- name: "ESLint Annotate"
# if: ${{ !cancelled() && steps.eslint.outcome != 'success' }}
# continue-on-error: true
# uses: ataylorme/eslint-annotate-action@v3
2 changes: 1 addition & 1 deletion .github/workflows/pull.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:

steps:
- name: "Checkout Pull"
uses: actions/checkout@v5
uses: actions/checkout@v6
with:
ref: ${{ github.event.pull_request.head.sha }}

Expand Down
7 changes: 7 additions & 0 deletions .github/yamllint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
extends: relaxed

ignore-from-file: .gitignore

rules:
line-length:
max: 119
9 changes: 8 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
# Generic
.idea/
*.iml
.vscode/
.*cache*
node_modules/
eslint_report.json
build/
dist/
out/
*.dll
*.exe
.env
.secrets
.vars
settings.env
eslint_report.json
18 changes: 2 additions & 16 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -1,17 +1,3 @@
# IDE
.idea/
.vscode/

# Tools
.ruff_cache/
.mypy_cache/
.pytest_cache/
eslint_report.json

# Build
dist/
node_modules/
.github/disabled/

# Files
.github/disabled
.github/pull_request_template.md
package-lock.json
4 changes: 2 additions & 2 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
{
"trailingComma": "es5",
"semi": false,
"singleQuote": true,
"printWidth": 90,
"overrides": [
{
"files": ["**/*.html", "**/*.yaml", "**/*.yml"],
"options": {
"singleQuote": false
"singleQuote": false,
"printWidth": 120
}
},
{
Expand Down
20 changes: 11 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,18 @@
[![GitHub Tag Minor](https://img.shields.io/github/v/tag/smashedr/node-badges?sort=semver&filter=!*.*.*&logo=git&logoColor=white&labelColor=585858&label=%20)](https://github.com/smashedr/node-badges/releases)
[![GitHub Release Version](https://img.shields.io/github/v/release/smashedr/node-badges?logo=github)](https://github.com/smashedr/node-badges/releases/latest)
[![Deployments Swarm](https://img.shields.io/github/deployments/smashedr/node-badges/swarm?logo=portainer&logoColor=white&label=swarm)](https://github.com/smashedr/node-badges/deployments/swarm)
[![Workflow Build](https://img.shields.io/github/actions/workflow/status/smashedr/node-badges/build.yaml?logo=cachet&label=build)](https://github.com/smashedr/node-badges/actions/workflows/build.yaml)
[![Workflow Lint](https://img.shields.io/github/actions/workflow/status/smashedr/node-badges/lint.yaml?logo=cachet&label=lint)](https://github.com/smashedr/node-badges/actions/workflows/lint.yaml)
[![Workflow Build](https://img.shields.io/github/actions/workflow/status/smashedr/node-badges/build.yaml?logo=norton&logoColor=white&label=build)](https://github.com/smashedr/node-badges/actions/workflows/build.yaml)
[![Workflow Lint](https://img.shields.io/github/actions/workflow/status/smashedr/node-badges/lint.yaml?logo=norton&logoColor=white&label=lint)](https://github.com/smashedr/node-badges/actions/workflows/lint.yaml)
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=smashedr_node-badges&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=smashedr_node-badges)
[![GitHub Last Commit](https://img.shields.io/github/last-commit/smashedr/node-badges?logo=github&label=updated)](https://github.com/smashedr/node-badges/pulse)
[![GitHub Repo Size](https://img.shields.io/github/repo-size/smashedr/node-badges?logo=bookstack&logoColor=white&label=repo%20size)](https://github.com/smashedr/node-badges?tab=readme-ov-file#readme)
[![GitHub Top Language](https://img.shields.io/github/languages/top/smashedr/node-badges?logo=htmx)](https://github.com/smashedr/node-badges/tree/master/src)
[![GitHub Discussions](https://img.shields.io/github/discussions/smashedr/node-badges?logo=github)](https://github.com/smashedr/node-badges/discussions)
[![GitHub Forks](https://img.shields.io/github/forks/smashedr/node-badges?style=flat&logo=github)](https://github.com/smashedr/node-badges/forks)
[![GitHub Repo Stars](https://img.shields.io/github/stars/smashedr/node-badges?style=flat&logo=github)](https://github.com/smashedr/node-badges/stargazers)
[![GitHub Org Stars](https://img.shields.io/github/stars/cssnr?style=flat&logo=github&label=org%20stars)](https://cssnr.github.io/)
[![GitHub Last Commit](https://img.shields.io/github/last-commit/smashedr/node-badges?logo=listenhub&label=updated)](https://github.com/smashedr/node-badges/pulse)
[![GitHub Repo Size](https://img.shields.io/github/repo-size/smashedr/node-badges?logo=googlecloudstorage&logoColor=white&label=repo%20size)](https://github.com/smashedr/node-badges?tab=readme-ov-file#readme)
[![GitHub Top Language](https://img.shields.io/github/languages/top/smashedr/node-badges?logo=devbox)](https://github.com/smashedr/node-badges?tab=readme-ov-file#readme)
[![GitHub Contributors](https://img.shields.io/github/contributors-anon/smashedr/node-badges?logo=southwestairlines)](https://github.com/smashedr/node-badges/graphs/contributors)
[![GitHub Issues](https://img.shields.io/github/issues/smashedr/node-badges?logo=codeforces&logoColor=white)](https://github.com/smashedr/node-badges/issues)
[![GitHub Discussions](https://img.shields.io/github/discussions/smashedr/node-badges?logo=theconversation)](https://github.com/smashedr/node-badges/discussions)
[![GitHub Forks](https://img.shields.io/github/forks/smashedr/node-badges?style=flat&logo=forgejo&logoColor=white)](https://github.com/smashedr/node-badges/forks)
[![GitHub Repo Stars](https://img.shields.io/github/stars/smashedr/node-badges?style=flat&logo=gleam&logoColor=white)](https://github.com/smashedr/node-badges/stargazers)
[![GitHub Org Stars](https://img.shields.io/github/stars/cssnr?style=flat&logo=apachespark&logoColor=white&label=org%20stars)](https://cssnr.github.io/)
[![Discord](https://img.shields.io/discord/899171661457293343?logo=discord&logoColor=white&label=discord&color=7289da)](https://discord.gg/wXy6m2X8wY)
[![Ko-fi](https://img.shields.io/badge/Ko--fi-72a5f2?logo=kofi&label=support)](https://ko-fi.com/cssnr)

Expand Down
1 change: 1 addition & 0 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ DEFAULT_VERSION="latest"
BUILD_CONTEXT="."


# shellcheck disable=SC1091
if [ -f ".env" ];then
echo "Sourcing Environment: .env"
set -a
Expand Down
Loading
Loading