From 45d8d7eaf963eedc40258bb5c136d7910ee563e6 Mon Sep 17 00:00:00 2001 From: Patrick Pacher Date: Tue, 20 Oct 2020 12:40:20 +0200 Subject: [PATCH] Add StackableAnnotation and update wording --- api/config.go | 2 +- config/expertise.go | 6 +++--- config/option.go | 6 ++++++ config/release.go | 2 +- template/module.go | 2 +- 5 files changed, 12 insertions(+), 6 deletions(-) diff --git a/api/config.go b/api/config.go index 2e7c079..c373b3f 100644 --- a/api/config.go +++ b/api/config.go @@ -41,7 +41,7 @@ func registerConfig() error { err := config.Register(&config.Option{ Name: "API Address", Key: CfgDefaultListenAddressKey, - Description: "Define on which IP and port the API should listen on.", + Description: "Defines the IP address and port for the internal HTTP database API.", OptType: config.OptTypeString, ExpertiseLevel: config.ExpertiseLevelDeveloper, ReleaseLevel: config.ReleaseLevelStable, diff --git a/config/expertise.go b/config/expertise.go index bc83c32..7d7798b 100644 --- a/config/expertise.go +++ b/config/expertise.go @@ -41,7 +41,7 @@ func registerExpertiseLevelOption() { expertiseLevelOption = &Option{ Name: "Expertise Level", Key: expertiseLevelKey, - Description: "The Expertise Level controls the perceived complexity. Higher settings will show you more complex settings and information. This might also affect various other things relying on this setting. Modified settings in higher expertise levels stay in effect when switching back. (Unlike the Release Level)", + Description: "The Expertise Level controls the perceived complexity. Higher settings will enable more complex settings and information. This might also affect various other things relying on this setting. Modified settings in higher expertise levels stay in effect when switching back. (Unlike the Release Level)", OptType: OptTypeString, ExpertiseLevel: ExpertiseLevelUser, ReleaseLevel: ReleaseLevelStable, @@ -52,9 +52,9 @@ func registerExpertiseLevelOption() { }, PossibleValues: []PossibleValue{ { - Name: "Easy", + Name: "Simple", Value: ExpertiseLevelNameUser, - Description: "Easy application mode by hidding complex settings.", + Description: "Simple application mode by hidding complex settings.", }, { Name: "Expert", diff --git a/config/option.go b/config/option.go index 260d17c..5e7191b 100644 --- a/config/option.go +++ b/config/option.go @@ -84,6 +84,12 @@ const ( // SubsystemAnnotation can be used to mark an option as part // of a module subsystem. SubsystemAnnotation = "safing/portbase:module:subsystem" + // StackableAnnotation can be set on configuration options that + // stack on top of the default (or otherwise related) options. + // The value of StackableAnnotaiton is expected to be a boolean but + // may be extended to hold references to other options in the + // future. + StackableAnnotation = "safing/portbase:options:stackable" // QuickSettingAnnotation can be used to add quick settings to // a configuration option. A quick setting can support the user // by switching between pre-configured values. diff --git a/config/release.go b/config/release.go index 965ef14..ec70293 100644 --- a/config/release.go +++ b/config/release.go @@ -39,7 +39,7 @@ func registerReleaseLevelOption() { releaseLevelOption = &Option{ Name: "Release Level", Key: releaseLevelKey, - Description: "The Release Level changes which features are available to you. Some beta or experimental features are also available in the stable release channel. Unavailable settings are set to the default value.", + Description: "The Release Level changes which features are available. Some beta or experimental features are also available in the stable release channel. Unavailable settings are set to the default value.", OptType: OptTypeString, ExpertiseLevel: ExpertiseLevelExpert, ReleaseLevel: ReleaseLevelStable, diff --git a/template/module.go b/template/module.go index fa38ec0..72097ad 100644 --- a/template/module.go +++ b/template/module.go @@ -30,7 +30,7 @@ func init() { module, "config:template", // key space for configuration options registered &config.Option{ - Name: "Enable Template Subsystem", + Name: "Template Subsystem", Key: "config:subsystems/template", Description: "This option enables the Template Subsystem [TEMPLATE]", OptType: config.OptTypeBool,