Skip to content

Commit ea5b144

Browse files
committed
chore(build): correct substitution string for release version
1 parent c04ae94 commit ea5b144

File tree

3 files changed

+15
-3
lines changed

3 files changed

+15
-3
lines changed

.github/workflows/publish.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,13 @@ jobs:
9393

9494
- name: Set version to include mypyc suffix
9595
run: |
96-
sed -i 's/version = "0.15.0"/version = "0.15.0+mypyc"/' pyproject.toml
96+
# Extract current version and add mypyc suffix
97+
CURRENT_VERSION=$(grep '^version = ' pyproject.toml | cut -d'"' -f2)
98+
if [[ "${{ runner.os }}" == "macOS" ]]; then
99+
sed -i '' "s/version = \"$CURRENT_VERSION\"/version = \"$CURRENT_VERSION+mypyc\"/" pyproject.toml
100+
else
101+
sed -i "s/version = \"$CURRENT_VERSION\"/version = \"$CURRENT_VERSION+mypyc\"/" pyproject.toml
102+
fi
97103
shell: bash
98104

99105
- name: Install dependencies with mypyc extras

.github/workflows/test-build.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,13 @@ jobs:
104104

105105
- name: Set version to include mypyc suffix
106106
run: |
107-
sed -i 's/version = "0.15.0"/version = "0.15.0+mypyc"/' pyproject.toml
107+
# Extract current version and add mypyc suffix
108+
CURRENT_VERSION=$(grep '^version = ' pyproject.toml | cut -d'"' -f2)
109+
if [[ "${{ runner.os }}" == "macOS" ]]; then
110+
sed -i '' "s/version = \"$CURRENT_VERSION\"/version = \"$CURRENT_VERSION+mypyc\"/" pyproject.toml
111+
else
112+
sed -i "s/version = \"$CURRENT_VERSION\"/version = \"$CURRENT_VERSION+mypyc\"/" pyproject.toml
113+
fi
108114
shell: bash
109115

110116
- name: Install dependencies with mypyc extras

sqlspec/utils/sync_tools.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
try:
1515
import uvloop # pyright: ignore[reportMissingImports]
1616
except ImportError:
17-
uvloop = None
17+
uvloop = None # type: ignore[assignment]
1818

1919

2020
ReturnT = TypeVar("ReturnT")

0 commit comments

Comments
 (0)