From eb4828d28d5966238ed6d4eeab63e36027fa6565 Mon Sep 17 00:00:00 2001 From: Steven Allen Date: Wed, 5 Jun 2019 16:07:13 -0700 Subject: [PATCH 1/3] doc: tell windows users to use the pre-built version if possible. --- docs/windows.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/windows.md b/docs/windows.md index 2687805e202..abe151c4769 100644 --- a/docs/windows.md +++ b/docs/windows.md @@ -1,6 +1,8 @@ # Building on Windows ![](https://ipfs.io/ipfs/QmccXW7JSZMVXidSc7tHsU6aktuaiV923q4yBGHUsdymYo/build.gif) +If you just want to install go-ipfs, please download it from https://dist.ipfs.io/#go-ipfs. This document explains how to build it from source. + ## Install Go `go-ipfs` is built on Golang and thus depends on it for all building methods. https://golang.org/doc/install From dd9cae7f04b9bab9fb7fd47e27e31dd9ab826767 Mon Sep 17 00:00:00 2001 From: Steven Allen Date: Wed, 5 Jun 2019 16:11:01 -0700 Subject: [PATCH 2/3] doc: remove mentions of gx --- docs/windows.md | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) diff --git a/docs/windows.md b/docs/windows.md index abe151c4769..4487e64ffe9 100644 --- a/docs/windows.md +++ b/docs/windows.md @@ -105,27 +105,20 @@ SETX PATH %PATH% ``` ## Minimal -While it's possible to build `go-ipfs` with `go` alone, we'll be using `git` and `gx` for practical source management. -You can use whichever version of `git` you wish but we recommend the Windows builds at . `git` must be in your [`PATH`](https://ss64.com/nt/path.html) for `go get` to recognize and use it. -### `gx` -You may install prebuilt binaries for [`gx`](https://dist.ipfs.io/#gx) & [`gx-go`](https://dist.ipfs.io/#gx-go) if they're available for your platform. -Alternatively, you can build them from source and install them to `%GOPATH%\bin` by running the following: +While it's possible to build `go-ipfs` with `go` alone, we'll be using `git` to fetch the source. -``` -go get -u github.com/whyrusleeping/gx -go get -u github.com/whyrusleeping/gx-go -``` +You can use whichever version of `git` you wish but we recommend the Windows builds at . `git` must be in your [`PATH`](https://ss64.com/nt/path.html) for `go get` to recognize and use it. + +### go-ipfs -### `go-ipfs` +Clone and change directory to the source code, if you haven't already: ``` -SET PATH=%PATH%;%GOPATH%\bin -go get -u -d github.com/ipfs/go-ipfs -cd %GOPATH%/src/github.com/ipfs/go-ipfs -gx --verbose install --global -cd cmd\ipfs +git clone https://github.com/ipfs/go-ipfs %GOPATH%/src/github.com/ipfs/go-ipfs +cd %GOPATH%/src/github.com/ipfs/go-ipfs/cmd/ipfs ``` + We need the `git` commit hash to be included in our build so that in the extremely rare event a bug is found, we have a reference point later for tracking it. We'll ask `git` for it and store it in a variable. The syntax for the next command is different depending on whether you're using the interactive command line or writing a batch file. Use the one that applies to you. - interactive: `FOR /F %V IN ('git rev-parse --short HEAD') do set SHA=%V` - interpreter: `FOR /F %%V IN ('git rev-parse --short HEAD') do set SHA=%%V` From f6ea84952909d1a78cf9bf40d687a6496a989810 Mon Sep 17 00:00:00 2001 From: Dominic Della Valle Date: Wed, 5 Jun 2019 19:57:39 -0400 Subject: [PATCH 3/3] doc: add Windows packages to README --- README.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/README.md b/README.md index 11e63a11485..a4af02c0787 100644 --- a/README.md +++ b/README.md @@ -114,6 +114,18 @@ With snap, in any of the [supported Linux distributions](https://snapcraft.io/do $ sudo snap install ipfs ``` +### From Windows package managers + +- [Chocolatey](#chocolatey) + +#### Chocolatey + +The package [ipfs](https://chocolatey.org/packages/ipfs) currently points to go-ipfs and is being maintained. + +```Powershell +PS> choco install ipfs +``` + ### Build from Source #### Install Go