Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 41 additions & 0 deletions .github/workflows/python-publish-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# This workflow will upload a Python Package using Twine when a release is created
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries

name: Deploy to Test PyPI

on:
push:
tags:
- 'v*'

jobs:
release-test-pypi:
# Upload to Test PyPI on every pushed tag.
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
runs-on: ubuntu-latest
environment:
name: release-pypi
url: https://test.pypi.org/p/NREL-landbosse
permissions:
id-token: write

steps:
- uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'

- name: Build package
run: |
python -m pip install --upgrade pip
pip install setuptools build wheel twine
python -m build
twine check --strict dist/*

- name: Publish package to Test PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
verbose: True
repository-url: https://test.pypi.org/legacy/
39 changes: 39 additions & 0 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# This workflow will upload a Python Package using Twine when a release is created
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries

name: Deploy to PyPI

on:
release:
types: [published]

jobs:
release-pypi:
# Upload to PyPI on every published release
if: github.event.action == 'published'
environment:
name: release-pypi
url: https://pypi.org/p/NREL-landbosse
runs-on: ubuntu-latest
permissions:
id-token: write

steps:
- uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'

- name: Build package
run: |
python -m pip install --upgrade pip
pip install setuptools build wheel twine
python -m build
twine check --strict dist/*

- name: Publish package to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
verbose: True
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ The user guide comes in three parts:

### Software Installation

```bash
pip install NREL-landbosse
```

There are two options depending on whether you are a developer or an end user and what operating system you are running.

- **Windows end-user**: If you run the Microsoft Windows operating system and aren't setting up as a developer who is going to be modifying the core library, these instructions are for you. [Find out how to configure Windows for end users.](installation_instructions/windows_end_user.md)
Expand Down
2 changes: 1 addition & 1 deletion installation_instructions/macos_developer.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ pip install -e .

By installing it in developer mode with `pip` you have two benefits:

1. It can be uninstalled with `pip uninstall landbosse` (you don't need to uninstall it right now)
1. It can be uninstalled with `pip uninstall NREL-landbosse` (you don't need to uninstall it right now)
1. You can update the source code with re-installing the package because `pip` uses symbolic links (aka symlinks) to reference your source code directory.

## Step 6: Copy your input data
Expand Down
2 changes: 2 additions & 0 deletions landbosse/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@

__version__ = "2.6.1"
9 changes: 5 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ requires = ["setuptools", "wheel"]
build-backend = "setuptools.build_meta"

[project]
name = "landbosse"
version = "2.6.0"
name = "NREL-landbosse"
dynamic = ["version"]
description = "Wind-Plant Integrated System Design & Engineering Model"
readme = "README.md"
requires-python = ">=3.9"
Expand Down Expand Up @@ -36,6 +36,7 @@ classifiers = [ # Optional
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: C",
"Programming Language :: Fortran",
Expand Down Expand Up @@ -78,8 +79,8 @@ docs = ["sphinx", "sphinx_rtd_theme"]
[tool.setuptools]
include-package-data = true

#[tool.setuptools.packages]
#find = {}
[tool.setuptools.dynamic]
version = {attr = "landbosse.__version__"}

[tool.setuptools.packages.find]
#where = ["wisdem"]
Expand Down
Loading