Skip to content

Commit

Permalink
Install instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
Paul Lhussiez committed May 21, 2019
1 parent 7000df9 commit e11d33f
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 0 deletions.
13 changes: 13 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
.DEFAULT_GOAL := build

export GO111MODULE=on
export CGO_ENABLED=false
BINARY=platypus
VERSION=$(shell git describe --abbrev=0 --tags 2> /dev/null || echo "0.1.0")
BUILD=$(shell git rev-parse HEAD 2> /dev/null || echo "undefined")
Expand All @@ -14,6 +15,10 @@ help:
build: ## Build
go build -o $(BINARY) $(LDFLAGS)

.PHONY: install
install: ## Build and install
go install $(LDFLAGS)

.PHONY: run
run: ## Runs the server
@go run $(LDFLAGS) main.go
Expand All @@ -30,6 +35,14 @@ test: ## Run the unit test suite
ttest: ## Run the unit test suite and parse it with tparse
go test -race -coverprofile="coverage.txt" ./... -json | tparse -all

.PHONY: release
release: ## Create a new release on Github
VERSION=$(VERSION) BUILD=$(BUILD) goreleaser

.PHONY: snapshot
snapshot: ## Create a new snapshot release
VERSION=$(VERSION) BUILD=$(BUILD) goreleaser --snapshot --rm-dist

.PHONY: clean
clean: ## Remove the binary
if [ -f $(BINARY) ] ; then rm $(BINARY) ; fi
Expand Down
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,23 @@ Platypus is a very simple mock server to abstract external services. It supports
CORS which is disabled by default but fully configurable. Platypus also allows
to respond with weighted responses.

## Install

You can install platypus by using directly the go command line:

```bash
$ go install github.com/Depado/platypus
```

Or if you wish to have the version information and such:

```
$ git clone git@github.com:Depado/platypus.git
$ make install
```

Or grab the latest release from the [release page](https://github.com/Depado/platypus/releases).

## Usage

```
Expand Down

0 comments on commit e11d33f

Please sign in to comment.