-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
36 changed files
with
4,015 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
end_of_line = lf | ||
insert_final_newline = true | ||
trim_trailing_whitespace = true | ||
|
||
[*.{cjs,cpp,dart,htm,html,js,json,json5,jsx,mjs,pu,puml,rb,ts,tsx,vue,yaml,yml}] | ||
indent_size = 2 | ||
indent_style = space | ||
|
||
[*.{go,gradle,py}] | ||
indent_size = 4 | ||
indent_style = space | ||
|
||
[*.sh] | ||
indent_size = 8 | ||
indent_style = space | ||
|
||
[*.md] | ||
max_line_length = off | ||
trim_trailing_whitespace = false | ||
|
||
[{Makefile,*.mk}] | ||
indent_style = tab |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
* text=auto | ||
|
||
*.vcproj text eol=crlf | ||
|
||
*.cjs text eol=lf | ||
*.cpp text eol=lf | ||
*.dart text eol=lf | ||
*.htm text eol=lf | ||
*.html text eol=lf | ||
*.js text eol=lf | ||
*.json text eol=lf | ||
*.json5 text eol=lf | ||
*.jsx text eol=lf | ||
*.mjs text eol=lf | ||
*.pu text eol=lf | ||
*.puml text eol=lf | ||
*.rb text eol=lf | ||
*.ts text eol=lf | ||
*.tsx text eol=lf | ||
*.vue text eol=lf | ||
*.yaml text eol=lf | ||
*.yml text eol=lf | ||
*.go text eol=lf | ||
*.gradle text eol=lf | ||
*.py text eol=lf | ||
*.md text eol=lf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
name: Add issue to github project | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
target_organization: | ||
required: false | ||
type: string | ||
label: | ||
required: false | ||
type: string | ||
default: project | ||
secrets: | ||
GH_PROJECT_URL: | ||
required: true | ||
GH_TOKEN: | ||
required: false | ||
|
||
jobs: | ||
add-to-project: | ||
if: ${{ !inputs.target_organization || github.repository_owner == inputs.target_organization }} | ||
runs-on: ${{ (!github.event.repository.private && 'ubuntu-latest') || fromJSON('["self-hosted", "medium"]') }} | ||
env: | ||
FORCE_COLOR: 3 | ||
steps: | ||
- uses: actions/[email protected] | ||
with: | ||
project-url: ${{ secrets.GH_PROJECT_URL }} | ||
github-token: ${{ secrets.GH_TOKEN }} | ||
labeled: ${{ inputs.label }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
name: Add close comment | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
target_organization: | ||
required: false | ||
type: string | ||
|
||
jobs: | ||
close-comment: | ||
if: ${{ !inputs.target_organization || github.repository_owner == inputs.target_organization }} | ||
runs-on: ${{ (!github.event.repository.private && 'ubuntu-latest') || fromJSON('["self-hosted", "medium"]') }} | ||
env: | ||
FORCE_COLOR: 3 | ||
steps: | ||
- run: | | ||
branchNumber=${{github.head_ref}} | ||
branchNumber=($(echo $branchNumber | tr "_" "-")) | ||
branchNumber=($(echo $branchNumber | tr "-" "\n")) | ||
re='^[0-9]+$' | ||
if [[ $branchNumber =~ $re ]]; then | ||
comment=$(curl \ | ||
-H "Accept:application/vnd.github+json" \ | ||
-H "Authorization:token ${{ secrets.GITHUB_TOKEN }}" \ | ||
https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.pull_request.number }} ) | ||
commentBody=$(echo $comment | jq .body) | ||
commentBody=$(echo $commentBody | tr -d "\"") | ||
newBody="close #$branchNumber\r\n$commentBody" | ||
curl \ | ||
-X PATCH \ | ||
-H "Accept:application/vnd.github+json" \ | ||
-H "Authorization:token ${{ secrets.GITHUB_TOKEN }}" \ | ||
https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.pull_request.number }} \ | ||
-d "{\"body\": \"${newBody}\"}" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: Show a given text (self-hosted) | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
cpu_arch: | ||
required: false | ||
type: string | ||
github_hosted_runner: | ||
required: false | ||
type: boolean | ||
text: | ||
required: true | ||
type: string | ||
outputs: | ||
text: | ||
value: ${{ jobs.echo.outputs.text }} | ||
|
||
jobs: | ||
echo: | ||
runs-on: self-hosted | ||
env: | ||
FORCE_COLOR: 3 | ||
outputs: | ||
text: ${{ steps.echo.outputs.text }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: willbooster/asdf-actions/install@main | ||
- id: echo | ||
run: | | ||
echo "text=${{ inputs.text }}" >> $GITHUB_OUTPUT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
name: Debug | ||
|
||
on: | ||
workflow_call: | ||
|
||
jobs: | ||
debug: | ||
runs-on: ${{ (!github.event.repository.private && 'ubuntu-latest') || fromJSON('["self-hosted", "medium"]') }} | ||
env: | ||
FORCE_COLOR: 3 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- run: | | ||
pwd | ||
ls -al |
Oops, something went wrong.