-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
23 changed files
with
860 additions
and
1,711 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,6 @@ | ||
# shellcheck shell=bash | ||
use flake | ||
watch_file poetry.lock | ||
|
||
watch_file uv.lock | ||
watch_file nix/pyproject-overrides.nix | ||
watch_file nix/overlay.nix |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
poetry.lock linguist-generated=true | ||
uv.lock linguist-generated=true | ||
flake.lock linguist-generated=true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
#!/usr/bin/env nix-shell | ||
#!nix-shell -p cacert gnugrep unzip poetry nix -i bash | ||
#!nix-shell -p cacert gnugrep unzip uv python3 -i bash | ||
# shellcheck shell=bash | ||
|
||
set -euo pipefail | ||
|
||
version="${1}" | ||
|
||
# set version | ||
poetry version "$version" | ||
uvx --from=toml-cli toml set --toml-path=pyproject.toml project.version "$version" | ||
|
||
# build artifacts | ||
poetry build | ||
uv build --python "$(which python)" | ||
|
||
# ensure that the built wheel has the correct version number | ||
unzip -p "dist/numbsql-${version}-py3-none-any.whl" numbsql/__init__.py | grep -q "__version__ = \"$version\"" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
#!/usr/bin/env nix-shell | ||
#!nix-shell --pure --keep POETRY_PYPI_TOKEN_PYPI -p cacert poetry -i bash | ||
#!nix-shell --pure --keep UV_PUBLISH_TOKEN -p cacert uv -i bash | ||
# shellcheck shell=bash | ||
|
||
set -euo pipefail | ||
|
||
poetry publish | ||
uv publish |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
#!/usr/bin/env nix-shell | ||
#!nix-shell -I nixpkgs=channel:nixos-unstable-small --pure --keep POETRY_PYPI_TOKEN_PYPI -p poetry -i bash | ||
#!nix-shell -I nixpkgs=channel:nixos-unstable-small --pure --keep UV_PUBLISH_TOKEN -p uv python3 -i bash | ||
# shellcheck shell=bash | ||
|
||
set -euo pipefail | ||
|
||
dry_run="${1:-false}" | ||
|
||
# verify pyproject.toml | ||
poetry check | ||
# verify pyproject.toml and lock file | ||
uv lock --python "$(which python)" --locked | ||
|
||
# verify that we have a token available to push to pypi using set -u | ||
if [ "${dry_run}" = "false" ]; then | ||
: "${POETRY_PYPI_TOKEN_PYPI}" | ||
: "${UV_PUBLISH_TOKEN}" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.