Skip to content

Commit

Permalink
chore: Create and checkout temp branch to store changes
Browse files Browse the repository at this point in the history
  • Loading branch information
Ackuq committed Jun 3, 2024
1 parent fae0c56 commit f0990b6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
6 changes: 2 additions & 4 deletions actions/update-standpoints/dist/index.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -32159,7 +32159,6 @@ const GIT_EMAIL = "github-actions[bot]@users.noreply.github.com";
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => {

/* harmony export */ __nccwpck_require__.d(__webpack_exports__, {
/* harmony export */ "JE": () => (/* binding */ checkout),
/* harmony export */ "Pp": () => (/* binding */ checkIfBranchExists),
/* harmony export */ "Qj": () => (/* binding */ createBranch),
/* harmony export */ "VF": () => (/* binding */ push),
Expand All @@ -32168,6 +32167,7 @@ const GIT_EMAIL = "github-actions[bot]@users.noreply.github.com";
/* harmony export */ "q7": () => (/* binding */ forcePush),
/* harmony export */ "th": () => (/* binding */ commit)
/* harmony export */ });
/* unused harmony export checkout */
/* harmony import */ var _actions_core__WEBPACK_IMPORTED_MODULE_0__ = __nccwpck_require__(4237);
/* harmony import */ var _actions_exec__WEBPACK_IMPORTED_MODULE_1__ = __nccwpck_require__(4260);
// @ts-check
Expand Down Expand Up @@ -32339,10 +32339,8 @@ _actions_core__WEBPACK_IMPORTED_MODULE_0__.startGroup("Creating / updating branc
const branchExists = await (0,_git_helper_mjs__WEBPACK_IMPORTED_MODULE_2__/* .checkIfBranchExists */ .Pp)(_constants_mjs__WEBPACK_IMPORTED_MODULE_1__/* .BRANCH_NAME */ .BP);
if (branchExists) {
_actions_core__WEBPACK_IMPORTED_MODULE_0__.info(`Branch ${_constants_mjs__WEBPACK_IMPORTED_MODULE_1__/* .BRANCH_NAME */ .BP} already exists...`);
_actions_core__WEBPACK_IMPORTED_MODULE_0__.info("Creating temp branch to store changes");
_actions_core__WEBPACK_IMPORTED_MODULE_0__.info("Creating and checking out temp branch to store changes");
await (0,_git_helper_mjs__WEBPACK_IMPORTED_MODULE_2__/* .createBranch */ .Qj)(_constants_mjs__WEBPACK_IMPORTED_MODULE_1__/* .TEMP_BRANCH_NAME */ .gK);
_actions_core__WEBPACK_IMPORTED_MODULE_0__.info("Checking out temporary branch");
await (0,_git_helper_mjs__WEBPACK_IMPORTED_MODULE_2__/* .checkout */ .JE)(_constants_mjs__WEBPACK_IMPORTED_MODULE_1__/* .TEMP_BRANCH_NAME */ .gK);
} else {
_actions_core__WEBPACK_IMPORTED_MODULE_0__.info(`Branch ${_constants_mjs__WEBPACK_IMPORTED_MODULE_1__/* .BRANCH_NAME */ .BP} does not exist, creating...`);
await (0,_git_helper_mjs__WEBPACK_IMPORTED_MODULE_2__/* .createBranch */ .Qj)(_constants_mjs__WEBPACK_IMPORTED_MODULE_1__/* .BRANCH_NAME */ .BP);
Expand Down
4 changes: 1 addition & 3 deletions actions/update-standpoints/src/main.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,8 @@ core.startGroup("Creating / updating branch and commit changes");
const branchExists = await checkIfBranchExists(BRANCH_NAME);
if (branchExists) {
core.info(`Branch ${BRANCH_NAME} already exists...`);
core.info("Creating temp branch to store changes");
core.info("Creating and checking out temp branch to store changes");
await createBranch(TEMP_BRANCH_NAME);
core.info("Checking out temporary branch");
await checkout(TEMP_BRANCH_NAME);
} else {
core.info(`Branch ${BRANCH_NAME} does not exist, creating...`);
await createBranch(BRANCH_NAME);
Expand Down

0 comments on commit f0990b6

Please sign in to comment.