Skip to content

Commit d523294

Browse files
committed
Merge remote-tracking branch 'upstream/main' into pin-actions-by-sha
2 parents 57ecd15 + 5b1311f commit d523294

7 files changed

Lines changed: 262 additions & 179 deletions

File tree

.pre-commit-config.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,3 +40,10 @@ repos:
4040
require_serial: true
4141
language: unsupported
4242
pass_filenames: false
43+
44+
- id: add-release-date
45+
language: unsupported
46+
name: add date to latest release header
47+
entry: uv run python scripts/add_latest_release_date.py
48+
files: ^release-notes\.md$
49+
pass_filenames: false

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,9 @@ dev = [
4444
]
4545
tests = [
4646
"coverage[toml]>=7.6.1",
47-
"mypy==1.19.1",
47+
"mypy==1.20.0",
4848
"pytest>=8.3.5",
49-
"ruff==0.15.4",
49+
"ruff==0.15.8",
5050
"smokeshow>=0.5.0",
5151
"ty>=0.0.9",
5252
]

release-notes.md

Lines changed: 19 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,20 @@
44

55
### Internal
66

7+
* 🔨 Add pre-commit hook to ensure latest release header has date. PR [#42](https://github.com/fastapi/fastapi-new/pull/42) by [@YuriiMotov](https://github.com/YuriiMotov).
8+
9+
## 0.0.6 (2026-04-03)
10+
11+
### Docs
12+
13+
* 📝 Remove login command from README instructions. PR [#57](https://github.com/fastapi/fastapi-new/pull/57) by [@alejsdev](https://github.com/alejsdev).
14+
15+
### Internal
16+
17+
* ⬆ Bump mypy from 1.19.1 to 1.20.0. PR [#53](https://github.com/fastapi/fastapi-new/pull/53) by [@dependabot[bot]](https://github.com/apps/dependabot).
18+
* ⬆ Bump ruff from 0.15.4 to 0.15.8. PR [#54](https://github.com/fastapi/fastapi-new/pull/54) by [@dependabot[bot]](https://github.com/apps/dependabot).
19+
* ⬆ Bump ty from 0.0.21 to 0.0.27. PR [#55](https://github.com/fastapi/fastapi-new/pull/55) by [@dependabot[bot]](https://github.com/apps/dependabot).
20+
* ⬆ Bump prek from 0.3.4 to 0.3.8. PR [#56](https://github.com/fastapi/fastapi-new/pull/56) by [@dependabot[bot]](https://github.com/apps/dependabot).
721
* 👷 Add `ty` to precommit. PR [#51](https://github.com/fastapi/fastapi-new/pull/51) by [@svlandeg](https://github.com/svlandeg).
822
* ⬆ Bump actions/upload-artifact from 6 to 7. PR [#43](https://github.com/fastapi/fastapi-new/pull/43) by [@dependabot[bot]](https://github.com/apps/dependabot).
923
* ⬆ Bump actions/download-artifact from 7 to 8. PR [#44](https://github.com/fastapi/fastapi-new/pull/44) by [@dependabot[bot]](https://github.com/apps/dependabot).
@@ -13,7 +27,7 @@
1327
* ⬆ Bump rich from 14.2.0 to 14.3.3. PR [#48](https://github.com/fastapi/fastapi-new/pull/48) by [@dependabot[bot]](https://github.com/apps/dependabot).
1428
* ⬆ Bump ruff from 0.14.14 to 0.15.4. PR [#49](https://github.com/fastapi/fastapi-new/pull/49) by [@dependabot[bot]](https://github.com/apps/dependabot).
1529

16-
## 0.0.5
30+
## 0.0.5 (2026-02-16)
1731

1832
### Internal
1933

@@ -27,7 +41,7 @@
2741
* 🔧 Ensure that an edit to `uv.lock` gets the `internal` label. PR [#34](https://github.com/fastapi/fastapi-new/pull/34) by [@svlandeg](https://github.com/svlandeg).
2842
* ⬆️ Migrate to uv. PR [#33](https://github.com/fastapi/fastapi-new/pull/33) by [@DoctorJohn](https://github.com/DoctorJohn).
2943

30-
## 0.0.4
44+
## 0.0.4 (2026-01-05)
3145

3246
### Fixes
3347

@@ -39,7 +53,7 @@
3953
* ⬆ Bump actions/checkout from 5 to 6. PR [#26](https://github.com/fastapi/fastapi-new/pull/26) by [@dependabot[bot]](https://github.com/apps/dependabot).
4054
* ⬆ Bump ruff from 0.14.4 to 0.14.10. PR [#31](https://github.com/fastapi/fastapi-new/pull/31) by [@dependabot[bot]](https://github.com/apps/dependabot).
4155

42-
## 0.0.3
56+
## 0.0.3 (2025-12-29)
4357

4458
### Docs
4559

@@ -59,7 +73,7 @@
5973
* 👷 Upgrade `latest-changes` GitHub Action and pin `actions/checkout@v5`. PR [#15](https://github.com/fastapi/fastapi-new/pull/15) by [@svlandeg](https://github.com/svlandeg).
6074
* ⬆ Bump ruff from 0.14.1 to 0.14.3. PR [#7](https://github.com/fastapi/fastapi-new/pull/7) by [@dependabot[bot]](https://github.com/apps/dependabot).
6175

62-
## 0.0.2
76+
## 0.0.2 (2025-11-10)
6377

6478
### Features
6579

@@ -82,6 +96,6 @@
8296
* 👷 Update version of Smokeshow. PR [#3](https://github.com/fastapi/fastapi-new/pull/3) by [@tiangolo](https://github.com/tiangolo).
8397
* 👷 Add tests setup for CI. PR [#1](https://github.com/fastapi/fastapi-new/pull/1) by [@tiangolo](https://github.com/tiangolo).
8498

85-
## 0.0.1
99+
## 0.0.1 (2024-08-15)
86100

87101
Reserve PyPI package.

scripts/add_latest_release_date.py

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
"""Check release-notes.md and add today's date to the latest release header if missing."""
2+
3+
import re
4+
import sys
5+
from datetime import date
6+
7+
RELEASE_NOTES_FILE = "release-notes.md"
8+
RELEASE_HEADER_PATTERN = re.compile(r"^## (\d+\.\d+\.\d+)\s*(\(.*\))?\s*$")
9+
10+
11+
def main() -> None:
12+
with open(RELEASE_NOTES_FILE) as f:
13+
lines = f.readlines()
14+
15+
for i, line in enumerate(lines):
16+
match = RELEASE_HEADER_PATTERN.match(line)
17+
if not match:
18+
continue
19+
20+
version = match.group(1)
21+
date_part = match.group(2)
22+
23+
if date_part:
24+
print(f"Latest release {version} already has a date: {date_part}")
25+
sys.exit(0)
26+
27+
today = date.today().isoformat()
28+
lines[i] = f"## {version} ({today})\n"
29+
print(f"Added date: {version} ({today})")
30+
31+
with open(RELEASE_NOTES_FILE, "w") as f:
32+
f.writelines(lines)
33+
sys.exit(0)
34+
35+
print("No release header found")
36+
sys.exit(1)
37+
38+
39+
if __name__ == "__main__":
40+
main()

src/fastapi_new/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = "0.0.5"
1+
__version__ = "0.0.6"

src/fastapi_new/new.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ def _generate_readme(project_name: str) -> str:
4545
> FastAPI Cloud is currently in private beta. Join the waitlist at https://fastapicloud.com
4646
4747
```bash
48-
uv run fastapi login
4948
uv run fastapi deploy
5049
```
5150
@@ -239,7 +238,6 @@ def new(
239238
toolkit.print_line()
240239

241240
toolkit.print("[bold]Deploy to FastAPI Cloud:[/bold]")
242-
toolkit.print(" [dim]$[/dim] uv run fastapi login")
243241
toolkit.print(" [dim]$[/dim] uv run fastapi deploy")
244242

245243
toolkit.print_line()

0 commit comments

Comments
 (0)