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
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @smashedr
1 change: 1 addition & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ko_fi: cssnr
16 changes: 9 additions & 7 deletions .github/ISSUE_TEMPLATE/0-bug.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: "⚠️ Report an Issue"
description: "Something Not Working Right? Please let us know..."
description: "Please let us know if something is not working right..."
labels: ["bug"]
assignees:
- smashedr
Expand All @@ -10,17 +10,17 @@ body:
validations:
required: false
attributes:
label: Repo Link
description: Please provide a link to the repository or workflow you are having issues with if possible.
label: URL
description: Please provide a link to the repository or workflow in question if possible.

- type: textarea
id: description
validations:
required: true
attributes:
label: Details
description: Please describe the issue you are experiencing and how to reproduce.
placeholder: Provide as many details as you can...
label: Issue Description
description: Please describe the issue you are experiencing and how it can be reproduced.
placeholder: Provide as many details as possible...

- type: textarea
id: logs
Expand All @@ -29,9 +29,11 @@ body:
attributes:
label: Log Output
description: Paste any relevant logs or output in this box.
placeholder: This text is automatically wrapped in a code block.
render: shell

- type: markdown
attributes:
value: |
All issues/bugs that we can verify will be fixed. Thank you for taking the time to make this report!
Any issues or bugs that can be verified will be fixed!
Thank you very much for taking the time to make this report...
10 changes: 5 additions & 5 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
blank_issues_enabled: true
contact_links:
- name: "💡 Request a Feature"
about: Request a New Feature or Enhancement in the Discussions.
about: Request a new feature or enhancement in a discussions.
url: https://github.com/cssnr/env-json-action/discussions/new?category=feature-requests

- name: "❔ Ask a Question"
about: Ask a General Question or start a Discussions.
about: Ask a general question or start a discussions.
url: https://github.com/cssnr/env-json-action/discussions/new?category=q-a

- name: "💬 Join Discord"
about: Chat with us about Issues, Features, Questions and More.
about: Chat with us about general questions, issues or suggestions.
url: https://discord.gg/wXy6m2X8wY

- name: "📝 Submit Feedback"
about: Send General Feedback.
url: https://cssnr.github.io/feedback/?app=Environment%20to%20JSON
about: Send general feedback through the website.
url: https://cssnr.github.io/feedback
8 changes: 8 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Overview



## Checklist
<!-- Do NOT remove tasks and append any custom tasks -->
- [ ] Verify the Required Checks are Passing
- [ ] Document changes in the [README.md](../blob/master/README.md) (for new features)
47 changes: 47 additions & 0 deletions .github/workflows/labeler.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: "PR Labeler"

on:
pull_request_target:

permissions:
pull-requests: write

jobs:
labeler:
name: "Labeler"
runs-on: ubuntu-latest
timeout-minutes: 5

steps:
- name: "Checkout Configs"
uses: actions/checkout@v5
with:
repository: cssnr/configs
ref: master
path: .configs
sparse-checkout-cone-mode: false
sparse-checkout: |
labels/**

- name: "Debug"
continue-on-error: true
run: |
echo "::group::labels.yaml"
cat .configs/labels/labels.yaml
echo "::endgroup::"

echo "::group::labeler.yaml"
cat .configs/labels/labeler.yaml
echo "::endgroup::"

- name: "Label Creator"
continue-on-error: true
uses: cssnr/label-creator-action@master
with:
file: .configs/labels/labels.yaml

- name: "Labeler"
uses: actions/labeler@v6
with:
sync-labels: true
configuration-path: .configs/labels/labeler.yaml
89 changes: 48 additions & 41 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,13 @@ on:
push:
branches: [master]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

permissions:
pull-requests: write

jobs:
lint:
name: "Lint"
Expand All @@ -14,60 +21,60 @@ jobs:

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

- name: "Setup Node 22"
uses: actions/setup-node@v4
- name: "Setup Node 24"
uses: actions/setup-node@v5
with:
node-version: 22
#cache: npm
node-version: 24

- name: "Install"
id: install
run: |
npm install
npm ci

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

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

build:
name: "Build"
runs-on: ubuntu-latest
timeout-minutes: 5

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

- name: "Setup Node 22"
uses: actions/setup-node@v4
with:
node-version: 22
#cache: npm
npm run prettier:check

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

- name: "Build"
run: |
npm run build
#- 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: "Verify"
run: |
git status --porcelain dist/
if [ ! -d "dist" ];then
echo "Missing dist directory, run: npm build"
exit 1
fi
if [ -n "$(git status --porcelain dist)" ];then
echo "Build was not run, run: npm build"
exit 1
fi
- name: "Check Build Action"
if: ${{ !cancelled() }}
uses: cssnr/check-build-action@v1

- name: "ESLint Annotate"
if: ${{ !cancelled() && steps.eslint.outcome != 'success' }}
continue-on-error: true
uses: ataylorme/eslint-annotate-action@v3
6 changes: 5 additions & 1 deletion .github/workflows/mirror.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ on:
branches: ["**"]
tags: ["**"]

concurrency:
group: ${{ github.workflow }}
cancel-in-progress: true

jobs:
mirror:
name: "Mirror"
Expand All @@ -14,7 +18,7 @@ jobs:

steps:
- name: "Checkout"
uses: actions/checkout@v4
uses: actions/checkout@v5
with:
fetch-depth: 0

Expand Down
24 changes: 24 additions & 0 deletions .github/workflows/pull.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: "Pull"

on:
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
pull:
name: "Pull"
runs-on: ubuntu-latest
timeout-minutes: 5
permissions:
pull-requests: write

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

- name: "NPM Outdated Check"
continue-on-error: true
uses: cssnr/npm-outdated-action@master
24 changes: 24 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,28 @@ jobs:

steps:
- name: "Update Tags"
id: tags
uses: cssnr/update-version-tags-action@v1

- name: "Debug Tags"
continue-on-error: true
run: |
echo "github.ref_name: ${{ github.ref_name }}"
echo "steps.tags.outputs.tags: ${{ steps.tags.outputs.tags }}"

- name: "Update Release Notes Action"
continue-on-error: true
uses: smashedr/update-release-notes-action@master
with:
tags: ${{ steps.tags.outputs.tags }}
location: tail

- name: "Package Changelog Action"
continue-on-error: true
uses: cssnr/package-changelog-action@v1

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

- name: "Schedule Failure Notification"
if: ${{ always() && failure() && github.event_name == 'schedule' }}
if: ${{ failure() && github.event_name == 'schedule' }}
uses: sarisia/actions-status-discord@v1
with:
webhook: ${{ secrets.DISCORD_WEBHOOK }}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
*.iml
.vscode/
node_modules/
eslint_report.json
.env
.secrets
.vars
16 changes: 15 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
# IDE
.idea/
.vscode/

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

# Build
dist/
node_modules/
package-lock.json
.github/disabled/

# Files
.github/pull_request_template.md
3 changes: 2 additions & 1 deletion .prettierrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"trailingComma": "es5",
"semi": false,
"singleQuote": true,
"printWidth": 90,
"overrides": [
{
"files": ["**/*.html", "**/*.yaml", "**/*.yml"],
Expand All @@ -10,7 +11,7 @@
}
},
{
"files": ["**/*.js", "**/*.css", "**/*.scss"],
"files": ["**/*.js", "**/*.mjs", "**/*.css", "**/*.scss"],
"options": {
"tabWidth": 4
}
Expand Down
Loading