Skip to content

Commit dc440a1

Browse files
committed
Forcing the repo name to populate in comment pr step
1 parent 34ebc53 commit dc440a1

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

.github/workflows/pr-preview.yml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,14 @@ jobs:
6868
script: |
6969
const version = process.env.VERSION;
7070
const prNumber = context.payload.pull_request.number;
71+
const owner = context.repo.owner;
72+
const repo = context.repo.repo;
73+
74+
// Log the values for debugging
75+
console.log("Owner:", context.repo.owner);
76+
console.log("Repo:", context.repo.repo);
77+
console.log("Context Repo:", JSON.stringify(context.repo, null, 2));
78+
7179
const comment = `
7280
🚀 Preview package published!
7381
@@ -80,13 +88,14 @@ jobs:
8088
`;
8189
8290
github.rest.issues.createComment({
91+
owner: owner,
92+
repo: repo,
8393
issue_number: prNumber,
84-
owner: context.repo.owner,
85-
repo: context.repo.name,
8694
body: comment
8795
});
8896
8997
98+
9099
- name: Login to Docker Hub
91100
uses: docker/login-action@v3
92101
with:

0 commit comments

Comments
 (0)