Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Here are some steps you can follow to get the git daemon running under Windows:</p> <p><em>(Prerequisites: A default Cygwin installation and a git client that supports git daemon)</em></p> <p><strong>Step 1</strong>: Open a bash shell</p> <p><strong>Step 2</strong>: In the directory /cygdrive/c/cygwin64/usr/local/bin/, create a file named "gitd" with the following content:</p> <pre><code>#!/bin/bash /usr/bin/git daemon --reuseaddr --base-path=/git --export-all --verbose --enable=receive-pack </code></pre> <p><strong>Step 3</strong>: Run the following cygrunsrv command from an elevated prompt (i.e. as admin) to install the script as a service (Note: assumes Cygwin is installed at C:\cygwin64):</p> <pre><code>cygrunsrv --install gitd \ --path c:/cygwin64/bin/bash.exe \ --args c:/cygwin64/usr/local/bin/gitd \ --desc "Git Daemon" \ --neverexits \ --shutdown </code></pre> <p><strong>Step 4</strong>: Run the following command to start the service:</p> <p>cygrunsrv --start gitd</p> <p>You are done. If you want to test it, here is a quick and dirty script that shows that you can push over the git protocol to your local machine:</p> <pre><code>#!/bin/bash echo "Creating main git repo ..." mkdir -p /git/testapp.git cd /git/testapp.git git init --bare touch git-daemon-export-ok echo "Creating local repo ..." cd mkdir testapp cd testapp git init echo "Creating test file ..." touch testfile git add -A git commit -m 'Test message' echo "Pushing master to main repo ..." git push git://localhost/testapp.git master </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload