Skip to content
Permalink
Browse files

Merge pull request #3023 from PhilippGackstatter/kdb_naming_scheme

Rename KDB commands
  • Loading branch information...
markus2330 committed Oct 6, 2019
2 parents 1c26661 + 144ba82 commit 704812a1841a02cbb4be06256cbc03d9342d841d
Showing with 437 additions and 678 deletions.
  1. +3 −3 doc/CONTRACT.ini
  2. +1 −1 doc/api_blueprints/elektrad.apib
  3. +1 −1 doc/api_blueprints/webd.apib
  4. +1 −1 doc/decisions/plugin_variants.md
  5. +1 −1 doc/help/elektra-cascading.md
  6. +2 −2 doc/help/elektra-metadata.md
  7. +1 −1 doc/help/kdb-check-env-dep.md
  8. +2 −2 doc/help/kdb-editor.md
  9. +1 −1 doc/help/kdb-export.md
  10. +1 −1 doc/help/kdb-file.md
  11. +0 −40 doc/help/kdb-fstab.md
  12. +1 −1 doc/help/kdb-get.md
  13. +1 −1 doc/help/kdb-import.md
  14. +5 −5 doc/help/{kdb-getmeta.md → kdb-meta-get.md}
  15. +3 −3 doc/help/{kdb-lsmeta.md → kdb-meta-ls.md}
  16. +3 −3 doc/help/{kdb-rmmeta.md → kdb-meta-rm.md}
  17. +7 −7 doc/help/{kdb-setmeta.md → kdb-meta-set.md}
  18. +11 −11 doc/help/{kdb-showmeta.md → kdb-meta-show.md}
  19. +2 −2 doc/help/kdb-mount.md
  20. +8 −8 doc/help/{kdb-check.md → kdb-plugin-check.md}
  21. +5 −5 doc/help/{kdb-info.md → kdb-plugin-info.md}
  22. +5 −5 doc/help/{kdb-list.md → kdb-plugin-list.md}
  23. +1 −1 doc/help/kdb-spec-mount.md
  24. +1 −1 doc/help/kdb-vset.md
  25. +4 −4 doc/help/kdb.md
  26. +5 −5 doc/man/man1/kdb-elektrify-getenv.1
  27. +1 −1 doc/man/man1/kdb-file.1
  28. +0 −70 doc/man/man1/kdb-fstab.1
  29. +1 −1 doc/man/man1/kdb-get.1
  30. +5 −5 doc/man/man1/{kdb-getmeta.1 → kdb-meta-get.1}
  31. +4 −4 doc/man/man1/{kdb-lsmeta.1 → kdb-meta-ls.1}
  32. +4 −4 doc/man/man1/{kdb-rmmeta.1 → kdb-meta-rm.1}
  33. +7 −7 doc/man/man1/{kdb-setmeta.1 → kdb-meta-set.1}
  34. +8 −8 doc/man/man1/{kdb-showmeta.1 → kdb-meta-show.1}
  35. +2 −2 doc/man/man1/kdb-mount.1
  36. +7 −7 doc/man/man1/{kdb-check.1 → kdb-plugin-check.1}
  37. +6 −6 doc/man/man1/{kdb-info.1 → kdb-plugin-info.1}
  38. +6 −6 doc/man/man1/{kdb-list.1 → kdb-plugin-list.1}
  39. +1 −1 doc/man/man1/kdb-spec-mount.1
  40. +1 −1 doc/man/man1/kdb-vset.1
  41. +3 −3 doc/man/man1/kdb.1
  42. +1 −1 doc/man/man7/elektra-cascading.7
  43. +9 −2 doc/news/_preparation_next_release.md
  44. +1 −1 doc/todo/MARKETING
  45. +1 −1 doc/todo/PLUGINS
  46. +1 −1 doc/todo/TOOLS
  47. +3 −3 doc/tutorials/application-integration.md
  48. +4 −4 doc/tutorials/arrays.md
  49. +1 −1 doc/tutorials/cascading.md
  50. +1 −1 doc/tutorials/contributing-clion.md
  51. +4 −4 doc/tutorials/crypto.md
  52. +9 −9 doc/tutorials/mount.md
  53. +8 −8 doc/tutorials/storage-plugins.md
  54. +17 −17 doc/tutorials/validation.md
  55. +3 −3 examples/codegen/menu/README.md
  56. +1 −1 scripts/CMakeLists.txt
  57. +1 −1 scripts/change-resolver-symlink.in
  58. +1 −1 scripts/change-storage-symlink.in
  59. +4 −4 scripts/completion/kdb.fish
  60. +6 −6 scripts/completion/kdb_zsh_completion
  61. +9 −9 scripts/configure-firefox.in
  62. +1 −1 scripts/ffconfig/setupProxy
  63. 0 scripts/{ → kdb}/mountpoint-info
  64. +5 −5 src/bindings/intercept/env/README.md
  65. +1 −1 src/bindings/swig/ruby/examples/tools/kdb_simple.rb
  66. +2 −2 src/libs/highlevel/README.md
  67. +1 −1 src/libs/tools/include/toolexcept.hpp
  68. +3 −3 src/plugins/README.md
  69. +1 −1 src/plugins/base64/README.md
  70. +3 −3 src/plugins/conditionals/README.md
  71. +13 −11 src/plugins/conditionals/conditionals.c
  72. +1 −1 src/plugins/counter/README.md
  73. +1 −1 src/plugins/crypto/README.md
  74. +1 −1 src/plugins/directoryvalue/README.md
  75. +2 −2 src/plugins/error/README.md
  76. +2 −2 src/plugins/file/README.md
  77. +1 −1 src/plugins/gpgme/README.md
  78. +4 −4 src/plugins/hexnumber/README.md
  79. +1 −1 src/plugins/hosts/README.md
  80. +8 −8 src/plugins/ini/README.md
  81. +1 −1 src/plugins/ini/ini.c
  82. +2 −2 src/plugins/ipaddr/README.md
  83. +2 −2 src/plugins/jni/README.md
  84. +4 −4 src/plugins/macaddr/README.md
  85. +3 −3 src/plugins/mathcheck/README.md
  86. +1 −1 src/plugins/mini/README.md
  87. +2 −2 src/plugins/mmapstorage/README.md
  88. +3 −3 src/plugins/mozprefs/README.md
  89. +4 −4 src/plugins/mozprefs/autoconfig/README.md
  90. +2 −2 src/plugins/network/README.md
  91. +5 −5 src/plugins/ni/README.md
  92. +6 −6 src/plugins/path/README.md
  93. +3 −3 src/plugins/quickdump/README.md
  94. +2 −2 src/plugins/range/README.md
  95. +1 −1 src/plugins/reference/README.md
  96. +2 −2 src/plugins/rgbcolor/README.md
  97. +3 −3 src/plugins/ruby/ruby.cpp
  98. +3 −3 src/plugins/spec/README.md
  99. +4 −4 src/plugins/specload/README.md
  100. +2 −2 src/plugins/tcl/README.md
  101. +1 −1 src/plugins/timeofday/README.md
  102. +1 −1 src/plugins/tracer/README.md
  103. +15 −15 src/plugins/type/README.md
  104. +4 −4 src/plugins/xerces/README.md
  105. +4 −4 src/plugins/yajl/README.md
  106. +1 −1 src/plugins/yambi/README.md
  107. +15 −15 src/plugins/yamlcpp/README.md
  108. +2 −2 src/plugins/yanlr/README.md
  109. +11 −13 src/tools/kdb/factory.hpp
  110. +0 −82 src/tools/kdb/fstab.cpp
  111. +0 −57 src/tools/kdb/fstab.hpp
  112. +2 −1 src/tools/kdb/mount.cpp
  113. +4 −4 src/tools/kdb/{check.cpp → plugincheck.cpp}
  114. +3 −3 src/tools/kdb/{check.hpp → plugincheck.hpp}
  115. +4 −4 src/tools/kdb/{info.cpp → plugininfo.cpp}
  116. +5 −5 src/tools/kdb/{info.hpp → plugininfo.hpp}
  117. +4 −4 src/tools/kdb/{list.cpp → pluginlist.cpp}
  118. +3 −3 src/tools/kdb/{list.hpp → pluginlist.hpp}
  119. +1 −1 tests/shell/check_error.sh
  120. +2 −2 tests/shell/check_kdb_internal_check.sh
  121. +6 −6 tests/shell/check_merge.sh
  122. +1 −1 tests/shell/check_spec.sh
  123. +1 −1 tests/shell/external/example_codegen_econf.sh
  124. +3 −3 tests/shell/external/example_codegen_menu.sh
  125. +4 −4 tests/shell/external/example_codegen_tree.sh
  126. +2 −2 tests/shell/external/example_highlevel.sh
  127. +1 −1 tests/shell/gen/highlevel/externalspec.check.sh
  128. +1 −1 tests/shell/gen/highlevel/externalwithdefaults.check.sh
  129. +1 −1 tests/shell/gen/highlevel/nosetter.check.sh
  130. +1 −1 tests/shell/gen/highlevel/simple.check.sh
  131. +1 −1 tests/shell/include_common.sh.in
  132. +8 −8 tests/shell/shell_recorder/mathcheck.esr
  133. +1 −1 tests/shell/shell_recorder/script.esr
  134. +1 −1 tests/shell/shell_recorder/tutorial_wrapper/CMakeLists.txt
@@ -8,7 +8,7 @@ description = This part of the hierarchy specifies the semantics of a
- src/libtools/src/plugin.cpp (validator of this specification)
- src/libtools/src/plugins.cpp (placements)
- cmake/Modules/LibAddMacros.cmake (for README.md conversion)
Use "kdb check" to validate.
Use "kdb plugin-check" to validate.
In doubt this specification overrules other specifications.
It is allowed to export additional keys (below the plugins module
name). They might, however, someday conflict with the specification
@@ -360,7 +360,7 @@ description = Exports a plugin configuration needed by another plugin. All keys
[infos/environment]
type = string
status = PROPOSED
usedby = plugin kdb-info
usedby = plugin kdb-plugin-info
example = HOME USER
description = List all environment variables the plugin
may access.
@@ -373,7 +373,7 @@ description = List all environment variables the plugin
[infos/dependencies/_]
type = string
status = PROPOSED
usedby = plugin kdb-info
usedby = plugin kdb-plugin-info
example = libyajl-dev
description = The list of dependencies a plugin has for
a specific package management system (like deb, rpm,
@@ -31,7 +31,7 @@ access the elektra key database by specifying a `path`

### get configuration [GET]

this actually does `kdb get`, `kdb ls` and `kdb lsmeta`/`kdb getmeta` at once and is used to browse the kdb
this actually does `kdb get`, `kdb ls` and `kdb meta-ls`/`kdb meta-get` at once and is used to browse the kdb

+ Request
+ Parameters
@@ -121,7 +121,7 @@ if the `INSTANCE` env var is used, webd creates a virtual instance with the id `
### get configuration [GET]

get the content and subkeys of the specified `path` in the elektra key database
this actually does `kdb get`, `kdb ls` and `kdb lsmeta`/`kdb getmeta` at once and is used to browse the kdb
this actually does `kdb get`, `kdb ls` and `kdb meta-ls`/`kdb meta-get` at once and is used to browse the kdb

+ Request
+ Parameters
@@ -142,7 +142,7 @@ system/elektra/plugins/simpleini/variants/spacesep/config/format = "% %"
- python
- python2
- `PluginDatabase` needs an extension to list all plugin variants
- `kdb list` should be able to list all variants, e.g. like:
- `kdb plugin-list` should be able to list all variants, e.g. like:
`augeas lens=Access.lns`
so that a user can copy and paste this for the `kdb mount` command.

@@ -35,7 +35,7 @@ They can be used like this:

```sh
kdb set /overrides/test "example override"
sudo kdb setmeta spec/test override/#0 /overrides/test
sudo kdb meta-set spec/test override/#0 /overrides/test
```

## CASCADING
@@ -65,8 +65,8 @@ Every key-value pair can have an arbitrary number of metakeys
with metavalues attached. Identical to keys, metakeys are
unique, but only within its key they are attached to.

To create a metakey, use [kdb-setmeta(1)](kdb-setmeta.md),
to get metadata [kdb-getmeta(1)](kdb-getmeta.md).
To create a metakey, use [kdb-meta-set(1)](kdb-meta-set.md),
to get metadata [kdb-meta-get(1)](kdb-meta-get.md).

The preferred way to use metadata is to set all metadata
in the `spec` namespace and let the `spec` plugin copy
@@ -1,4 +1,4 @@
# kdb-check-env-dep -- Checks which mount points are influenced by environment variables
# kdb-plugin-check-env-dep -- Checks which mount points are influenced by environment variables

## SYNOPSIS

@@ -8,8 +8,8 @@ Where `path` is the destination where the user wants to edit keys and `format` i
If the `format` argument is not passed, then the default format will be used as determined by the value of the `sw/kdb/current/format` key.
By default, that key contains `storage`.
The `storage` plugin can be configured at compile-time or changed by the link `libelektra-storage.so`.
The `format` attribute relies on Elektra’s plugin system to properly import the configuration. The user can view all plugins available for use by running the kdb-list(1) command.
To learn about any plugin, the user can simply use the kdb-info(1) command.
The `format` attribute relies on Elektra’s plugin system to properly import the configuration. The user can view all plugins available for use by running the kdb-plugin-list(1) command.
To learn about any plugin, the user can simply use the kdb-plugin-info(1) command.

## DESCRIPTION

@@ -14,7 +14,7 @@ This command can also be used to view full key(s) including their values.<br>

Where `source` is the path of the key(s) you want to export.
Additionally, the user can specify a format to use by passing it as the option argument `format`.<br>
The `format` attribute relies on Elektra’s plugin system to export the keys in the desired format.The user can view all plugins available for use by running the kdb-list(1) command. To learn about any plugin, the user can simply use the kdb-info(1) command.<br>
The `format` attribute relies on Elektra’s plugin system to export the keys in the desired format.The user can view all plugins available for use by running the kdb-plugin-list(1) command. To learn about any plugin, the user can simply use the kdb-plugin-info(1) command.<br>
The `storage` plugin can be configured at compile-time or changed by the link `libelektra-storage.so`.

## OPTIONS
@@ -11,7 +11,7 @@ Where `key name` is the name of the key to check.<br>
This command prints which file a given key is stored in.<br>
While many keys are stored in a default key database file, many others are stored in any number of configuration files located all over the system.<br>
This tool is made to allow users to find out the file that a key is actually stored in.<br>
This command makes use of Elektra’s `resolver` plugin which the uer can learn more about by running the command `kdb info resolver`.
This command makes use of Elektra’s `resolver` plugin which the uer can learn more about by running the command `kdb plugin-info resolver`.

## OPTIONS

This file was deleted.

@@ -63,7 +63,7 @@ sudo kdb mount get.ecf spec/tests/get/examples/kdb-get dump
# Create the keys we use for the examples
kdb set user/tests/get/examples/kdb-get/key myKey
kdb setmeta /tests/get/examples/kdb-get/anotherKey default defaultValue
kdb meta-set /tests/get/examples/kdb-get/anotherKey default defaultValue
# To get the value of a key:
kdb get user/tests/get/examples/kdb-get/key
@@ -10,7 +10,7 @@ Where `destination` is the destination where the user wants the keys to be impor
## DESCRIPTION

If the `format` argument is not passed, then the default format will be used as determined by the value of the `sw/kdb/current/format` key. By default, that key is set to the `storage` format.
The `format` attribute relies on Elektra’s plugin system to properly import the configuration. The user can view all plugins available for use by running the kdb-list(1) command. To learn about any plugin, the user can simply use the kdb-info(1) command.
The `format` attribute relies on Elektra’s plugin system to properly import the configuration. The user can view all plugins available for use by running the kdb-plugin-list(1) command. To learn about any plugin, the user can simply use the kdb-plugin-info(1) command.

This command allows a user to import an existing configuration into the key database.
The configuration that the user wants to import is read from `stdin`.
@@ -1,8 +1,8 @@
# kdb-getmeta(1) -- Get the value of a metakey stored in the key database
# kdb-meta-get(1) -- Get the value of a metakey stored in the key database

## SYNOPSIS

`kdb getmeta <key name> <metaname>`<br>
`kdb meta-get <key name> <metaname>`<br>

Where `key name` is the name of the key and
`metaname` is the name of the metakey the user would like to access.
@@ -46,14 +46,14 @@ This command will return the following values as an exit status:<br>
## EXAMPLES

To get the value of a metakey called `description` stored in the key `spec/example/key`:<br>
`kdb getmeta spec/example/key description`
`kdb meta-get spec/example/key description`

To get the value of metakey called `override/#0` stored in the key `spec/example/dir/key`:<br>
`kdb getmeta spec/example/dir/key "override/#0"`
`kdb meta-get spec/example/dir/key "override/#0"`

## SEE ALSO

- How to set metadata: [kdb-setmeta(1)](kdb-setmeta.md)
- How to set metadata: [kdb-meta-set(1)](kdb-meta-set.md)
- For more about cascading keys see [elektra-cascading(7)](elektra-cascading.md)
- [elektra-metadata(7)](elektra-metadata.md) for an explanation of the metadata concepts.
- [elektra-key-names(7)](elektra-key-names.md) for an explanation of key names.
@@ -1,8 +1,8 @@
# kdb-lsmeta(1) - Print metakeys associated with a key
# kdb-meta-ls(1) - Print metakeys associated with a key

## SYNOPSIS

`kdb lsmeta <key name>`
`kdb meta-ls <key name>`

Where `key name` is the name of the key.

@@ -31,7 +31,7 @@ If no metakeys are associated with the given key, nothing will be printed.<br>
## EXAMPLE

To see which metakeys are associated with a key:<br>
`kdb lsmeta /example/key`
`kdb meta-ls /example/key`

## SEE ALSO

@@ -1,8 +1,8 @@
# kdb-rmmeta(1) -- Remove metakey of a key from the key database
# kdb-meta-rm(1) -- Remove metakey of a key from the key database

## SYNOPSIS

`kdb rmmeta <key name> <metaname>`
`kdb meta-rm <key name> <metaname>`

Where `key name` is the name of the key and `metaname` is the name of the metakey you want to remove.

@@ -28,7 +28,7 @@ This command removes a metakey of a key from the Key database.
## EXAMPLES

To remove metakey `metakey` of a key:<br>
`kdb rmmeta user/example metakey`
`kdb meta-rm user/example metakey`

## SEE ALSO

@@ -1,8 +1,8 @@
# kdb-setmeta(1) -- Set the value of a metakey
# kdb-meta-set(1) -- Set the value of a metakey

## SYNOPSIS

`kdb setmeta <key name> <metaname> [<metavalue>]`
`kdb meta-set <key name> <metaname> [<metavalue>]`

Where `key name` is the name of the key that the metakey is associated with,
`metaname` is the name of the metakey the user would like to set the value of (or create),
@@ -51,27 +51,27 @@ that is the place where you usually want to set metadata.
## EXAMPLES

To set a metakey called `description` associated with the key `user/example/key` to the value `Hello World!`:<br>
`kdb setmeta spec/example/key description "Hello World!"`
`kdb meta-set spec/example/key description "Hello World!"`

To create a new key `spec/example/newkey` with a null value (if it did not exist before)
and a metakey `namespace/#0` associated with it to the value `system`:<br>
`kdb setmeta /example/newkey "namespace/#0" system`
`kdb meta-set /example/newkey "namespace/#0" system`

To create an override link for a `/test` key:

```sh
kdb set /overrides/test "example override"
sudo kdb setmeta spec/test override/#0 /overrides/test
sudo kdb meta-set spec/test override/#0 /overrides/test
```

To remove it:

```sh
sudo kdb setmeta spec/test override/#0
sudo kdb meta-set spec/test override/#0
```

## SEE ALSO

- How to get metadata: [kdb-getmeta(1)](kdb-getmeta.md)
- How to get metadata: [kdb-meta-get(1)](kdb-meta-get.md)
- [elektra-metadata(7)](elektra-metadata.md) for an explanation of the metadata concepts.
- [elektra-key-names(7)](elektra-key-names.md) for an explanation of key names.
@@ -1,8 +1,8 @@
# kdb-showmeta(1) -- Print all metakeys along with their value
# kdb-meta-show(1) -- Print all metakeys along with their value

## SYNOPSIS

`kdb showmeta <key name>`<br>
`kdb meta-show <key name>`<br>

Where `key name` is the name of the key the user would like to access.

@@ -47,14 +47,14 @@ This command will return the following values as an exit status:<br>
sudo kdb mount ls.ecf user/tests/examples dump
# Create the keys we use for the examples
kdb set user/tests/examples/kdb-showmeta test
kdb setmeta user/tests/examples/kdb-showmeta meta1 val1
kdb setmeta user/tests/examples/kdb-showmeta meta2 val2
kdb setmeta user/tests/examples/kdb-showmeta meta3 val3
kdb setmeta user/tests/examples/kdb-showmeta meta4 val4
# list all meta keys for /tests/examples/kdb-showmeta
kdb showmeta /tests/examples/kdb-showmeta
kdb set user/tests/examples/kdb-meta-show test
kdb meta-set user/tests/examples/kdb-meta-show meta1 val1
kdb meta-set user/tests/examples/kdb-meta-show meta2 val2
kdb meta-set user/tests/examples/kdb-meta-show meta3 val3
kdb meta-set user/tests/examples/kdb-meta-show meta4 val4
# list all meta keys for /tests/examples/kdb-meta-show
kdb meta-show /tests/examples/kdb-meta-show
#> meta1: val1
#> meta2: val2
#> meta3: val3
@@ -66,7 +66,7 @@ sudo kdb umount user/tests/examples

## SEE ALSO

- How to set metadata: [kdb-setmeta(1)](kdb-setmeta.md)
- How to set metadata: [kdb-meta-set(1)](kdb-meta-set.md)
- For more about cascading keys see [elektra-cascading(7)](elektra-cascading.md)
- [elektra-metadata(7)](elektra-metadata.md) for an explanation of the metadata concepts.
- [elektra-key-names(7)](elektra-key-names.md) for an explanation of key names.
@@ -5,7 +5,7 @@
`kdb mount [<path> <mount point>] [<plugin> [<config>] [..]]`<br>

- Where `path` is the path to the file the user wants to mount.
See `kdb info resolver` for details what an absolute and relative path means.
See `kdb plugin-info resolver` for details what an absolute and relative path means.
See also IMPORTANT below.

- `mountpoint` is where in the key database the new backend should be mounted.
@@ -31,7 +31,7 @@ Additionally, the user can use this command to list the currently mounted backen
This command writes into the `/etc` directory and as such it requires root permissions.
Use `kdb file system/elektra/mountpoints` to find out where exactly it will write to.

Absolute paths are still relative to their namespace (see `kdb info resolver`).
Absolute paths are still relative to their namespace (see `kdb plugin-info resolver`).
Only system+spec mount points are actually absolute.
Read [elektra-namespaces(7)](elektra-namespaces.md) for further information.

@@ -1,8 +1,8 @@
# kdb-check(1) -- Perform internal checks
# kdb-plugin-check(1) -- Perform internal checks

## SYNOPSIS

`kdb check [<plugin>]`
`kdb plugin-check [<plugin>]`

## DESCRIPTION

@@ -95,22 +95,22 @@ If the user wants to have the value printed, they must do so manually (by runnin
## EXAMPLES

To check the Key Database:<br>
`kdb check`
`kdb plugin-check`

To check the Key Database and then print the result:<br>
`kdb check`
`kdb plugin-check`
followed by:<br>
`echo $?`

To check the Key Database including write checks:<br>
`kdb check -f`
`kdb plugin-check -f`
Note that this type of check may change configuration files.

To check the `line` plugin:<br>
`kdb check line`
`kdb plugin-check line`

## SEE ALSO

- For an introductions into plugins, read [elektra-plugins](/src/plugins).
- To list all plugins use [kdb-list(1)](kdb-list.md).
- For information on a plugin use [kdb-info(1)](kdb-info.md).
- To list all plugins use [kdb-plugin-list(1)](kdb-plugin-list.md).
- For information on a plugin use [kdb-plugin-info(1)](kdb-plugin-info.md).

0 comments on commit 704812a

Please sign in to comment.
You can’t perform that action at this time.