3. it only had to handle three commands in the line-based protocol.

I've changed the function names from git-remote-bsv below, for
clarity. The processes are meant to be run on the remote server, so
it's backward.

"capabilities\n" -> "connect\n\n"
"connect git-upload-pack\n" -> remote_uploads_to_us()
"connect git-receive-pack\n" -> remote_receives_from_us()

"connect" expects a process to be launched on the remote, with
stdin/stdout piped.

4. for both commands, first I synced the shadow dir called
"mirror_dir" down from the remote. this ensured it was a canonical
copy. I downloaded these files and dirs:

    /description
    /config
    /info
    /refs
    /HEAD
    /packed-refs

I additionally downloaded /objects, but I made sure not to overwrite
files that were newer locally, and if there were multiple copies on
the chain, I made sure to always pick the oldest one, to retain
integrity if a private key were compromised.

In case the repository had not refs remotely, or wasn't present
remotely, I then instantiated a refs folder:
140    fse.ensureDirSync(mirror_path + '/refs')
  • [ot][spam][crazy] git-remot... Undiscussed Horrific Abuse, One Victim of Many
    • Re: [ot][spam][crazy] ... Undiscussed Horrific Abuse, One Victim of Many
      • Re: [ot][spam][cra... Undiscussed Horrific Abuse, One Victim of Many
        • Re: [ot][spam]... Undiscussed Horrific Abuse, One Victim of Many
          • Re: [ot][s... Undiscussed Horrific Abuse, One Victim of Many
            • Re: [... Undiscussed Horrific Abuse, One Victim of Many
              • R... Undiscussed Horrific Abuse, One Victim of Many
                • ... Undiscussed Horrific Abuse, One Victim of Many
                • ... Undiscussed Horrific Abuse, One Victim of Many
                • ... Undiscussed Horrific Abuse, One Victim of Many
                • ... Undiscussed Horrific Abuse, One Victim of Many

Reply via email to