5 Commits

Author SHA1 Message Date
Alexander
29c564380d feat(infra): Adds pre-comit setup and conventional commit message enforment
All checks were successful
On-Site VTT - Develop / build (push) Successful in 2m50s
Adds git-hooks for pre-commit package and configuration for repository checks and commit messages
2023-12-11 21:46:45 +01:00
Alexander
a8d01fd9bf Update pipelines
All checks were successful
On-Site VTT - Develop / build (push) Successful in 3m19s
2023-12-11 13:52:23 +01:00
Alexander
402c6da5df Preparation for main-pipeline 2023-12-11 13:47:49 +01:00
Alexander
f9fefaf404 Fixes locations of files in module 2023-12-11 13:22:56 +01:00
Alexander
fa3c98d2b7 Adds ready method and fixes spelling
All checks were successful
On-Site VTT - Develop / build (push) Successful in 2m44s
2023-12-11 13:11:30 +01:00
11 changed files with 55 additions and 22 deletions

View File

@@ -42,7 +42,9 @@ jobs:
title: dev-${{ steps.date.outputs.date }} title: dev-${{ steps.date.outputs.date }}
tag_name: dev-${{ steps.date.outputs.date }} tag_name: dev-${{ steps.date.outputs.date }}
files: |- files: |-
"LICENSE.txt"
"README.md"
"on-site-vtt/module.json" "on-site-vtt/module.json"
on-site-vtt.zip "on-site-vtt.zip"
pre_release: true pre_release: true
api_key: "${{secrets.RELEASE_TOKEN}}" api_key: "${{secrets.RELEASE_TOKEN}}"

View File

@@ -5,8 +5,6 @@ on:
push: push:
branches: branches:
- main - main
tags:
- "*"
jobs: jobs:
build: build:
@@ -31,11 +29,19 @@ jobs:
find: "{{branch}}" find: "{{branch}}"
replace: ${{ github.ref }} replace: ${{ github.ref }}
include: "on-site-vtt/module.json" include: "on-site-vtt/module.json"
- name: Pack and release - name: Pack archive
uses: actions/release-action@main uses: montudor/action-zip@v1
with: with:
title: ${{ github.ref_name }} args: zip -r on-site-vtt.zip on-site-vtt
pre_release: false - name: publish release
api_key: "${{secrets.RELEASE_TOKEN}}" uses: https://gitea.aweleczka.de/actions/release-action@main
with:
title: dev-${{ steps.date.outputs.date }}
tag_name: dev-${{ steps.date.outputs.date }}
files: |- files: |-
on-site-vtt/** "LICENSE.txt"
"README.md"
"on-site-vtt/module.json"
"on-site-vtt.zip"
pre_release: true
api_key: "${{secrets.RELEASE_TOKEN}}"

2
.gitignore vendored
View File

@@ -23,7 +23,7 @@
.LSOverride .LSOverride
# Icon must end with two \r # Icon must end with two \r
Icon Icon
# Thumbnails # Thumbnails
._* ._*

21
.pre-commit-config.yaml Normal file
View File

@@ -0,0 +1,21 @@
## See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-added-large-files
- id: check-json
- id: check-byte-order-marker
- id: end-of-file-fixer
- id: mixed-line-ending
- id: detect-private-key
- repo: https://github.com/compilerla/conventional-pre-commit
rev: v3.0.0
hooks:
- id: conventional-pre-commit
stages: [commit-msg]
args: [feat, fix, chore, test]

View File

@@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE. SOFTWARE.

View File

@@ -1 +1 @@
# On-Site VTT # On-Site VTT

View File

@@ -1,4 +1,4 @@
{ {
"on-site-vtt.title": "On-Site VTT", "on-site-vtt.title": "On-Site VTT",
"on-site-vtt.rotate": "Ansicht drehen" "on-site-vtt.rotate": "Ansicht drehen"
} }

View File

@@ -1,4 +1,4 @@
{ {
"on-site-vtt.title": "On-Site VTT", "on-site-vtt.title": "On-Site VTT",
"on-site-vtt.rotate": "Rotate view" "on-site-vtt.rotate": "Rotate view"
} }

View File

@@ -26,11 +26,11 @@
} }
], ],
"url": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT", "url": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT",
"manifest": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT/raw/branch/{{branch}}/on-site-vtt/module.json",
"download": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT/releases/download/{{version}}/on-site-vtt.zip",
"bugs": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT/issues", "bugs": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT/issues",
"readme": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT/raw/branch/{{branch}}/README.md", "manifest": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT/releases/download/{{version}}/module.json",
"license": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT/raw/branch/{{branch}}/LICENSE.txt", "download": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT/releases/download/{{version}}/on-site-vtt.zip",
"readme": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT/releases/download/{{version}}/README.md",
"license": "https://gitea.aweleczka.de/aweleczka/On-Site-VTT/releases/download/{{version}}/LICENSE.txt",
"flags": { "flags": {
"allowBugReporter": true "allowBugReporter": true
}, },
@@ -40,4 +40,4 @@
"esmodules": [ "esmodules": [
"./scripts/on-site-vtt.js" "./scripts/on-site-vtt.js"
] ]
} }

View File

@@ -1,5 +1,5 @@
function inti() { function init() {
if (game.modules.get("on-site-vtt")?.active) { if (game.modules.get("on-site-vtt")?.active) {
console.log("on-site-vtt | Enabled"); console.log("on-site-vtt | Enabled");
@@ -23,6 +23,9 @@ function inti() {
} }
} }
function ready() {
console.log("on-site-vtt | Ready");
}
function rotateView() { function rotateView() {
if (document.getElementsByTagName("body")[0].className.includes("nsvRotate")) { if (document.getElementsByTagName("body")[0].className.includes("nsvRotate")) {
@@ -34,4 +37,5 @@ function rotateView() {
} }
} }
Hooks.on("init", init); Hooks.on("init", init);
Hooks.on("ready", ready);

View File

@@ -1,3 +1,3 @@
.nsvRotate { .nsvRotate {
rotate: 180deg; rotate: 180deg;
} }