Browse Source

Badges and travis testing (#40)

* Added badges to the README

* Restructured the travis config
Thomas Boerger 3 years ago
parent
commit
42a744d9e6
3 changed files with 33 additions and 17 deletions
  1. 17 13
      .travis.yml
  2. 8 2
      README.md
  3. 8 2
      README_ZH.md

+ 17 - 13
.travis.yml

@@ -1,30 +1,34 @@
1 1
 language: go
2 2
 
3 3
 go:
4
-  - 1.4
5
-  - 1.5
6 4
   - 1.6
7 5
   - 1.7
8 6
 
9 7
 before_install:
10 8
   - sudo apt-get update -qq
11 9
   - sudo apt-get install -y libpam-dev
12
-  - go get github.com/msteinert/pam 
10
+  - go get github.com/msteinert/pam
13 11
 
14 12
 install:
15 13
   - go get -t -v ./...
16 14
 
17
-script: 
18
-  - go build -v -tags "pam"
19
-  - go test -v -cover -race ./...
15
+script: |
16
+  go build -v -tags "pam"
17
+
18
+  for pkg in $(go list ./... | grep -v /vendor/)
19
+  do
20
+    go test -v -race -cover -coverprofile $GOPATH/src/$pkg/coverage.out $pkg || exit 1
21
+  done
22
+
23
+after_success:
24
+  - bash <(curl -s https://codecov.io/bash)
20 25
 
21 26
 notifications:
22
-  email:
23
-    - u@gogs.io
24
-  slack: gophercn:o5pSanyTeNhnfYc3QnG0X7Wx
25 27
   webhooks:
28
+    on_success: change
29
+    on_failure: always
30
+    on_start: never
26 31
     urls:
27
-      - https://webhooks.gitter.im/e/b590f8e03882f7aedc3e
28
-    on_success: change 
29
-    on_failure: always 
30
-    on_start: never     
32
+      - https://webhooks.gitter.im/e/ee6b822f3cf54c98e70c
33
+      - https://webhooks.gitter.im/e/87428658ef177ce8a7e4
34
+      - https://webhooks.gitter.im/e/a1d2b69804dfda72187e

+ 8 - 2
README.md

@@ -1,5 +1,11 @@
1
-Gogs - Go Git Service [![Build Status](https://travis-ci.org/gogits/gogs.svg?branch=master)](https://travis-ci.org/gogits/gogs) [![Crowdin](https://d322cqt584bo4o.cloudfront.net/gogs/localized.svg)](https://crowdin.com/project/gogs) [![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/gogits/gogs?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
2
-=====================
1
+# Gitea - Git with a cup of tea
2
+
3
+[![Build Status](https://travis-ci.org/go-gitea/gitea.svg?branch=master)](https://travis-ci.org/go-gitea/gitea)
4
+[![codecov](https://codecov.io/gh/go-gitea/gitea/branch/master/graph/badge.svg)](https://codecov.io/gh/go-gitea/gitea)
5
+[![Go Report Card](https://goreportcard.com/badge/github.com/go-gitea/gitea)](https://goreportcard.com/report/github.com/go-gitea/gitea)
6
+[![GoDoc](https://godoc.org/github.com/go-gitea/gitea?status.svg)](https://godoc.org/github.com/go-gitea/gitea)
7
+[![](https://images.microbadger.com/badges/image/gitea/gitea.svg)](http://microbadger.com/images/gitea/gitea "Get your own image badge on microbadger.com")
8
+[![Join the chat at https://gitter.im/go-gitea/gitea](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/go-gitea/gitea?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
3 9
 
4 10
 ![](https://github.com/go-gitea/gitea/blob/master/public/img/gogs-large-resize.png?raw=true)
5 11
 

+ 8 - 2
README_ZH.md

@@ -1,5 +1,11 @@
1
-Gogs - Go Git Service [![Build Status](https://travis-ci.org/gogits/gogs.svg?branch=master)](https://travis-ci.org/gogits/gogs)
2
-=====================
1
+# Gitea - Git with a cup of tea
2
+
3
+[![Build Status](https://travis-ci.org/go-gitea/gitea.svg?branch=master)](https://travis-ci.org/go-gitea/gitea)
4
+[![codecov](https://codecov.io/gh/go-gitea/gitea/branch/master/graph/badge.svg)](https://codecov.io/gh/go-gitea/gitea)
5
+[![Go Report Card](https://goreportcard.com/badge/github.com/go-gitea/gitea)](https://goreportcard.com/report/github.com/go-gitea/gitea)
6
+[![GoDoc](https://godoc.org/github.com/go-gitea/gitea?status.svg)](https://godoc.org/github.com/go-gitea/gitea)
7
+[![](https://images.microbadger.com/badges/image/gitea/gitea.svg)](http://microbadger.com/images/gitea/gitea "Get your own image badge on microbadger.com")
8
+[![Join the chat at https://gitter.im/go-gitea/gitea](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/go-gitea/gitea?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
3 9
 
4 10
 Gogs (Go Git Service) 是一款极易搭建的自助 Git 服务。
5 11