deploy-vir 0.2.2 → 0.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/git.js +4 -4
- package/dist/notifications/slack.js +1 -1
- package/package.json +1 -1
- package/src/git.ts +4 -4
- package/src/notifications/slack.ts +1 -1
package/dist/git.js
CHANGED
|
@@ -74,16 +74,16 @@ export async function pushDeploy(git, { deployName, fromBranch, toBranch }, remo
|
|
|
74
74
|
`${remoteName}/${fromBranch}..${remoteName}/${toBranch}`,
|
|
75
75
|
])).all;
|
|
76
76
|
if (commitsBehind.length > 0) {
|
|
77
|
-
log.info(`\
|
|
78
|
-
|
|
77
|
+
log.info(`\nOnly on ${logColors.bold}${fromBranch}${logColors.reset}:`);
|
|
78
|
+
commitsAhead.forEach((commit, index) => {
|
|
79
79
|
log.faint(` ${index + 1}. ${commit.hash.slice(0, 7)} (${commit.author_name}) - ${commit.message}`);
|
|
80
80
|
});
|
|
81
|
-
log.info(`\
|
|
81
|
+
log.info(`\nOnly on ${logColors.bold}${toBranch}${logColors.reset}:`);
|
|
82
82
|
commitsBehind.forEach((commit, index) => {
|
|
83
83
|
log.faint(` ${index + 1}. ${commit.hash.slice(0, 7)} (${commit.author_name}) - ${commit.message}`);
|
|
84
84
|
});
|
|
85
85
|
}
|
|
86
|
-
const shouldForcePush = await askQuestion(`\nDo you want to force push ${logColors.bold}${fromBranch}${logColors.reset} to ${logColors.bold}${toBranch}${logColors.reset}?\n\n${logColors.warning}This will overwrite the commits
|
|
86
|
+
const shouldForcePush = await askQuestion(`\nDo you want to force push ${logColors.bold}${fromBranch}${logColors.reset} to ${logColors.bold}${toBranch}${logColors.reset}?\n\n${logColors.warning}This will overwrite the commits only on ${logColors.bold}${toBranch}${logColors.normalWeight}.${logColors.reset} (y/N): `);
|
|
87
87
|
if (shouldForcePush.toLowerCase() === 'y' || shouldForcePush.toLowerCase() === 'yes') {
|
|
88
88
|
await git.push(remoteName, pushString, ['--force']);
|
|
89
89
|
log.warning(`Force pushed ${logColors.bold}${fromBranch}${logColors.reset} to ${logColors.bold}${toBranch}${logColors.reset}.`);
|
package/package.json
CHANGED
package/src/git.ts
CHANGED
|
@@ -158,14 +158,14 @@ export async function pushDeploy(
|
|
|
158
158
|
).all;
|
|
159
159
|
|
|
160
160
|
if (commitsBehind.length > 0) {
|
|
161
|
-
log.info(`\
|
|
162
|
-
|
|
161
|
+
log.info(`\nOnly on ${logColors.bold}${fromBranch}${logColors.reset}:`);
|
|
162
|
+
commitsAhead.forEach((commit, index) => {
|
|
163
163
|
log.faint(
|
|
164
164
|
` ${index + 1}. ${commit.hash.slice(0, 7)} (${commit.author_name}) - ${commit.message}`,
|
|
165
165
|
);
|
|
166
166
|
});
|
|
167
167
|
|
|
168
|
-
log.info(`\
|
|
168
|
+
log.info(`\nOnly on ${logColors.bold}${toBranch}${logColors.reset}:`);
|
|
169
169
|
commitsBehind.forEach((commit, index) => {
|
|
170
170
|
log.faint(
|
|
171
171
|
` ${index + 1}. ${commit.hash.slice(0, 7)} (${commit.author_name}) - ${commit.message}`,
|
|
@@ -174,7 +174,7 @@ export async function pushDeploy(
|
|
|
174
174
|
}
|
|
175
175
|
|
|
176
176
|
const shouldForcePush = await askQuestion(
|
|
177
|
-
`\nDo you want to force push ${logColors.bold}${fromBranch}${logColors.reset} to ${logColors.bold}${toBranch}${logColors.reset}?\n\n${logColors.warning}This will overwrite the commits
|
|
177
|
+
`\nDo you want to force push ${logColors.bold}${fromBranch}${logColors.reset} to ${logColors.bold}${toBranch}${logColors.reset}?\n\n${logColors.warning}This will overwrite the commits only on ${logColors.bold}${toBranch}${logColors.normalWeight}.${logColors.reset} (y/N): `,
|
|
178
178
|
);
|
|
179
179
|
|
|
180
180
|
if (shouldForcePush.toLowerCase() === 'y' || shouldForcePush.toLowerCase() === 'yes') {
|