docs: improve windows.md
This add a lot of steps that were missing and makes it possible to build on Windows. License: MIT Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Christian Couder committed
Feb 12, 2016 at 22:22 UTC
912623ed25bcc1745214216442392e5319f178d7
1 file changed
+46
-1
docs/windows.md
+46
-1
@@ -1,5 +1,50 @@
1
# Building on Windows
2
3
+## Install Git For Windows
4
+
5
+As Git is used by the Go language to download dependencies, you need
6
+to install Git, for example from http://git-scm.com/.
7
+
8
+You also must make sure that the directory that contains the Git For
9
+Windows binary is in the Path environment variable. Note that Git For
10
+Windows has a 'git' binary in a 'Git\bin' directory and another one in
11
+a 'Git\cmd' directory. You should only put the 'Git\cmd' directory in
12
+the Path environment variable.
13
+
14
+## Install Go
15
+
16
+Please install the Go language as explained on
17
+https://golang.org/doc/install.
18
+
19
+You must make sure that the GOROOT environment variable is set and
20
+that the %GOROOT%/bin directory is in the Path environment variable.
21
+
22
+The GOPATH environment variable should also be set to a directory that
23
+you have created, and the %GOPATH/bin directory should also be in the
24
+Path environment variable.
25
+
26
+## Download go-ipfs and its dependencies
27
+
28
+The following commands should download or update go-ipfs and its
29
+dependencies:
30
+
31
+```sh
32
+go get -u github.com/whyrusleeping/gx
33
+go get -u github.com/whyrusleeping/gx-go
34
+go get -u github.com/ipfs/go-ipfs
35
+cd %GOPATH%/src/github.com/ipfs/go-ipfs
36
+gx --verbose install --global
37
+```
38
+
39
+If you get authentication problems with Git, you might want to take a
40
+look at
41
+https://help.github.com/articles/caching-your-github-password-in-git/
42
+and use the suggested solution:
43
+
44
+```sh
45
+git config --global credential.helper wincred
46
+```
47
+
48
## Build
49
50
Fuse is not supported for Windows, so you need to build IPFS without Fuse:
@@ -10,4 +55,4 @@ go build -tags nofuse ./cmd/ipfs
55
56
## TODO
57
13
-Add more instructions on setting up the golang environment on Windows
58
+Fix the "Build" section to pass the current commit as the Makefile does.