Metadata-Version: 2.2
Name: viur-toolkit
Version: 0.2.5
Summary: A kit of helpers and tools to simplify more intensive use of ViUR
Author-email: Sven Eberth <se@mausbrand.de>
Maintainer-email: Sven Eberth <se@mausbrand.de>
License: MIT License
        
        Copyright (c) 2024 ViUR
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
        
Project-URL: Repository, https://github.com/viur-framework/viur-toolkit.git
Project-URL: Bug Tracker, https://github.com/viur-framework/viur-toolkit/issues
Keywords: viur,plugin,backend,toolkit
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: requests
Requires-Dist: Deprecated
Requires-Dist: viur-core>=3.6

<div align="center">
    <h1>viur-toolkit</h1>
    <a href="https://pypi.org/project/viur-toolkit/">
        <img alt="Badge showing current PyPI version" title="PyPI" src="https://img.shields.io/pypi/v/viur-toolkit">
    </a>
    <a href="LICENSE">
        <img src="https://img.shields.io/github/license/viur-framework/viur-toolkit" alt="Badge displaying the license" title="License badge">
    </a>
    <br>
    A kit of helpers and tools to simplify more intensive use of ViUR
</div>

## Usage

### Install with pip
```
pip install viur-toolkit
```

### Install with pipenv
```
pipenv install viur-toolkit
```

### Example
```python
from viur import toolkit

if toolkit.user_has_access("root"):
    print("Hello root user!")
```


## Development / Contributing

Create a fork and clone it

### Setup the local environment with pipenv:
```sh
cd viur-toolkit
pipenv install --dev
pipenv run precommit_install
```

### Install as editable in your project
```sh
cd myproject
pipenv install -e path/to/viur-toolkit
```

### Code linting & type checking
Use the `lint` command
```sh
$ pipenv run lint
```
tu run `pep8check` and `type_check` at once.

#### Alternative:
Setup the pre-commit hook with `pipenv run precommit_install`.

### Branches
Depending on what kind of change your Pull Request contains, please submit your PR against the following branches:

* **main:**
  fixes/patches that fix a problem with existing code go into this branch.
  This results in a new patch version (X.X.n+1 where n is the current patch-level).
* **develop:**
  new features, refactorings, or adjustments for new versions of dependencies are added to this branch.
  This becomes a new minor version (X.n+1.0) where n is the current minor-level).
  Depending on the complexity of the changes, a new major release (n+1.0.0, where n is the current major level) may be chosen instead.
