Force-push when rewriting history
This commit is contained in:
parent
74290d2101
commit
c13ece3f65
4
dist/index.js
vendored
4
dist/index.js
vendored
@ -25843,9 +25843,9 @@ async function main(sourceRepo, targetRepo, dryRun, tokenForTargetRepo) {
|
|||||||
// OK, that's it - we've processed all the source commits, and we've inserted all the necessary target commits.
|
// OK, that's it - we've processed all the source commits, and we've inserted all the necessary target commits.
|
||||||
// We can just `git push` to the target repo now.
|
// We can just `git push` to the target repo now.
|
||||||
//
|
//
|
||||||
// But I'm gonna do a bunch more dry-run testing before I do that!
|
// Note that it must be a `-f`, because we are literally rewriting history.
|
||||||
if (!dryRun) {
|
if (!dryRun) {
|
||||||
(0, child_process_1.execSync)(`git push https://unused-username:${tokenForTargetRepo}@${targetRepo.domain}/${targetRepo.owner}/${targetRepo.name}`, {
|
(0, child_process_1.execSync)(`git push -f https://unused-username:${tokenForTargetRepo}@${targetRepo.domain}/${targetRepo.owner}/${targetRepo.name}`, {
|
||||||
cwd: TARGET_DIR
|
cwd: TARGET_DIR
|
||||||
});
|
});
|
||||||
// TODO - it'd be nice - before this `git push` is probably best - to add a `README.md` comment acknowledging
|
// TODO - it'd be nice - before this `git push` is probably best - to add a `README.md` comment acknowledging
|
||||||
|
BIN
node_modules/@vercel/ncc/dist/ncc/cli.js.cache
generated
vendored
BIN
node_modules/@vercel/ncc/dist/ncc/cli.js.cache
generated
vendored
Binary file not shown.
BIN
node_modules/@vercel/ncc/dist/ncc/index.js.cache
generated
vendored
BIN
node_modules/@vercel/ncc/dist/ncc/index.js.cache
generated
vendored
Binary file not shown.
BIN
node_modules/@vercel/ncc/dist/ncc/loaders/relocate-loader.js.cache
generated
vendored
BIN
node_modules/@vercel/ncc/dist/ncc/loaders/relocate-loader.js.cache
generated
vendored
Binary file not shown.
BIN
node_modules/@vercel/ncc/dist/ncc/loaders/shebang-loader.js.cache
generated
vendored
BIN
node_modules/@vercel/ncc/dist/ncc/loaders/shebang-loader.js.cache
generated
vendored
Binary file not shown.
BIN
node_modules/@vercel/ncc/dist/ncc/loaders/ts-loader.js.cache
generated
vendored
BIN
node_modules/@vercel/ncc/dist/ncc/loaders/ts-loader.js.cache
generated
vendored
Binary file not shown.
@ -116,9 +116,9 @@ export async function main(sourceRepo: Repo, targetRepo: Repo, dryRun: boolean,
|
|||||||
// OK, that's it - we've processed all the source commits, and we've inserted all the necessary target commits.
|
// OK, that's it - we've processed all the source commits, and we've inserted all the necessary target commits.
|
||||||
// We can just `git push` to the target repo now.
|
// We can just `git push` to the target repo now.
|
||||||
//
|
//
|
||||||
// But I'm gonna do a bunch more dry-run testing before I do that!
|
// Note that it must be a `-f`, because we are literally rewriting history.
|
||||||
if (!dryRun) {
|
if (!dryRun) {
|
||||||
execSync(`git push https://unused-username:${tokenForTargetRepo}@${targetRepo.domain}/${targetRepo.owner}/${targetRepo.name}`, {
|
execSync(`git push -f https://unused-username:${tokenForTargetRepo}@${targetRepo.domain}/${targetRepo.owner}/${targetRepo.name}`, {
|
||||||
cwd: TARGET_DIR
|
cwd: TARGET_DIR
|
||||||
})
|
})
|
||||||
// TODO - it'd be nice - before this `git push` is probably best - to add a `README.md` comment acknowledging
|
// TODO - it'd be nice - before this `git push` is probably best - to add a `README.md` comment acknowledging
|
||||||
|
Loading…
x
Reference in New Issue
Block a user