Skip to content

Commit d7096c5

Browse files
committed
Added basic release information
1 parent 27fbeec commit d7096c5

File tree

4 files changed

+50
-5
lines changed

4 files changed

+50
-5
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Load data from YAML files into Netbox
66

77
First activate your virtual environment where Netbox is installed, the install the plugin version correspondig to your Netbox version.
88
```bash
9-
pip install "netbox-initializers==3.2"
9+
pip install "netbox-initializers==3.2.*"
1010
```
1111

1212
### Getting started
@@ -30,6 +30,6 @@ The initializers where a part of the Docker image and where then extracted into
3030
To use the new plugin in a the Netbox Docker image, it musst be installad into the image. To this, the following example can be used as a starting point:
3131

3232
```dockerfile
33-
FROM netboxcommunity/netbox:3.2
34-
RUN /opt/netbox/venv/bin/pip install "netbox-initializers==3.2"
33+
FROM netboxcommunity/netbox:v3.2
34+
RUN /opt/netbox/venv/bin/pip install "netbox-initializers==3.2.*"
3535
```

Release.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# Build a release
2+
3+
Please follow these steps to produce a release
4+
5+
## Checkout correct branch
6+
7+
Checkout the branch for which the release is to be build. If no branch exists for the new release one must be created. The name must correspond to the Netbox version in the format "MAJOR.MINOR".
8+
9+
## Set version number
10+
11+
The version number in `README.md`, `setup.py` and the `NetBoxInitializersConfig` need to be updated.
12+
13+
## Build the packages
14+
15+
Install the needed Python packages for the build:
16+
17+
```bash
18+
pip install --upgrade pip setuptools wheel twine build
19+
```
20+
21+
Then run the build for the wheel and source distributions:
22+
23+
```bash
24+
python -m build --sdist
25+
python -m build --wheel
26+
```
27+
28+
Check the release with twine:
29+
30+
```bash
31+
twine check dist/*
32+
```
33+
34+
## Upload packeges to PyPi
35+
36+
```bash
37+
twine upload dist/*
38+
```

src/netbox_initializers/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ class NetBoxInitializersConfig(PluginConfig):
55
name = 'netbox_initializers'
66
verbose_name = 'NetBox Initializers'
77
description = 'Load initial data into Netbox'
8-
version = '3.2'
8+
version = '3.2.0'
99
base_url = 'initializers'
1010
min_version = '3.2.0'
1111
max_version = '3.2.99'

src/setup.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,19 @@
11
from setuptools import find_packages, setup
22

3+
from pathlib import Path
4+
this_directory = Path(__file__).parent
5+
6+
long_description = (this_directory / ".." / "README.md").read_text()
7+
38
setup(
49
name="netbox-initializers",
5-
version="3.2",
10+
version="3.2.0",
611
description="Load initial data into Netbox",
712
install_requires=["ruamel.yaml==0.17.21"],
813
packages=find_packages() + ["netbox_initializers.initializers.yaml"],
914
package_data={"netbox_initializers.initializers.yaml": ["*.yml"]},
1015
include_package_data=True,
1116
zip_safe=False,
17+
long_description=long_description,
18+
long_description_content_type='text/markdown'
1219
)

0 commit comments

Comments
 (0)