feature: every write of an instance's variable files is kept as a revision with the schema version of their layout and the application that wrote them.
Release / release (push) Successful in 1m8s

This commit is contained in:
slawek committed 2026-11-06 22:22:35 +01:00
1 parent 7c335c7ed2
commit 5e62e143b6
11 files changed
+286 -37

No files matched your search

+1 -1
View File
@@ -1,3 +1,3 @@
export type { CredentialField, CredentialKind, CredentialProfile, CredentialsDocument } from './credentials.ts'
export type { TfInstance, TfModule, TfvarsFileStatus } from './tfvars.ts'
export type { TfInstance, TfModule, TfvarsFileStatus, TfvarsRevision } from './tfvars.ts'
export { STATE_SCHEMA_PATTERN, TFVARS_FILE_PATTERN, TF_NAME_PATTERN } from './tfvars.ts'
+14
View File
@@ -26,6 +26,20 @@ export type TfvarsFileStatus = {
previous: boolean
}
/** A write of an instance's variable files, without their content. */
export type TfvarsRevision = {
/** The number of the write, from 1 for each instance. */
revision: number
/** The schema version of the files' layout, as their producer gave it; null when not known. */
schema: number | null
/** The application that wrote the files, with its version. */
producer: string
/** ISO 8601. */
saved: string
/** The names of the files of the revision. */
names: string[]
}
/** The names of modules and instances: a lower-case letter, then lower-case letters, digits and hyphens. */
export const TF_NAME_PATTERN = /^[a-z][a-z0-9-]*$/