Skip to content

Commit

Permalink
feat(makefile): added make build command
Browse files Browse the repository at this point in the history
also updated readme to add build instructions
  • Loading branch information
b5 committed Jan 31, 2018
1 parent 0640edd commit cc6b26a
Show file tree
Hide file tree
Showing 3 changed files with 67 additions and 11 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,5 @@ RUN mkdir -p $IPFS_PATH && mkdir -p $QRI_PATH \
# VOLUME $IPFS_PATH
# VOLUME $QRI_PATH

# Set binary as entrypoint, initalizing ipfs repo if none is mounted
# Set binary as entrypoint, initalizing ipfs & qri repos if none is mounted
CMD ["qri", "connect", "--setup"]
36 changes: 29 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,43 @@ GOPACKAGES = $(shell go list ./... | grep -v /vendor/ | grep qri/core)

default: build

build:
@# install non-gx deps
go get -v github.com/briandowns/spinner github.com/datatogether/api/apiutil github.com/fatih/color github.com/ipfs/go-datastore github.com/olekukonko/tablewriter github.com/qri-io/analytics github.com/qri-io/bleve github.com/qri-io/dataset github.com/qri-io/doggos github.com/sirupsen/logrus github.com/spf13/cobra github.com/spf13/viper github.com/qri-io/varName github.com/qri-io/datasetDiffer github.com/datatogether/cdxj
@# install gx
go get -v -u github.com/whyrusleeping/gx github.com/whyrusleeping/gx-go
@# install gx deps. This will take time.
gx install
@# install deps with gx depenencies
go get github.com/qri-io/cafs
@# build the thing
go build

install-deps:
go get -v github.com/briandowns/spinner github.com/datatogether/api/apiutil github.com/fatih/color github.com/ipfs/go-datastore github.com/olekukonko/tablewriter github.com/qri-io/analytics github.com/qri-io/bleve github.com/qri-io/dataset github.com/qri-io/doggos github.com/sirupsen/logrus github.com/spf13/cobra github.com/spf13/viper github.com/qri-io/varName github.com/qri-io/datasetDiffer github.com/datatogether/cdxj

install-gx:
go get -v -u github.com/whyrusleeping/gx github.com/whyrusleeping/gx-go

install-gx-deps:
gx install

workdir:
mkdir -p workdir

build: workdir/qri
# build: workdir/qri

# build-native: $(GOFILES)
# go build -o workdir/native-qri .

build-native: $(GOFILES)
go build -o workdir/native-qri .
# workdir/qri: $(GOFILES)
# GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -o workdir/qri .

workdir/qri: $(GOFILES)
GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -o workdir/qri .
lint:
golint ./...

test: test-all
test:
go test ./...

test-all:
test-all-coverage:
./.circleci/cover.test.sh
40 changes: 37 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,54 @@
# qri
# [qri](http://qri.io)

[![Qri](https://img.shields.io/badge/made%20by-qri-magenta.svg?style=flat-square)](https://qri.io)
[![GoDoc](https://godoc.org/github.com/qri-io/qri?status.svg)](http://godoc.org/github.com/qri-io/qri)
[![License](https://img.shields.io/github/license/qri-io/qri.svg?style=flat-square)](./LICENSE)
[![Codecov](https://img.shields.io/codecov/c/github/qri-io/qri.svg?style=flat-square)](https://codecov.io/gh/qri-io/qri)
[![CI](https://img.shields.io/circleci/project/github/qri-io/qri.svg?style=flat-square)](https://circleci.com/gh/qri-io/qri)

Frictionless distributed data.
qri (“query”) animates data stored on the distributed web to work like a database.
#### qri is a global dataset version control system (GDVCS) built on the distributed web

Breaking that down:

- **global** so that if *anyone, anywhere* has published work with the same or similar datasets, you can discover it.
- Specific to **datasets** to ****solve the friction problem. datasets on qri work with each other by default
- **version control** to keep data in sync, attributing all changes to authors
- On the **distributed web** to make *all* of the data published on qri simultaneously available to on the network

If you’re unfamiliar with *version control,* particularly the distributed kind, well you're probably viewing this document on [github](https://github.com/qri-io/qri) — which is a version control system intended for code. Its underlying technology – git – popularized some magic sauce that has inspired a generation of programmers and popularized concepts at the heart of the distributed web. Qri is applying that family of concepts to four common data problems:

1. **Discovery** _Can I find data I’m looking for?_
2. **Trust** _Can I trust what I’ve found?_
3. **Friction** _Can I make this work with my other stuff?_
4. **Sync** _How do I handle changes in data?_

Using because qri is *global* and *content-addressed* adding data to qri also checks the entire network if someone has added it before. Because qri is focused solely on datasets, it can provide meaningful search results. Every change on qri is associated with a peer, creating a audit-able trail you can use to quickly see what has changed and who has changed it. All datasets on qri are automatically described at the time of ingest using a flexible schema that makes data naturally inter-operate. Qri comes with tools to turn *all* datasets on the network into a JSON API with a single command. Finally, all changes in qri are tracked & synced.

<p align="center">
<a href="https://asciinema.org/a/160303" target="_blank"><img src="https://asciinema.org/a/160303.png" width="654"/></a>
</p>

## Getting Involved

We would love involvement from more people! If you notice any errors or would
like to submit changes, please see our
[Contributing Guidelines](./.github/CONTRIBUTING.md).

## Building From Source

To build qri you'll need the [go programming language](https://golang.org) on your machine. then run:
```shell
$ go get github.com/qri-io/qri
$ cd $GOPATH/src/github.com/qri-io/qri
$ make build
```

It'll take a minute, but once everything's finished a new binary `qri` will appear in this directory. you should be able to run:
```shell
$ ./qri help
```
and see help output.

## Developing

We've set up a separate document for [developer guidelines](https://github.com/qri-io/qri/blob/master/DEVELOPERS.md)!

0 comments on commit cc6b26a

Please sign in to comment.