summaryrefslogtreecommitdiff
path: root/config/version.go
diff options
context:
space:
mode:
Diffstat (limited to 'config/version.go')
-rw-r--r--config/version.go12
1 files changed, 12 insertions, 0 deletions
diff --git a/config/version.go b/config/version.go
new file mode 100644
index 0000000..4a145fd
--- /dev/null
+++ b/config/version.go
@@ -0,0 +1,12 @@
+package config
+
+// CurrentVersion declares the currently supported config version.
+//
+const CurrentVersion string = "v1"
+
+// VersionConfig contains a single field that allows for validation of the
+// config version independent from an entire Config struct.
+//
+type VersionConfig struct {
+ Version string `yaml:"version" validate:"required,currentversion"`
+}