Metadata-Version: 2.4
Name: pyright-to-gitlab
Version: 1.0.1
Summary: Convert Pyright JSON output to GitLab CI/CD format
Author: Micha Schöll
License: MIT License
        
        Copyright (c) 2025 Micha Schöll
        
        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.
License-File: LICENSE
Requires-Python: >=3.6
Description-Content-Type: text/markdown

# pyright to gitlab
Simple Python script to convert a pyright --outputjson to a gitlab code-quality report.

## Usage
Run the script with the path to the pyright output file:
```shell
$ pip install pyright-to-gitlab
$  pyright . --outputjson | pyright-to-gitlab > code-quality.json 
```

Alternatively, the module can be called:
```shell
$ pip install pyright-to-gitlab
$  pyright . --outputjson | python -m pyright_to_gitlab > code-quality.json 
```
### Custom path prefix
The `--prefix` option adds a custom prefix to the file paths in the output. This is
useful if the paths in the pyright output are not relative to the root of the repository.


```shell
$  pyright . --outputjson | pyright-to-gitlab --prefix my-app/ > code-quality.json 
```

## Testing
To run the tests, execute
```shell
$ uv run pytest tests/
```
