Skip to content

Commit 050ec7c

Browse files
committed
welcome to github
0 parents  commit 050ec7c

File tree

18 files changed

+1046
-0
lines changed

18 files changed

+1046
-0
lines changed

.editorconfig

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
; https://editorconfig.org/
2+
3+
root = true
4+
5+
[*]
6+
insert_final_newline = true
7+
charset = utf-8
8+
trim_trailing_whitespace = true
9+
indent_style = space
10+
indent_size = 2
11+
12+
[{Makefile,go.mod,go.sum,*.go,.gitmodules}]
13+
indent_style = tab
14+
indent_size = 4
15+
16+
[*.md]
17+
indent_size = 4
18+
trim_trailing_whitespace = false
19+
20+
eclint_indent_style = unset
21+
22+
[Dockerfile]
23+
indent_size = 4

.github/CODEOWNERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* @arhea

.github/FUNDING.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# These are supported funding model platforms
2+
3+
github: [arhea]
4+
patreon: # Replace with a single Patreon username
5+
open_collective: # Replace with a single Open Collective username
6+
ko_fi: # Replace with a single Ko-fi username
7+
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8+
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9+
liberapay: # Replace with a single Liberapay username
10+
issuehunt: # Replace with a single IssueHunt username
11+
otechie: # Replace with a single Otechie username
12+
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
13+
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']

.github/dependabot.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "gomod"
4+
target-branch: "main"
5+
directory: "/"
6+
schedule:
7+
interval: "weekly"

.github/workflows/main.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Test / Quality
2+
3+
on:
4+
push:
5+
branches: [main]
6+
7+
pull_request:
8+
types: [opened, reopened, edited]
9+
10+
jobs:
11+
check:
12+
name: Quality / Check
13+
runs-on: ubuntu-latest
14+
15+
permissions:
16+
contents: "read"
17+
id-token: "write"
18+
19+
steps:
20+
- uses: actions/checkout@v4
21+
22+
- uses: actions/setup-go@v4
23+
with:
24+
check-latest: true
25+
go-version: stable
26+
27+
- uses: golangci/golangci-lint-action@v3
28+
29+
- run: make ci
30+
shell: bash

.github/workflows/release.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Release
2+
3+
on:
4+
release:
5+
types: [published]
6+
7+
jobs:
8+
docs:
9+
name: Trigger Documentation
10+
runs-on: ubuntu-latest
11+
12+
permissions:
13+
contents: "read"
14+
15+
steps:
16+
- run: curl -sfL https://proxy.golang.org/github.com/${{ github.repository }}/@v/${{ github.ref_name }}.info
17+
shell: bash

.gitignore

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# If you prefer the allow list template instead of the deny list, see community template:
2+
# https://github.com/github/gitignore/blob/main/community/Golang/Go.AllowList.gitignore
3+
#
4+
# Binaries for programs and plugins
5+
*.exe
6+
*.exe~
7+
*.dll
8+
*.so
9+
*.dylib
10+
.DS_Store
11+
12+
# Test binary, built with `go test -c`
13+
*.test
14+
15+
# Output of the go coverage tool, specifically when used with LiteIDE
16+
*.out
17+
18+
# Dependency directories (remove the comment below to include it)
19+
# vendor/
20+
21+
# Go workspace file
22+
go.work
23+
24+
# Log files
25+
*.log
26+
27+
# Temporary files
28+
/tmp
29+
30+
# Configuration files
31+
*.env

.golangci.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# Refer to golangci-lint's example config file for more options and information:
2+
# https://github.com/golangci/golangci-lint/blob/master/.golangci.example.yml
3+
4+
run:
5+
timeout: 5m
6+
modules-download-mode: readonly
7+
8+
linters:
9+
disable-all: true
10+
enable:
11+
- errcheck
12+
- gosimple
13+
- govet
14+
- ineffassign
15+
- staticcheck
16+
- unused
17+
- bodyclose
18+
- revive
19+
- gosec
20+
- exportloopref
21+
- misspell
22+
23+
linters-settings:
24+
revive:
25+
rules:
26+
- name: unused-parameter
27+
disabled: true
28+
29+
issues:
30+
exclude-use-default: false
31+
max-issues-per-linter: 0
32+
max-same-issues: 0

.vscode/settings.json

Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
{
2+
"editor.formatOnSave": false,
3+
"editor.formatOnPaste": false,
4+
"editor.formatOnType": false,
5+
"editor.codeActionsOnSave": [ ],
6+
"editor.rulers": [ 120 ],
7+
8+
// markdown formatting options
9+
"[markdown]": {
10+
"editor.formatOnSave": true,
11+
"editor.defaultFormatter": "esbenp.prettier-vscode"
12+
},
13+
// json formatting options
14+
"[json]": {
15+
"editor.formatOnSave": true,
16+
"editor.defaultFormatter": "vscode.json-language-features"
17+
},
18+
"[jsonc]": {
19+
"editor.formatOnSave": true,
20+
"editor.defaultFormatter": "vscode.json-language-features"
21+
},
22+
// yaml formatting options
23+
"[yaml]": {
24+
"editor.formatOnSave": true,
25+
"editor.defaultFormatter": "redhat.vscode-yaml"
26+
},
27+
// we want to support make files as well
28+
"[makefile]": {
29+
"editor.formatOnSave": true,
30+
"editor.defaultFormatter": "ms-vscode.makefile-tools"
31+
},
32+
// go specific settings
33+
"[go]": {
34+
"editor.formatOnSave": true,
35+
"editor.defaultFormatter": "golang.go",
36+
"editor.codeActionsOnSave": {
37+
"source.organizeImports": "explicit",
38+
"source.fixAll": "explicit"
39+
}
40+
},
41+
// make sure the go language server is enabled
42+
"go.useLanguageServer": true,
43+
// configure gopls, the go language server
44+
"gopls": {
45+
"ui.semanticTokens": true,
46+
"ui.completion.usePlaceholders": true
47+
},
48+
// configure the go formatting tool to be goimports
49+
"go.formatTool": "goimports",
50+
"go.formatFlags": [ "-local", "github.com/arhea/" ],
51+
52+
// change the linting tool to be golangci
53+
"go.lintTool": "golangci-lint",
54+
"go.lintOnSave": "workspace",
55+
"go.lintFlags": [ "--fast" ],
56+
// configure the tags we want to add by default
57+
"go.addTags": {
58+
"tags": "json,validate",
59+
"options": "json=omitempty,validate=omitempty",
60+
"promptForTags": false,
61+
"transform": "snakecase",
62+
"template": ""
63+
},
64+
// dont run code coverage on save
65+
"go.coverOnSave": false,
66+
"go.coverOnSingleTest": true,
67+
"go.coverOnTestPackage": true,
68+
"go.coverShowCounts": false,
69+
"go.coverageDecorator": {
70+
"type": "gutter",
71+
"coveredHighlightColor": "rgba(64,128,128,0.5)",
72+
"uncoveredHighlightColor": "rgba(128,64,64,0.25)",
73+
"coveredGutterStyle": "blockgreen",
74+
"uncoveredGutterStyle": "blockred"
75+
},
76+
// configure some helpful test environment variables
77+
"go.testEnvVars": {
78+
"WORKSPACE_DIR": "${workspaceFolder}"
79+
}
80+
}

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2023 Alex Rhea
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

0 commit comments

Comments
 (0)