Config Key Validator
Project description
Gambas
Gambas is a config key validator. You can confirm the config file whether its keys all exist or not.
Generally, default.cfg
would be the standard for your config file. (Of course, you don't need to set default.cfg
as a standard file name.) And, you has a config file used on your project, but not upload on your git due to .gitignore
. I'll call it 'target config file'. Because it is a little bothering to sync two files, you sometimes might miss some keys.
Comparing two files' keys with Gambas, you can find the keys you missed of the target config file.
Getting Started
Built With
- Python >= 3.6.x
Installation
- Install Gambas with pip command
> pip install gambas
Usage
-
Prepare your 2 config files, default file and target file. The file extension is limited only on
cfg
,json
.# cfg file PSQL_HOST="127.0.0.1" PSQL_PORT="5432" PSQL_DBNAME="test_db" WEBHOOK_URL="http://webhook.url.com" ...
# json file { "psql_host": "127.0.0.1", "psql_port": "5432", "psql_dbname": "test_db", "webhook_url": "http://webhook.url.com", } ...
-
Execute the command with config files path.
-d
: the default config file-t
: the target config file
> gambas -d default_config.cfg -t target_config.cfg
You also can compare files with different extensions.
> gambas -d default_config.cfg -t target_json.json
-
If you don't want to let an error raise, execute the command with option
--no-error
. In this case, the warnig comes out instead of an error message.> gambas -d default_config.cfg -t target_config.cfg --no-error
Contact
- Chung Yunyoung - yy.chung@linewalks.com
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file gambas-0.0.2.tar.gz
.
File metadata
- Download URL: gambas-0.0.2.tar.gz
- Upload date:
- Size: 7.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.8.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0106ebad21f9c65f968046284beb0c814773086c444d4001e760a88851c7890b |
|
MD5 | 958e2c6e18c6400b00603a23659913f5 |
|
BLAKE2b-256 | 208daa48d4bee9b5e43c3523e3a156653621335d5f531fcfadc368d9663cbee4 |
File details
Details for the file gambas-0.0.2-py3-none-any.whl
.
File metadata
- Download URL: gambas-0.0.2-py3-none-any.whl
- Upload date:
- Size: 8.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.8.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1282f652501ea6fed6a80a8e587e216a49414df8f7736f8010f04920fb9e1c23 |
|
MD5 | 3a6f1427eb3654981e8d20f77cba693f |
|
BLAKE2b-256 | 660d7b77e7c37de197ea2f675a23d049f39c1210cb75009316bb51b76fa0482d |