generated from actions/typescript-action
-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
enhancementNew feature or requestNew feature or request
Description
When the issue #24 is merged, we will have JTD schema validation for the message body:
interface CommitBodyMetaData {
job_number?: number
job_commit?: string
}
interface CommitBodyData {
namespace: 'git-queue.commit-body'
version: number
metadata: CommitBodyMetaData
payload: string
}
const CommitBodySchema: JTDSchemaType<CommitBodyData> = {
properties: {
namespace: {enum: ['git-queue.commit-body']},
version: {type: 'int32'},
payload: {type: 'string'},
metadata: {
optionalProperties: {
job_number: {type: 'int32'},
job_commit: {type: 'string'}
},
additionalProperties: true
}
},
additionalProperties: true
}
This allows us to have an expressive description of the commit body, and make validations and parsings more robust and simple.
This methodology should be extended to the commit subject, that will store the queue message.
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request