@@ -57338,7 +57338,7 @@ const file_1 = __nccwpck_require__(398);
5733857338const get_release_plan_1 = __nccwpck_require__(6240);
5733957339function main() {
5734057340 return __awaiter(this, void 0, void 0, function* () {
57341- var _a, _b, _c, _d;
57341+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m ;
5734257342 const context = github.context;
5734357343 const { pull_request } = context.payload;
5734457344 if (!pull_request) {
@@ -57382,11 +57382,74 @@ function main() {
5738257382 : `The base branch is ${pull_request.base.ref}, or the head branch is ${(_c = pull_request === null || pull_request === void 0 ? void 0 : pull_request.head) === null || _c === void 0 ? void 0 : _c.ref}, so detectAdd is skipped.`);
5738357383 return;
5738457384 }
57385+ // Fork PR 감지 및 가이드 코멘트 처리
57386+ const forkGuideEnabled = core.getInput('fork_guide_enabled') === 'true';
57387+ const isForkPR = ((_e = (_d = pull_request.head) === null || _d === void 0 ? void 0 : _d.repo) === null || _e === void 0 ? void 0 : _e.fork) === true || ((_g = (_f = pull_request.head) === null || _f === void 0 ? void 0 : _f.repo) === null || _g === void 0 ? void 0 : _g.full_name) !== `${owner}/${repo}`;
57388+ if (isForkPR) {
57389+ core.info(isKoreanLanguage
57390+ ? `Fork PR이 감지되었습니다. (${(_j = (_h = pull_request.head) === null || _h === void 0 ? void 0 : _h.repo) === null || _j === void 0 ? void 0 : _j.full_name})`
57391+ : `Fork PR detected. (${(_l = (_k = pull_request.head) === null || _k === void 0 ? void 0 : _k.repo) === null || _l === void 0 ? void 0 : _l.full_name})`);
57392+ if (forkGuideEnabled) {
57393+ const customMessage = core.getInput('fork_guide_message');
57394+ const defaultMessage = `## Changeset Guide for External Contributors
57395+
57396+ **한국어** | [English](#english)
57397+
57398+ ### 한국어
57399+
57400+ 외부 기여자분께 감사드립니다! 🎉
57401+
57402+ 패키지에 변경사항이 있는 경우, changeset 파일을 수동으로 생성해주세요.
57403+
57404+ \`\`\`bash
57405+ pnpm changeset
57406+ \`\`\`
57407+
57408+ 위 명령어를 실행하면 변경된 패키지와 버전 타입(patch/minor/major)을 선택하고, 변경 내용을 입력할 수 있습니다.
57409+
57410+ 생성된 \`.changeset/*.md\` 파일을 커밋에 포함해주세요.
57411+
57412+ > **참고**: \`${skipLabel}\` 레이블이 있으면 changeset이 필요하지 않습니다.
57413+
57414+ ---
57415+
57416+ <a name="english"></a>
57417+ ### English
57418+
57419+ Thank you for your contribution! 🎉
57420+
57421+ If your PR includes package changes, please create a changeset file manually.
57422+
57423+ \`\`\`bash
57424+ pnpm changeset
57425+ \`\`\`
57426+
57427+ This command will guide you to select the changed packages, version type (patch/minor/major), and enter a description.
57428+
57429+ Please include the generated \`.changeset/*.md\` file in your commit.
57430+
57431+ > **Note**: If the \`${skipLabel}\` label is present, changeset is not required.
57432+
57433+ <!-- ${constants_1.CHANGESET_DETECT_ADD_ACTIONS_CHECKSUM} -->`;
57434+ const guideMessage = customMessage || defaultMessage;
57435+ const guideComment = Object.assign(Object.assign({}, commonParams), { body: guideMessage });
57436+ if (prevComment !== undefined) {
57437+ yield octokit.rest.issues.updateComment(Object.assign(Object.assign({}, guideComment), { comment_id: prevComment.id }));
57438+ }
57439+ else {
57440+ yield octokit.rest.issues.createComment(guideComment);
57441+ }
57442+ core.info(isKoreanLanguage
57443+ ? `Fork PR에 changeset 가이드 코멘트를 추가했습니다.`
57444+ : `Added changeset guide comment for fork PR.`);
57445+ }
57446+ return;
57447+ }
5738557448 /**
5738657449 * 변경된 파일 이름을 가져오기위한 api
5738757450 */
5738857451 const packages_dir = core.getInput('packages_dir');
57389- const excludes = (_d = core.getInput('excludes')) !== null && _d !== void 0 ? _d : '';
57452+ const excludes = (_m = core.getInput('excludes')) !== null && _m !== void 0 ? _m : '';
5739057453 if (typeof packages_dir !== 'string') {
5739157454 throw new Error(isKoreanLanguage
5739257455 ? `해당 action에 주입된 packages_dir parameter가 잘못되었습니다. (string, string1)의 형식으로 작성해주세요.`
0 commit comments