Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
cashier
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Kevin Lyda
cashier
Commits
8ab6dc32
Commit
8ab6dc32
authored
6 years ago
by
Niall Sheridan
Browse files
Options
Downloads
Patches
Plain Diff
Switch to a Makefile
parent
e2b4c388
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
.travis.yml
+2
-2
2 additions, 2 deletions
.travis.yml
Makefile
+33
-0
33 additions, 0 deletions
Makefile
regen.sh
+0
-11
0 additions, 11 deletions
regen.sh
run_tests.sh
+0
-16
0 additions, 16 deletions
run_tests.sh
with
35 additions
and
29 deletions
.travis.yml
+
2
−
2
View file @
8ab6dc32
...
@@ -15,7 +15,7 @@ matrix:
...
@@ -15,7 +15,7 @@ matrix:
-
go
:
tip
-
go
:
tip
before_install
:
before_install
:
-
go get -v github.com/golang/lint/golint
-
make dep
install
:
install
:
-
go version
-
go version
...
@@ -25,4 +25,4 @@ before_script:
...
@@ -25,4 +25,4 @@ before_script:
sudo
:
false
sudo
:
false
script
:
script
:
-
./run_tests.sh
-
make test
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Makefile
0 → 100644
+
33
−
0
View file @
8ab6dc32
CASHIER_CMD
:=
./cmd/cashier
CASHIER_BIN
:=
./cashier
CASHIERD_BIN
:=
./cashierd
CASHIERD_CMD
:=
./cmd/cashierd
SRC_FILES
=
$(
shell find
*
-type
f
-name
'*.go'
-not
-path
'vendor/*'
-not
-name
'a_*-packr.go'
)
all
:
test build
test
:
dep
go
test
./...
go
install
-race
$(
CASHIER_CMD
)
$(
CASHIERD_CMD
)
go vet ./...
go list ./... |egrep
-v
'vendor/|proto$$'
|xargs
-L1
golint
-set_exit_status
gofmt
-d
$(
SRC_FILES
)
build
:
cashier cashierd
generate
:
go generate
-x
./...
cashier
:
go build
-o
cashier
$(
CASHIER_CMD
)
cashierd
:
generate
go build
-o
cashierd
$(
CASHIERD_CMD
)
clean
:
rm
-f
cashier cashierd
dep
:
go get
-u
github.com/golang/lint/golint
.PHONY
:
dep generate test cashier cashierd
\ No newline at end of file
This diff is collapsed.
Click to expand it.
regen.sh
deleted
100755 → 0
+
0
−
11
View file @
e2b4c388
#!/bin/bash
# Run this script from the root of the repo to regenerate static content.
set
-xue
go get
-u
github.com/mjibson/esc
${
GOPATH
}
/bin/esc
-ignore
'\.go'
-prefix
'server'
\
-o
'server/static/static.go'
-pkg
'static'
'server/static'
go get
-u
github.com/golang/protobuf/protoc-gen-go
protoc
--go_out
=
plugins
=
grpc:. proto/signer.proto
This diff is collapsed.
Click to expand it.
run_tests.sh
deleted
100755 → 0
+
0
−
16
View file @
e2b4c388
#! /bin/sh
# This can be used as a pre-commit script. Just run
# cp run_tests.sh .git/hooks/pre-commit
# and it will run before each commit.
set
-xue
go
install
-race
-v
./cmd/cashier ./cmd/cashierd
go list ./... |grep
-v
vendor/ |xargs go
test
-race
gofmt
-d
$(
find
*
-type
f
-name
'*.go'
-not
-path
'vendor/*'
)
go list ./... |grep
-v
vendor/ |xargs go vet
if
!
type
-f
golint
>
/dev/null
;
then
go get
-u
github.com/golang/lint/golint
fi
go list ./... |egrep
-v
'vendor/|proto$'
|xargs
-L1
golint
-set_exit_status
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment