Metadata-Version: 2.1
Name: ops-py-generate-pyproject
Version: 2.2.3
Summary: Generate needed pyproject files to use with setuptools
License: MIT License
        
        Copyright (c) 2024 Equinor
        
        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.
        
Description-Content-Type: text/markdown
License-File: LICENSE

# generate-pyproject

## Before you begin
Please refer to the [example-code](https://pypi.org/project/ops-py-example-code)
if you are planning on writing a Python package and distribute it to https://pypi.org

---

## Usage

### Install this package:
`pip install ops-py-generate-pyproject`


### Export the VERSION and PROJECT_NAME environment variables 
The PyPI project name and version, e.g.:

```
export VERSION=1.2.3
export PROJECT_NAME=my-fabulous-projects
```

### Run the code
Be sure to be in the directory where the `src` dir of you code is located. Then run the following:   
`python3 -m generate_pyproject.generate_pyproject`

When executing the above code, the following files should then be generated in the `src/my-fabulous-projects` directory:   
- `setup.py`
- `pyproject.toml`

### Build the pip package
Be sure to be inside the `src` directory and then run:   
`python -m build`

### Upload to pypi.org
Be sure to be inside the `src` directory and then run:   
`python -m twine upload --verbose dist/*`
