No symlink, fail when not in GOPATH

master
Harshavardhana 10 years ago
parent 2bc7ded828
commit 79455c3f9d
  1. 20
      CONTRIBUTING.md
  2. 12
      Makefile

@ -1,6 +1,8 @@
### Setup your Minio Github Repository
Fork [Minio upstream](https://github.com/Minio-io/minio/fork) source repository to your own personal repository. Copy the URL and pass it to ``go get`` command. Go uses git to clone a copy into your project workspace folder.
```sh
$ mkdir -p $GOPATH/src/github.com/minio-io
$ cd $GOPATH/src/github.com/minio-io
$ git clone https://github.com/$USER_ID/minio
$ cd minio
```
@ -19,6 +21,24 @@ Building Libraries
...
```
### Setting up git remote as ``upstream``
```sh
$ cd $GOPATH/src/github.com/minio-io/minio
$ git remote add upstream https://github.com/minio-io/minio
$ git fetch upstream
$ git merge upstream/master
...
...
$ make
Checking if proper environment variables are set.. Done
...
Checking dependencies for Minio.. Done
Installed godep
Installed cover
Building Libraries
...
```
### Developer Guidelines
``Minio`` community welcomes your contribution. To make the process as seamless as possible, we ask for the following:
* Go ahead and fork the project and make your changes. We encourage pull requests to discuss code changes.

@ -1,18 +1,20 @@
MINIOPATH=$(GOPATH)/src/github.com/minio-io/minio
all: getdeps install
checkdeps:
@echo "Checking deps.."
@(env bash $(PWD)/devscripts/checkdeps.sh)
createsymlink:
@mkdir -p $(GOPATH)/src/github.com/minio-io/;
@if test ! -e $(GOPATH)/src/github.com/minio-io/minio; then echo "Creating symlink to $(GOPATH)/src/github.com/minio-io/minio" && ln -s $(PWD) $(GOPATH)/src/github.com/minio-io/minio; fi
checkgopath:
@echo "Checking project in ${MINIOPATH}"
@if [ ! -d ${MINIOPATH} ]; then echo "Project not found in $GOPATH, please follow instructions provided at https://github.com/Minio-io/minio/blob/master/CONTRIBUTING.md#setup-your-minio-github-repository" && exit 1; fi
getdeps: checkdeps
getdeps: checkdeps checkgopath
@go get github.com/tools/godep && echo "Installed godep"
@go get golang.org/x/tools/cmd/cover && echo "Installed cover"
build-all: getdeps createsymlink
build-all: getdeps
@echo "Building Libraries"
@godep go generate ./...
@godep go build ./...

Loading…
Cancel
Save