From 46081de3d5b6bfbf80daf8bf11a7d8f72592afb1 Mon Sep 17 00:00:00 2001 From: dzdidi Date: Thu, 18 Jan 2024 11:26:52 +0000 Subject: [PATCH] TODO comments Signed-off-by: dzdidi --- src/git-remote-pear.js | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/git-remote-pear.js b/src/git-remote-pear.js index 2822cea..60e98b2 100755 --- a/src/git-remote-pear.js +++ b/src/git-remote-pear.js @@ -73,13 +73,27 @@ async function talkToGit (refs, drive) { process.stdout.write('list\n') process.stdout.write('push\n') process.stdout.write('fetch\n\n') - } else if (chunk && chunk.search(/^push/) !== -1) { + } else if (chunk && chunk.search(/^push/) !== -1) {j const [_command, path] = chunk.split(' ') const [src, dst] = path.split(':') const isDelete = !src const isForce = src.startsWith('+') + // TODO: options: + // ---- push by pull ---- + // - init for share (daemon, etc) + // - push branch to local remote + // - send rpc command to origin + // Mapping of RPC commands to git commands on origin: + // - normal push - git pull + // - force push - git reset --hard / + // - delete branch - git branch -D / + // + // ---- push by push ---- + // + // + process.stdout.write('\n\n') process.exit(0) } else if (chunk && chunk.search(/^list/) !== -1) { // list && list for-push