github-rest-api 0.47.0__tar.gz → 0.47.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/PKG-INFO +1 -1
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/create_github_repo.py +15 -5
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/pyproject.toml +1 -1
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/uv.lock +1 -1
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/.devcontainer/devcontainer.json +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/.github/workflows/claude-code-review.yml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/.github/workflows/claude.yml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/.github/workflows/create_pr_to_main.yaml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/.github/workflows/lint.yaml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/.github/workflows/release.yaml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/.github/workflows/remove_branch.yaml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/.github/workflows/test.yaml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/.gitignore +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/GEMINI.md +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/README.md +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/__init__.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/github.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/pr_content.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/__init__.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/cargo/__init__.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/cargo/benchmark.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/cargo/profiling.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/cargo/utils.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/container/__init__.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/container/build_container_images.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/container/config_container.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/container/update_version_containerfile.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/__init__.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/auto_merge_pull_request.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/create_pull_request.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/release_on_github.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/remove_branch.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/workflows/create_pr_dev_to_main.yaml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/workflows/create_pr_to_dev.yaml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/workflows/create_pr_to_main.yaml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/workflows/python/lint.yaml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/workflows/python/test.yaml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/workflows/remove_branch.yaml +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/utils.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/utils.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/memory/MEMORY.md +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/memory/feedback_test_runner.md +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/tests/__init__.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/tests/test_build_container_images.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/tests/test_create_pull_request.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/tests/test_github.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/tests/test_pr_content.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/tests/test_release_on_github.py +0 -0
- {github_rest_api-0.47.0 → github_rest_api-0.47.1}/tests/test_utils.py +0 -0
|
@@ -45,6 +45,17 @@ def _ensure_remote(path: Path, repo: str, protocol: str) -> None:
|
|
|
45
45
|
pass
|
|
46
46
|
|
|
47
47
|
|
|
48
|
+
def _active_branch(path: Path) -> str:
|
|
49
|
+
try:
|
|
50
|
+
return porcelain.active_branch(path).decode()
|
|
51
|
+
except (IndexError, ValueError) as e:
|
|
52
|
+
raise ValueError(
|
|
53
|
+
f"HEAD of the local repo at '{path}' is detached (not on any branch), "
|
|
54
|
+
"which is unsupported (this happens, e.g., with a colocated Jujutsu repo). "
|
|
55
|
+
"Check out a branch (e.g. `git switch -c main`) before running this command."
|
|
56
|
+
) from e
|
|
57
|
+
|
|
58
|
+
|
|
48
59
|
def _init_local_repo(
|
|
49
60
|
repo: str,
|
|
50
61
|
language: str,
|
|
@@ -61,10 +72,9 @@ def _init_local_repo(
|
|
|
61
72
|
readme.write_text(f"# {repo_name}\n")
|
|
62
73
|
if not (path / ".git").exists():
|
|
63
74
|
porcelain.init(path=path)
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
)
|
|
67
|
-
porcelain.add(repo=path)
|
|
75
|
+
if not porcelain.branch_list(path):
|
|
76
|
+
initial_branch = _active_branch(path)
|
|
77
|
+
porcelain.add(repo=path, paths=["README.md"])
|
|
68
78
|
porcelain.commit(repo=path, message="first commit")
|
|
69
79
|
for branch in branches:
|
|
70
80
|
if branch != initial_branch:
|
|
@@ -76,7 +86,7 @@ def _init_local_repo(
|
|
|
76
86
|
local_branches = {b.decode() for b in porcelain.branch_list(path)}
|
|
77
87
|
branches_to_push = [branch for branch in branches if branch in local_branches]
|
|
78
88
|
if not branches_to_push:
|
|
79
|
-
branches_to_push = [
|
|
89
|
+
branches_to_push = [_active_branch(path)]
|
|
80
90
|
for branch in branches_to_push:
|
|
81
91
|
porcelain.push(
|
|
82
92
|
repo=path,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/cargo/benchmark.py
RENAMED
|
File without changes
|
{github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/cargo/profiling.py
RENAMED
|
File without changes
|
|
File without changes
|
{github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/container/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{github_rest_api-0.47.0 → github_rest_api-0.47.1}/github_rest_api/scripts/github/remove_branch.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|