MCPcopy
hub / github.com/pyodide/pyodide / set_date

Function set_date

tools/backport.py:739–765  ·  view source on GitHub ↗
(args)

Source from the content-addressed store, hash-verified

737
738
739def set_date(args):
740 version = get_version()
741 BACKPORTS_BRANCH = f"backports-for-{version}"
742 CHANGELOG_BRANCH = f"changelog-for-{version}"
743 update_old_branch(BACKPORTS_BRANCH)
744 run(["git", "switch", BACKPORTS_BRANCH])
745 run(
746 [
747 "git",
748 "rebase",
749 "stable",
750 "--exec",
751 " && ".join(
752 [
753 f"sed -i 's/_{INSERT_DATE_HERE}_/_{today()}_/' docs/project/changelog.md",
754 "git add docs/project/changelog.md",
755 "git commit --amend --no-edit",
756 ]
757 ),
758 ]
759 )
760
761 update_old_branch(CHANGELOG_BRANCH)
762 run(["git", "switch", CHANGELOG_BRANCH])
763 CHANGELOG.write_text(CHANGELOG.read_text().replace(INSERT_DATE_HERE, today()))
764 run(["git", "add", "docs/project/changelog.md"])
765 run(["git", "commit", "--amend", "--no-edit"])
766
767
768def bump_version(args):

Callers

nothing calls this directly

Calls 6

get_versionFunction · 0.85
update_old_branchFunction · 0.85
todayFunction · 0.85
joinMethod · 0.80
write_textMethod · 0.80
runFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…