3 Commits

Author SHA1 Message Date
07f224ff18 Relax type requirements on 'd' (data payload) field to improve type generation
All checks were successful
Generate and Release Protos / release (push) Successful in 29s
2026-02-19 21:05:33 +00:00
91e9432a07 Update to handle /v3 version
All checks were successful
Generate and Release Protos / release (push) Successful in 29s
2026-02-19 17:13:47 +00:00
50e2907f47 Update package.json values for output 2026-02-17 20:50:28 +00:00
2 changed files with 23 additions and 7 deletions

View File

@@ -59,9 +59,29 @@ jobs:
}' >> index.ts }' >> index.ts
VERSION="${{ steps.get_version.outputs.VERSION }}" VERSION="${{ steps.get_version.outputs.VERSION }}"
REPO_URL="${{ github.server_url }}/${{ github.repository }}.git"
jq --arg ver "$VERSION" \ jq --arg ver "$VERSION" \
--arg name "@owlboard/api-schema-types" \ --arg name "@owlboard/api-schema-types" \
'.name = $name | .version = $ver | .type = "module" | .main = "./dist/index.js" | .types = "./dist/index.d.ts"' \ --arg repo "$REPO_URL" \
'.name = $name |
.description = "TypeScript type definitions for OwlBoard API schemas" |
.author = "Frederick Boniface" |
.version = $ver |
.type = "module" |
.main = "./dist/index.js" |
.license = "MIT" |
.repository = { "type": "git", "url": $repo } |
.files = ["dist"] |
.sideEffects = false |
.dependencies = {} |
.devDependencies = {} |
.exports = {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.js"
}
} |
.types = "./dist/index.d.ts"' \
package.json > package.json.new && mv package.json.new package.json package.json > package.json.new && mv package.json.new package.json
# Compile # Compile
@@ -74,7 +94,7 @@ jobs:
- name: Publish Go - name: Publish Go
run: | run: |
VERSION="v${{ steps.get_version.outputs.VERSION }}" VERSION="v${{ steps.get_version.outputs.VERSION }}"
MOD_NAME="git.fjla.uk/owlboard/api-schema-types" MOD_NAME="git.fjla.uk/owlboard/api-schema-types/v3"
ZIP_ROOT="/tmp/go_upload" ZIP_ROOT="/tmp/go_upload"
FULL_PATH="$ZIP_ROOT/$MOD_NAME@$VERSION" FULL_PATH="$ZIP_ROOT/$MOD_NAME@$VERSION"

View File

@@ -11,11 +11,7 @@
"description": "Unix timestamp showing when the data was generated, or the time the error was encountered" "description": "Unix timestamp showing when the data was generated, or the time the error was encountered"
}, },
"d": { "d": {
"description": "Payload data. Type depends on request endpoint", "description": "Payload data. Type depends on request endpoint"
"anyOf": [
{"type": "object"},
{"type": "array"}
]
}, },
"e": { "e": {
"type": "object", "type": "object",