Skip to content

Commit

Permalink
Merge pull request #639 from padix-key/fix-switcher
Browse files Browse the repository at this point in the history
Fix version for creating `switcher.json`
  • Loading branch information
padix-key authored Aug 27, 2024
2 parents f9ddf5c + 9d88c1a commit d68128d
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 3 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/test_and_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,10 @@ jobs:

steps:
- uses: actions/checkout@v4
with:
# Make sure to fetch the latest tag, so 'switcher.py' works correctly
fetch-depth: 0
fetch-tags: true
- uses: conda-incubator/setup-miniconda@v2
with:
environment-file: environment.yml
Expand Down
4 changes: 3 additions & 1 deletion doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@

# Pregeneration of files
apidoc.create_api_doc(PACKAGE_PATH, join(DOC_PATH, "apidoc"))
switcher.create_switcher_json(join("static", "switcher.json"), "v0.41.0", n_versions=5)
switcher.create_switcher_json(
join("static", "switcher.json"), biotite.__version__, n_versions=5
)

# Use custom citation style
pybtex.plugin.register_plugin("pybtex.style.formatting", "ieee", bibliography.IEEEStyle)
Expand Down
2 changes: 1 addition & 1 deletion doc/switcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

RELEASE_REQUEST = "https://api.github.com/repos/biotite-dev/biotite/releases"
BIOTITE_URL = "https://www.biotite-python.org"
SEMVER_TAG_REGEX = r"^v(\d+)\.(\d+)\.(\d+)"
SEMVER_TAG_REGEX = r"^v?(\d+)\.(\d+)\.(\d+)"


@dataclass(frozen=True)
Expand Down
3 changes: 2 additions & 1 deletion environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ dependencies:
# Package building
- cython >=3.0
- pip >=10.0
- setuptools >=30.0
- hatchling
- hatch-vcs == 0.4
- wheel >=0.30
# Biotite dependencies
- biotraj >=1.0,<2.0
Expand Down

0 comments on commit d68128d

Please sign in to comment.