Skip to content

Commit fd5a9a5

Browse files
committed
ci(sync-pr): allow custom command & secure git remote auth with token
1 parent dc0c63c commit fd5a9a5

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ WORKDIR /app
4343
ARG GH_TOKEN
4444
ENV GH_TOKEN=$GH_TOKEN
4545
RUN gh repo clone oleander/git-ai /app
46+
RUN git remote set-url origin https://x-access-token:$GH_TOKEN@github.com/oleander/git-ai.git
4647
RUN cargo fetch
4748
RUN cargo build
4849
RUN cargo clippy

Justfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,5 +35,5 @@ pr PR_NUMBER CMD:
3535
docker run -i --rm -e GITHUB_TOKEN=$(gh auth token) git-ai-pr-tester bash -c "{{CMD}}"
3636

3737
# Sync a specific PR with origin/main
38-
sync-pr PR_NUM:
39-
just pr {{PR_NUM}} "git merge origin/main --no-edit && cargo fmt --check && cargo check && git push origin"
38+
sync-pr PR_NUM CMD = "date":
39+
just pr {{PR_NUM}} "git merge origin/main --no-edit && {{CMD}} && cargo fmt --check && cargo check && git push origin"

0 commit comments

Comments
 (0)