# GAMA Config
GAMA Config is used to load config stored inside the `.gama` folder.
## Install
* `pip install -e ./libs/gama_config`
* or...
* `pip install gama_config` (Public on [PyPi](https://pypi.org/project/gama-config/))
## Usage
### Reading config
```python
from gama_config.gama_vessel import read_vessel_config
from gama_config.gama_gs import read_gs_config
vessel_config = read_vessel_config()
gs_config = read_gs_config()
```
### Writing config
```python
from gama_config.gama_vessel import write_vessel_config, GamaVesselConfig
from gama_config.gama_gs import write_gs_config, GamaGsConfig
vessel_config = GamaVesselConfig()
gs_config = GamaGsConfig()
write_vessel_config(vessel_config)
write_gs_config(gs_config)
```
### Generating schemas
After changing the dataclasses, you can generate the schemas with:
```bash
python3 -m gama_config.generate_schemas
```
## Running tests
```bash
python3 -m pytest -v ./libs/gama_config
```
Raw data
{
"_id": null,
"home_page": "https://github.com/Greenroom-Robotics/gama",
"name": "gama-config",
"maintainer": "David Revay",
"docs_url": null,
"requires_python": null,
"maintainer_email": "david.revay@greenroomrobotics.com",
"keywords": "colcon",
"author": "Greenroom Robotics",
"author_email": "team@greenroomrobotics.com",
"download_url": "https://files.pythonhosted.org/packages/a7/d9/128d0c1ac38b8ab0ce1004e3a9e33a2eded06406c588afc27645d6f3cc1a/gama_config-2.3.0.tar.gz",
"platform": null,
"description": "# GAMA Config\n\nGAMA Config is used to load config stored inside the `.gama` folder.\n\n## Install\n\n* `pip install -e ./libs/gama_config`\n* or...\n* `pip install gama_config` (Public on [PyPi](https://pypi.org/project/gama-config/))\n\n## Usage\n\n### Reading config\n\n```python\nfrom gama_config.gama_vessel import read_vessel_config\nfrom gama_config.gama_gs import read_gs_config\n\nvessel_config = read_vessel_config()\ngs_config = read_gs_config()\n\n```\n\n### Writing config\n\n```python\nfrom gama_config.gama_vessel import write_vessel_config, GamaVesselConfig\nfrom gama_config.gama_gs import write_gs_config, GamaGsConfig\n\nvessel_config = GamaVesselConfig()\ngs_config = GamaGsConfig()\n\nwrite_vessel_config(vessel_config)\nwrite_gs_config(gs_config)\n\n```\n\n### Generating schemas\n\nAfter changing the dataclasses, you can generate the schemas with:\n\n```bash\npython3 -m gama_config.generate_schemas\n```\n\n## Running tests\n\n```bash\npython3 -m pytest -v ./libs/gama_config\n```\n",
"bugtrack_url": null,
"license": "Copyright (C) 2023, Greenroom Robotics",
"summary": "A library for reading / writing GAMA config files",
"version": "2.3.0",
"project_urls": {
"Homepage": "https://github.com/Greenroom-Robotics/gama"
},
"split_keywords": [
"colcon"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "7bd8ea051f9eb8d06e4eb0eb23d83d5298712e8f0d8aa1f1a46ee9c351c382f0",
"md5": "eef68fc76d7a7fd0c1dce868c664d2dc",
"sha256": "ccee16f1542d1ebac5375b3fe8e628d4241d44bf5127ab8616bca715798ed5ba"
},
"downloads": -1,
"filename": "gama_config-2.3.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "eef68fc76d7a7fd0c1dce868c664d2dc",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 13515,
"upload_time": "2024-04-16T22:15:03",
"upload_time_iso_8601": "2024-04-16T22:15:03.614508Z",
"url": "https://files.pythonhosted.org/packages/7b/d8/ea051f9eb8d06e4eb0eb23d83d5298712e8f0d8aa1f1a46ee9c351c382f0/gama_config-2.3.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "a7d9128d0c1ac38b8ab0ce1004e3a9e33a2eded06406c588afc27645d6f3cc1a",
"md5": "41d4974bbd2864d408af1e8a8d8b1789",
"sha256": "2778758dacb19061ff412cbac282a5ed8903e878bacae7dfccb6b3ca0e9bb2a2"
},
"downloads": -1,
"filename": "gama_config-2.3.0.tar.gz",
"has_sig": false,
"md5_digest": "41d4974bbd2864d408af1e8a8d8b1789",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 9907,
"upload_time": "2024-04-16T22:15:05",
"upload_time_iso_8601": "2024-04-16T22:15:05.043931Z",
"url": "https://files.pythonhosted.org/packages/a7/d9/128d0c1ac38b8ab0ce1004e3a9e33a2eded06406c588afc27645d6f3cc1a/gama_config-2.3.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-04-16 22:15:05",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "Greenroom-Robotics",
"github_project": "gama",
"github_not_found": true,
"lcname": "gama-config"
}