A module for parsing and discovery of frigg settings file
Project description
# frigg-settings [![Build status](https://ci.frigg.io/badges/frigg/frigg-settings/)](https://ci.frigg.io/frigg/frigg-settings/last/) [![Coverage status](https://ci.frigg.io/badges/coverage/frigg/frigg-settings/)](https://ci.frigg.io/frigg/frigg-settings/last/)
A python module for parsing and discovery of frigg settings file
## Installation
```
pip install frigg-settings
```
## Usage
The same content as t.py, thus run `python t.py` to se the output.
```python
from frigg_settings.helpers import FileSystemWrapper
from frigg_settings import build_tasks, load_settings_file, build_settings
path = os.getcwd()
runner = FileSystemWrapper()
print('Tasks: {}'.format(build_tasks(path, runner)))
print('Settings-file: {}'.format(load_settings_file('{}/.frigg.yml'.format(path), runner)))
print('Build-settings: {}'.format(build_settings(path, runner)))
```
The script prints the following:
```text
Tasks: ['tox', 'flake8']
Settings-file: {'tasks': ['tox -e py34', 'tox -e flake8', 'tox -e isort', 'coverage report -m && coverage xml'], 'coverage': {'parser': 'python', 'path': 'coverage.xml'}}
Build-settings: {'webhooks': [], 'services': [], 'tasks': ['tox -e py34', 'tox -e flake8', 'tox -e isort', 'coverage report -m && coverage xml'], 'coverage': {'parser': 'python', 'path': 'coverage.xml'}}
```
--------------
MIT © frigg.io
A python module for parsing and discovery of frigg settings file
## Installation
```
pip install frigg-settings
```
## Usage
The same content as t.py, thus run `python t.py` to se the output.
```python
from frigg_settings.helpers import FileSystemWrapper
from frigg_settings import build_tasks, load_settings_file, build_settings
path = os.getcwd()
runner = FileSystemWrapper()
print('Tasks: {}'.format(build_tasks(path, runner)))
print('Settings-file: {}'.format(load_settings_file('{}/.frigg.yml'.format(path), runner)))
print('Build-settings: {}'.format(build_settings(path, runner)))
```
The script prints the following:
```text
Tasks: ['tox', 'flake8']
Settings-file: {'tasks': ['tox -e py34', 'tox -e flake8', 'tox -e isort', 'coverage report -m && coverage xml'], 'coverage': {'parser': 'python', 'path': 'coverage.xml'}}
Build-settings: {'webhooks': [], 'services': [], 'tasks': ['tox -e py34', 'tox -e flake8', 'tox -e isort', 'coverage report -m && coverage xml'], 'coverage': {'parser': 'python', 'path': 'coverage.xml'}}
```
--------------
MIT © frigg.io
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
frigg-settings-3.0.0.tar.gz
(4.6 kB
view details)
Built Distribution
File details
Details for the file frigg-settings-3.0.0.tar.gz
.
File metadata
- Download URL: frigg-settings-3.0.0.tar.gz
- Upload date:
- Size: 4.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3c738e3513e935958d018168b1289011ccf7fd607af04238ca279d6d4d5a47a5 |
|
MD5 | 12c50c9d4d8ae093eef74da7cd5ec716 |
|
BLAKE2b-256 | 367bfdd472cd8acf78953168b6573866b0b8d5a46deb298f22569786c5b1e010 |
File details
Details for the file frigg_settings-3.0.0-py2.py3-none-any.whl
.
File metadata
- Download URL: frigg_settings-3.0.0-py2.py3-none-any.whl
- Upload date:
- Size: 5.9 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 247c59085d8271366a77deea256e2a0c5570f1c0c6f2a405386ea95bf893c197 |
|
MD5 | 3b5ca980c65439da80f3365aea3fd418 |
|
BLAKE2b-256 | 1ba7b46bbe07fbdb7ed7ee4094fe6c9b56bfb4513d41ab34e54a2a7671539fda |