3 Commits

Author SHA1 Message Date
dcaa4a7365 fix: await file check promises 2025-09-12 00:38:43 +02:00
3e48f9c97c fix: add options in action definition 2025-09-11 16:57:30 +02:00
8402546cf8 fix: change node version to 20 2025-09-11 15:43:41 +02:00
3 changed files with 13 additions and 5 deletions

View File

@@ -15,7 +15,15 @@ inputs:
description: The Minecraft version to use. If not specified or set to 'auto', will try to use the version indicated in `pack.mcmeta` description: The Minecraft version to use. If not specified or set to 'auto', will try to use the version indicated in `pack.mcmeta`
required: false required: false
default: 'auto' default: 'auto'
reportAllErrors:
description: Whether to report all errors or only the first one
required: false
default: 'false'
verbose:
description: Whether to provide details on errors or just the number of errors
required: false
default: 'false'
runs: runs:
using: 'node24' using: 'node20'
main: 'dist/index.js' main: 'dist/index.js'

4
dist/index.js vendored
View File

@@ -87625,7 +87625,7 @@ class CustomService extends Service {
`- Function: ${funcFiles.length}`); `- Function: ${funcFiles.length}`);
let success = true; let success = true;
for (const jsonFile of jsonFiles) { for (const jsonFile of jsonFiles) {
if (!this.checkFile(jsonFile, "json")) { if (!(await this.checkFile(jsonFile, "json"))) {
success = false; success = false;
if (!this.options.reportAllErrors) { if (!this.options.reportAllErrors) {
return false; return false;
@@ -87633,7 +87633,7 @@ class CustomService extends Service {
} }
} }
for (const funcFile of funcFiles) { for (const funcFile of funcFiles) {
if (!this.checkFile(funcFile, "mcfunction")) { if (!(await this.checkFile(funcFile, "mcfunction"))) {
success = false; success = false;
if (!this.options.reportAllErrors) { if (!this.options.reportAllErrors) {
return false; return false;

View File

@@ -166,7 +166,7 @@ export class CustomService extends core.Service {
) )
let success = true let success = true
for (const jsonFile of jsonFiles) { for (const jsonFile of jsonFiles) {
if (!this.checkFile(jsonFile, "json")) { if (!(await this.checkFile(jsonFile, "json"))) {
success = false success = false
if (!this.options.reportAllErrors) { if (!this.options.reportAllErrors) {
return false return false
@@ -174,7 +174,7 @@ export class CustomService extends core.Service {
} }
} }
for (const funcFile of funcFiles) { for (const funcFile of funcFiles) {
if (!this.checkFile(funcFile, "mcfunction")) { if (!(await this.checkFile(funcFile, "mcfunction"))) {
success = false success = false
if (!this.options.reportAllErrors) { if (!this.options.reportAllErrors) {
return false return false