From c20b1c6d3accb1854ba1af6acfd2e51bc4c4ff52 Mon Sep 17 00:00:00 2001 From: Martin Bernstorff Date: Sat, 23 Dec 2023 13:45:31 +0000 Subject: [PATCH 1/7] {selected_issue.title}. Fixes #{selected_issue.number} --- .devcontainer/devcontainer.json | 5 +++-- personal_mnemonic_medium/subtasks/graphite.py | 7 ++++--- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index d8c030f..a5cf8e5 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -32,12 +32,13 @@ ], "containerEnv": { "HOST_HOME": "${localEnv:HOME}", - "HOST_INPUT_DIR": "${localEnv:HOME}/ankidecks" + "HOST_INPUT_DIR": "${localEnv:HOME}/ankidecks", + "ENV": "devcontainer" }, "features": { "ghcr.io/devcontainers/features/github-cli:1": {} }, - "postStartCommand": "inv install && export ENV=dev-container" + "postStartCommand": "inv install && gt user pager disable" // Features to add to the dev container. More info: https://containers.dev/features. // "features": {}, // Use 'forwardPorts' to make a list of ports inside the container available locally. diff --git a/personal_mnemonic_medium/subtasks/graphite.py b/personal_mnemonic_medium/subtasks/graphite.py index a326f36..6d9a878 100644 --- a/personal_mnemonic_medium/subtasks/graphite.py +++ b/personal_mnemonic_medium/subtasks/graphite.py @@ -13,7 +13,8 @@ def submit_pr(c: inv.Context): def create_branch_from_issue(c: inv.Context, selected_issue: GithubIssue): sanitised_title = sanitise_issue_title(selected_issue.title) branch_title = f"{selected_issue.number}-{sanitised_title}" - c.run(f"gt create {branch_title}") - c.run( - f"git commit --allow-empty -m $'{selected_issue.title}.\n\nFixes #{selected_issue.number}'" + first_commit_str = ( + "$'{selected_issue.title}.\n\nFixes #{selected_issue.number}'" ) + c.run(f"gt create {branch_title} --all -m {first_commit_str}") + c.run(f"git commit --allow-empty -m {first_commit_str}") From aac479fee33687c5d6d4105687504ef03f7d00b6 Mon Sep 17 00:00:00 2001 From: Martin Bernstorff Date: Sat, 23 Dec 2023 13:45:31 +0000 Subject: [PATCH 2/7] {selected_issue.title}. Fixes #{selected_issue.number} From 58161adb3b31117f83f5c068e0cc86aa1316b208 Mon Sep 17 00:00:00 2001 From: Martin Bernstorff Date: Sat, 23 Dec 2023 13:45:41 +0000 Subject: [PATCH 3/7] misc. --- personal_mnemonic_medium/subtasks/graphite.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/personal_mnemonic_medium/subtasks/graphite.py b/personal_mnemonic_medium/subtasks/graphite.py index 6d9a878..e6b15b3 100644 --- a/personal_mnemonic_medium/subtasks/graphite.py +++ b/personal_mnemonic_medium/subtasks/graphite.py @@ -14,7 +14,7 @@ def create_branch_from_issue(c: inv.Context, selected_issue: GithubIssue): sanitised_title = sanitise_issue_title(selected_issue.title) branch_title = f"{selected_issue.number}-{sanitised_title}" first_commit_str = ( - "$'{selected_issue.title}.\n\nFixes #{selected_issue.number}'" + f"$'{selected_issue.title}.\n\nFixes #{selected_issue.number}'" ) c.run(f"gt create {branch_title} --all -m {first_commit_str}") c.run(f"git commit --allow-empty -m {first_commit_str}") From 41973009f47756b3fa98e9daf473cc58b81f6c57 Mon Sep 17 00:00:00 2001 From: Martin Bernstorff Date: Sat, 23 Dec 2023 13:46:41 +0000 Subject: [PATCH 4/7] misc. --- .devcontainer/devcontainer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index a5cf8e5..87463e5 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -38,7 +38,7 @@ "features": { "ghcr.io/devcontainers/features/github-cli:1": {} }, - "postStartCommand": "inv install && gt user pager disable" + "postStartCommand": "inv install && gt user pager --disable" // Features to add to the dev container. More info: https://containers.dev/features. // "features": {}, // Use 'forwardPorts' to make a list of ports inside the container available locally. From da1e4ad4ecd9393153709ed71e600a7427319fcd Mon Sep 17 00:00:00 2001 From: Martin Bernstorff Date: Sat, 23 Dec 2023 13:48:47 +0000 Subject: [PATCH 5/7] fix: smokestest --- docker_smoketest.sh | 2 -- 1 file changed, 2 deletions(-) diff --git a/docker_smoketest.sh b/docker_smoketest.sh index f1374d7..63c0e9f 100755 --- a/docker_smoketest.sh +++ b/docker_smoketest.sh @@ -20,8 +20,6 @@ docker run -i \ personal-mnemonic-medium \ python personal_mnemonic_medium/cli.py \ --input-dir /input/ \ - --apkg-output-dir $APKG_OUTPUT_DIR \ - --host-apkg-dir $HOST_APKG_DIR \ --dry-run \ --skip-sync From 10c29f1369097f2d6354d6991a02040bbf82e797 Mon Sep 17 00:00:00 2001 From: Martin Bernstorff Date: Sat, 23 Dec 2023 13:49:33 +0000 Subject: [PATCH 6/7] dev: update pager --- personal_mnemonic_medium/subtasks/graphite.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/personal_mnemonic_medium/subtasks/graphite.py b/personal_mnemonic_medium/subtasks/graphite.py index e6b15b3..5f2766c 100644 --- a/personal_mnemonic_medium/subtasks/graphite.py +++ b/personal_mnemonic_medium/subtasks/graphite.py @@ -7,7 +7,7 @@ def submit_pr(c: inv.Context): c.run("gt sync --delete --force") c.run("gt submit --stack --restack -m --no-edit --publish") - c.run("gt log -s") + c.run("gt log short") def create_branch_from_issue(c: inv.Context, selected_issue: GithubIssue): From 75b3f22e5e4fa38c2fb86f80c8a34829b4d31116 Mon Sep 17 00:00:00 2001 From: Martin Bernstorff Date: Sat, 23 Dec 2023 14:07:45 +0000 Subject: [PATCH 7/7] ci: update