Template
1
0

Compare commits

...

10 Commits

Author SHA1 Message Date
9e5f490209 add golang setup 2025-02-24 08:59:31 +01:00
5c6c078b65 add Makefile support 2025-02-24 08:16:06 +01:00
679576895d update default branch names 2024-09-09 14:05:15 +02:00
6354ddb256 update pr and issue template to new yml based syntx 2024-09-09 13:47:09 +02:00
fff43b0aec fix CI wording (#1)
#### 📖 Summary

<!-- Provide a summary of your changes. Describe the why and not how. -->

#### 📑 Test Plan

> 💡 Select your test plan for the code changes.

- [x] CI pipeline tests
- [ ] Custom test
- [ ] No test plan

##### Details / Justification

<!-- Add your test details or justification for missing tests here. -->

#### 📚 Additional Notes

<!-- A place for additional detail notes. -->

Reviewed-on: Templates/Baseline#1
2022-12-09 12:35:56 +01:00
bdd598ad67 fix readme casing 2022-08-01 10:27:25 +02:00
6596af8add add missing logo file 2022-08-01 09:55:10 +02:00
d713bc7594 add template Readme file 2022-08-01 09:47:52 +02:00
a380a5b327 add vscode config 2022-08-01 09:47:42 +02:00
0a965c5c3a add optional local git helpers 2022-08-01 09:47:25 +02:00
20 changed files with 431 additions and 110 deletions

View File

@ -1,14 +1,16 @@
root = true root = true
[*] [*]
indent_style = space indent_style = space
indent_size = 2 indent_size = 2
end_of_line = lf end_of_line = lf
charset = utf-8 charset = utf-8
trim_trailing_whitespace = true trim_trailing_whitespace = true
insert_final_newline = true insert_final_newline = true
[*.go]
[*.go] indent_style = tab
indent_style = tab indent_size = 4
indent_size = 4
[Makefile]
indent_style = tab

View File

@ -1,10 +0,0 @@
---
name: 'Default'
about: 'Use this template if nothing seems to work.'
title: ':question: '
labels:
- question
---
#### :grey_question: Simply ask your question here: :grey_question:
<!-- Take your time an think about your problem.... -->

17
.gitea/ISSUE_TEMPLATE.yml Normal file
View File

@ -0,0 +1,17 @@
name: Default
about: Use this template if nothing seems to work.
title: ''
body:
- type: markdown
attributes:
value: |
> [!NOTE]
> Thanks for taking the time to fill out this bug report!
- type: textarea
id: content
attributes:
label: ❔ What happened
description: Simply ask your question here.
placeholder: Tell us what you want to know...
validations:
required: true

View File

@ -1,48 +0,0 @@
---
name: 'Bug'
about: 'This template is used to report bugs!'
title: ':lady_beetle: '
labels:
- bug
---
<!--
This bug report is ony for content provided in this repository!
- Make sure you're able to reproduce the error in the latest version of this package.
- Search of already existing issues.
- Refer to the known issues and FAQ section.
-->
#### :bomb: Steps to reproduce
```bash
```
#### :rocket: Expected behavior
```bash
```
#### :boom: Actual behavior
```bash
```
#### :notebook: Environment data
<!-- You can add additional environment data here--->
```bash
```
#### :framed_picture: Screenshots
<!-- Paste your screenshots here. -->
#### :bookmark: Refs
<!-- A place for additional references to other issues and PRs -->

View File

@ -0,0 +1,70 @@
name: 🐞 Bug Report
about: This template is used to report bugs!
title: ''
labels:
- bug
body:
- type: markdown
attributes:
value: |
> [!NOTE]
> This bug report is only for content provided in this repository!
>
> - Make sure you're able to reproduce the error in the lastest version of this package.
> - Search of already existing issues.
> - Refer to the known issues and FAQ section.
- type: textarea
id: reproduce
attributes:
label: 💣 Steps to reproduce
description: Describe ho to reproduce the error.
value: |
```bash
```
validations:
required: true
- type: textarea
id: expected
attributes:
label: 🚀 Expected behavior
description: Describe what should happen.
value: |
```bash
```
validations:
required: true
- type: textarea
id: actual
attributes:
label: 💥 Actual behavior
description: Describe what actually happens.
value: |
```bash
```
validations:
required: true
- type: textarea
id: env
attributes:
label: 📓 Environment data
description: You can add additional environment data here.
placeholder: |
```bash
```
- type: textarea
id: img
attributes:
label: 🖼️ Screenshots
description: Paste your screenshots here.
placeholder: Copy-Paste or Drag-and-Drop your images...
- type: textarea
id: refs
attributes:
label: 🔖 Refs
description: A place for additional references to other issues and PRs.
placeholder: |
- reopens #999

View File

@ -1,16 +0,0 @@
---
name: 'Enhancement'
about: 'Wite about new features.'
title: ':flying_saucer: '
labels:
- issue/enhancement
---
<!-- This issue template is used to describe whished features. -->
#### :satellite: Suggestion
#### :artificial_satellite: Implementation ideas
#### :framed_picture: Mock-up Images
#### :bookmark: Refs.

View File

@ -0,0 +1,47 @@
name: 🛸 Feature Request
about: Wite about new features.
title: ''
labels:
- feature
- enhancement
body:
- type: markdown
attributes:
value: |
> [!NOTE]
> This bug report is only for content provided in this repository!
>
> This issue template is used to describe new features or enhancements.
- type: textarea
id: idea
attributes:
label: 📡 Suggestion
description: Describe ho to reproduce the error.
value: |
```bash
```
validations:
required: true
- type: textarea
id: impl
attributes:
label: 🛰️ Implementation ideas
description: Describe your initial implementation ideas.
validations:
required: true
- type: textarea
id: mockup
attributes:
label: 🖼️ Mock-up
description: Alternatively add your mockups here.
placeholder: Copy-Paste or Drag-and-Drop your images...
validations:
required: true
- type: textarea
id: refs
attributes:
label: 🔖 Refs
description: A place for additional references to other issues and PRs.
placeholder: |
- reopens #999

View File

@ -0,0 +1,19 @@
name: ❓ Question
about: Use this template if nothing seems to work.
title: ''
labels:
- question
body:
- type: markdown
attributes:
value: |
> [!NOTE]
> Thanks for taking the time to fill out this bug report!
- type: textarea
id: content
attributes:
label: ❔ What happened
description: Simply ask your question here.
placeholder: Tell us what you want to know...
validations:
required: true

View File

@ -1,19 +0,0 @@
#### :book: Summary
<!-- Provide a summary of your changes. Describe the why and not how. -->
#### :bookmark_tabs: Test Plan
> :bulb: Select your test plan for the code changes.
- [ ] Tested via Drone.io pipeline
- [ ] Custom test
- [ ] No test plan
##### Details / Justification
<!-- Add your test details or justification for missing tests here. -->
#### :books: Additional Notes
<!-- A place for additional detail notes. -->

View File

@ -0,0 +1,42 @@
name: Pull Request
about: General pull request
title: ""
body:
- type: markdown
attributes:
value: |
> [!NOTE]
> Thanks for contributing to this project with your pull request!
- type: textarea
id: summary
attributes:
label: 📖 Summary
description: Provide a summary of your changes. Also describe the why...
placeholder: Tell us about your code changes.
validations:
required: true
- type: dropdown
id: testplan
attributes:
label: 📑 Test Plan
description: How did you test your code changes?
options:
- ✅ CI pipeline tests (Default)
- 🤔 Custom test
- 💣 No test Plan
validations:
required: true
- type: textarea
id: details
attributes:
label: 💬 Details
description: Add your custom test details or justification for missing tests here.
placeholder: First, solve the problem. Then, write the code.
- type: textarea
id: notes
attributes:
label: 📚 Additional Notes
description: A place for additional notes or linking references.
placeholder: Software and cathedrals are much the same - First we build them, then we pray.

View File

@ -1 +1,2 @@
Readme.md README.md
Makefile

7
.gitignore vendored
View File

@ -7,8 +7,15 @@ data/*.csv
# Ignore temp build artifacts # Ignore temp build artifacts
/bin/* /bin/*
/dist/*
!bin/.gitkeep !bin/.gitkeep
# Ignore Pester test result files # Ignore Pester test result files
coverage.xml coverage.xml
testResults.xml testResults.xml
# Ignore NodeJS modules
node_modules
# Ignore local env setups
.env

19
.gitlocal Normal file
View File

@ -0,0 +1,19 @@
[alias]
# simplified logs
log1 = log --graph --abbrev-commit --decorate --date=relative --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --all
log2 = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an%C(reset)' --all
# Aliases for a Phabricator inspired workflow
# 1. Create new feature branch
feature = "!f(){ b=$1; git checkout main; git pull; git checkout -b "$b" main; };f"
# 2. Working with code
wip = !"git add -A; git commit -m '[WIP]'"
squish = !"git add -A; git commit --no-edit --amend"
# 3. Push to origin
pod = !"git push origin dev"
# 4. Push to custom remote branch
poc = "!f(){ b=$1; git push origin "$b";};f"

10
.prettierrc.json Normal file
View File

@ -0,0 +1,10 @@
{
"$schema": "https://json.schemastore.org/prettierrc",
"arrowParens": "always",
"bracketSpacing": true,
"printWidth": 116,
"semi": false,
"singleQuote": true,
"trailingComma": "all",
"vueIndentScriptAndStyle": true
}

View File

@ -0,0 +1 @@
tbd

11
.vscode/extensions.json vendored Normal file
View File

@ -0,0 +1,11 @@
{
"recommendations": [
"editorconfig.editorconfig",
"esbenp.prettier-vscode",
"golang.go",
"vue.volar",
"eamodio.gitlens",
"streetsidesoftware.code-spell-checker",
"bierner.emojisense",
]
}

71
.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,71 @@
{
"files.encoding": "utf8",
"files.eol": "auto",
"files.trimTrailingWhitespace": true,
"files.insertFinalNewline": true,
"editor.renderWhitespace": "boundary",
"editor.formatOnSave": true,
"editor.formatOnType": true,
"editor.rulers": [
116
],
// powershell general
"powershell.startAutomatically": true,
"powershell.enableProfileLoading": true,
"powershell.scriptAnalysis.enable": true,
// powershell code Formatting
"powershell.codeFormatting.openBraceOnSameLine": true,
"powershell.codeFormatting.newLineAfterOpenBrace": true,
"powershell.codeFormatting.newLineAfterCloseBrace": true,
"powershell.codeFormatting.whitespaceBeforeOpenBrace": true,
"powershell.codeFormatting.whitespaceBeforeOpenParen": true,
"powershell.codeFormatting.whitespaceAroundOperator": true,
"powershell.codeFormatting.whitespaceAfterSeparator": true,
"powershell.codeFormatting.ignoreOneLineBlock": true,
"powershell.codeFormatting.alignPropertyValuePairs": true,
// cSpell settings for custom dictionary
"cSpell.enabled": true,
"cSpell.caseSensitive": false,
"cSpell.maxNumberOfProblems": 100,
"cSpell.numSuggestions": 8,
"cSpell.minWordLength": 3,
"cSpell.allowCompoundWords": false,
"cSpell.ignorePaths": [
"package-lock.json",
"node_modules",
"vscode-extension",
".git/objects",
".vscode",
".vscode-insiders"
],
"cSpell.enabledLanguageIds": [
"c",
"cpp",
"csharp",
"go",
"javascript",
"javascriptreact",
"json",
"latex",
"markdown",
"php",
"plaintext",
"powershell",
"python",
"text",
"typescript",
"typescriptreact",
"yaml",
"yml"
],
"cSpell.language": "en-US",
"cSpell.customDictionaries": {
"project-words": {
"name": "project-words",
"path": "${workspaceRoot}/.vscode/dictionaries/project-words.txt",
"description": "Words used in this project",
"addWords": true
},
"custom": true
}
}

69
Makefile Normal file
View File

@ -0,0 +1,69 @@
.DEFAULT_GOAL := build
BINARY_NAME := ${REPO_NAME}
LDFLAGS := -s -w
arkanum-install:
@echo "🤖 Installing required frameworks and runtimes with arkanum..."
@arkanum install golang
@arkanum install nodejs
@echo "🚩 step done."
install:
@echo "🤖 Installing frontend dependencies...(npm)"
cd web && npm install
@echo "🤖 Install backend dependencies...(golang)"
go mod tidy
@echo "🤖 Install global helpers..."
npm install --global prettier
@echo "🚩 step done."
lint:
@echo "🤖 Running prettier linter in check mode..."
pretier -c .
prettier:
@echo "🤖 Running prettier linter in write mode..."
prettier -w .
clean:
@echo "🤖 Cleaning go cache..."
@go clean
@echo "🤖 Cleanig web / pb_public files..."
@cd web && npm run clean
@echo "🤖 Cleaning dist binaries..."
@rm dist/${BINARY_NAME}-* || echo "Files already removed or not present. Ignore this error."
@echo "🚩 step done."
build-frontend:
@echo "📦 Building frontend artifacts..."
@cd web && npm run build
@echo "🚩 step done."
frontend-dev:
@echo "🚀 Starting frontend dev server..."
@cd web && npm run dev
build-linux: clean build-frontend
@echo "📦 Building linux binary..."
@CGO_ENABLED=0 GOARCH=amd64 GOOS=linux go build -a -v ldflags= '${LD_FLAGS}' -o dist/${BINARY_NAME}-linux-amd64 .
@echo "🚩 step done."
build-win: clean build-frontend
@echo "📦 Building windows binary..."
@CGO_ENABLED=0 GOARCH=amd64 GOOS=windows go build -a -v ldflags= '${LD_FLAGS}' -o dist/${BINARY_NAME}-win-amd64 .
@echo "🚩 step done."
build: build-linux build-win
@ls -lh dist/
@echo "🏁 done."
dev: clean build-frontend
@echo "📦 Building linux dev binary..."
@CGO_ENABLED=0 GOARCH=amd64 GOOS=linux go build -tags dev -v ldflags '${LD_FLAGS}' -o dist/${BINARY_NAME}-dev .
@echo "🚀 Starting dev server..."
dist/${BINARY_NAME}-dev serve --dev --http="0.0.0.0:1313"
serve:
@echo "🚀 Starting dev server in prod mode..."
dist/${BINARY_NAME}-linux-amd64 serve --http="0.0.0.0:1313"

View File

@ -1,3 +1,31 @@
# Baseline <p align="right">
<img src="http://forthebadge.com/images/badges/built-with-love.svg">
<img src="http://forthebadge.com/images/badges/for-you.svg">
</p>
Baseline repository template with common meta files. <p align="center">
<a href="https://gitea.ocram85.com/${REPO_OWNER}/${REPO_NAME}/">
<img
src="${REPO_LINK}/raw/branch/main/assets/social-logo.png"
alt="${REPO_NAME}"
>
</a>
</p>
<h1 align="center">
${REPO_NAME}
</h1>
<p align="center">
${REPO_DESCRIPTION}
</p>
<p align="center">
<a href="https://ci.ocram85.com/${REPO_OWNER}/${REPO_NAME}">
<img src="https://ci.ocram85.com/api/badges/${REPO_OWNER}/${REPO_NAME}/status.svg" alt="Main Branch Build Status">
</a>
</p>
## :book: General
> :bulb: tbd...

BIN
assets/social-logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB