Skip to content

Commit

Permalink
feat: Initial implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
Alorel committed Sep 21, 2023
1 parent 669e537 commit ac551f7
Show file tree
Hide file tree
Showing 136 changed files with 7,776 additions and 0 deletions.
41 changes: 41 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Auto detect text files and perform LF normalization
* text=auto

# Force the following filetypes to have unix eols, so Windows does not break them
*.* text eol=lf

# These files are text and should be normalized (Convert crlf => lf)
.browserlistrc text
*.js text
*.xml text
*.iml text
*.jsx text
*.ts text
*.tsx text
*.yml text
*.yaml text
*.nycrc text
*.toml text
*.pug text
*.md text
*.scss text
*.sass text
*.css text
*.less text
*.json text
LICENSE text
CHANGELOG text

*.ico binary
*.png binary
*.jpg binary
*.jpeg binary
*.webp binary
*.mp3 binary
*.wav binary
*.gif binary
*.gz binary
*.tgz binary
*.gz binary
*.br binary
*.tgz binary
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @Alorel
6 changes: 6 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# These are supported funding model platforms

github:
- Alorel
custom:
- "https://paypal.me/alorel"
71 changes: 71 additions & 0 deletions .github/actions/release/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
name: Release
description: Releases changes to the branch
inputs:
changelog:
description: changelog
required: true
major:
required: true
description: major version
minor:
required: true
description: minor version
patch:
required: true
description: patch version
issues-closed:
description: Issues closed by the release
runs:
using: composite
steps:
- uses: alorel-actions/git-ident@v1
name: Identity

- shell: bash
run: git tag v${{ inputs.major }} --force

- shell: bash
run: git tag v${{ inputs.major }}.${{ inputs.minor }} --force

- shell: bash
run: git tag v${{ inputs.major }}.${{ inputs.minor }}.${{ inputs.patch }}

- shell: bash
run: git push --tags --force

- uses: ncipollo/release-action@v1
with:
allowUpdates: true
prerelease: false
generateReleaseNotes: false
makeLatest: false
commit: ${{ github.sha }}
body: Alias for `v${{ inputs.major }}.${{ inputs.minor }}.${{ inputs.patch }}`
tag: v${{ inputs.major }}

- uses: ncipollo/release-action@v1
with:
allowUpdates: true
prerelease: false
generateReleaseNotes: false
makeLatest: false
commit: ${{ github.sha }}
body: Alias for `v${{ inputs.major }}.${{ inputs.minor }}.${{ inputs.patch }}`
tag: v${{ inputs.major }}.${{ inputs.minor }}

- uses: ncipollo/release-action@v1
with:
allowUpdates: false
prerelease: false
generateReleaseNotes: false
commit: ${{ github.sha }}
body: ${{ inputs.changelog }}
tag: v${{ inputs.major }}.${{ inputs.minor }}.${{ inputs.patch }}

- name: Notify
if: ${{ inputs.issues-closed }}
uses: ./dist/notify
with:
allow-out-of-sync: true
tag: v${{ inputs.major }}.${{ inputs.minor }}.${{ inputs.patch }}
issues: ${{ inputs.issues-closed }}
30 changes: 30 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Please see the documentation for all configuration options:
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2
updates:
- package-ecosystem: "github-actions" # See documentation for possible values
directory: "/" # Location of package manifests
schedule:
interval: "weekly"
commit-message:
prefix: deps
prefix-development: "deps(dev)"
ignore:
- dependency-name: "*"
update-types:
- version-update:semver-minor
- version-update:semver-patch

- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "weekly"
commit-message:
prefix: deps
prefix-development: "deps(dev)"
ignore:
- dependency-name: "*"
update-types:
- version-update:semver-minor
- version-update:semver-patch
17 changes: 17 additions & 0 deletions .github/semantic.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# https://github.com/Ezard/semantic-prs

enabled: true
commitsOnly: true
types:
- feat
- fix
- docs
- refactor
- build
- ci
- chore
- deps
- deps-dev
- perf
scopes:
- dev
91 changes: 91 additions & 0 deletions .github/workflows/core.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
name: Core
on:
push:
branches:
- master
pull_request:
branches:
- '**'

permissions:
contents: read

jobs:
test:
name: Test
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Default init
uses: ./
with:
key: foo

- name: Path init
uses: ./
with:
key: bar
path: here

- name: Test default path
shell: bash
run: |
if [ "$(cat ~/.ssh/id_rsa)" != "foo" ]; then
exit 1
fi
- name: Test custom path
shell: bash
run: |
if [ "$(cat here)" != "bar" ]; then
exit 1
fi
release:
name: Changelog & Release
runs-on: ubuntu-latest
needs:
- test
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-tags: true

- name: Parse
id: parse
uses: alorel-actions/semantic-release-lite@v0
with:
minor-types: |
feat: Features
patch-types: |
fix: Bug Fixes
deps: Dependency updates
perf: Performance
trivial-types: |
chore: Maintenance
ci: CI & Build
build: CI & Build
refactor: Refactors
docs: Documentation
- name: Release
uses: ./.github/actions/release
if: ${{ steps.parse.outputs.should-release && github.ref == 'refs/heads/master' }}
with:
major: ${{ steps.parse.outputs.next-version-major }}
minor: ${{ steps.parse.outputs.next-version-minor }}
patch: ${{ steps.parse.outputs.next-version-patch }}
changelog: ${{ steps.parse.outputs.changelog }}
issues-closed: ${{ steps.parse.outputs.issues-closed }}
10 changes: 10 additions & 0 deletions .idea/auto_sync.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/jsLibraryMappings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

25 changes: 25 additions & 0 deletions .idea/jsonSchemas.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit ac551f7

Please sign in to comment.