[ot][spam][crazy] git-remote-bsv

Undiscussed Horrific Abuse, One Victim of Many gmkarl at gmail.com
Sat May 14 12:51:33 PDT 2022


1: if there was private key information, i configured separate push
url and pull urls, only if they weren't already configured

      if (child_process.spawnSync('git', ['config', '--get', 'remote.'
+ remotename + '.pushurl']).stdout.length === 0) {
        child_process.spawnSync('git', ['remote', 'set-url', '--push',
remotename, origurl])
        child_process.spawnSync('git', ['remote', 'set-url',
remotename, origurl.replace(privkey, addr)])
      }

2. i defined two shadow folders: one for git to sync with, and another
for the uploader to upload from

  const bsv_path = path.join(GIT_DIR, 'bsv', addr)
  const mirror_path = path.join(bsv_path, 'git.' +
crypto.createHash('sha256').update(urlparts.join(path.sep)).digest('hex'))
  const mirror_path_new = path.join(bsv_path, 'git.new')


More information about the cypherpunks mailing list