Skip to content

Commit eac4d7b

Browse files
authored
Merge pull request #175 from vmarkovtsev/master
Language stats
2 parents 71227aa + a4f96b2 commit eac4d7b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+827
-342
lines changed

.appveyor.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ version: "{build}"
22
platform: x64
33
image: Visual Studio 2017
44

5-
clone_folder: c:\gopath\src\gopkg.in\src-d\hercules.v6
5+
clone_folder: c:\gopath\src\gopkg.in\src-d\hercules.v7
66

77
environment:
88
GOPATH: c:\gopath
@@ -16,14 +16,14 @@ build_script:
1616
- go version
1717
- set PATH=C:\mingw-w64\x86_64-7.2.0-posix-seh-rt_v5-rev1\mingw64\bin;C:\msys64\usr\bin;C:\msys64\mingw64\bin;%GOPATH%\bin;%PATH%
1818
- set PATH=%PATH:C:\Program Files\Git\usr\bin;=%
19-
- cd %GOPATH%\src\gopkg.in\src-d\hercules.v6
19+
- cd %GOPATH%\src\gopkg.in\src-d\hercules.v7
2020
- go get -v github.com/golang/dep/cmd/dep
2121
- make
22-
- 7z a c:\gopath\src\gopkg.in\src-d\hercules.v6\hercules.win64.zip %GOPATH%\bin\hercules.exe
22+
- 7z a c:\gopath\src\gopkg.in\src-d\hercules.v7\hercules.win64.zip %GOPATH%\bin\hercules.exe
2323

2424
test_script:
25-
- go get -v -t -d gopkg.in/src-d/hercules.v6/...
26-
- go test -v -tags disable_babelfish gopkg.in/src-d/hercules.v6/...
25+
- go get -v -t -d gopkg.in/src-d/hercules.v7/...
26+
- go test -v -tags disable_babelfish gopkg.in/src-d/hercules.v7/...
2727

2828
artifacts:
2929
- name: hercules.win64.zip

.travis.yml

+8-8
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ git:
55
depth: 9999999
66

77
language: go
8-
go_import_path: gopkg.in/src-d/hercules.v6
8+
go_import_path: gopkg.in/src-d/hercules.v7
99
go:
1010
- 1.10.x
1111
- 1.11.x
@@ -24,10 +24,10 @@ cache:
2424
- $HOME/gopath/src
2525
before_cache:
2626
- cd $HOME/gopath
27-
- mv $HOME/gopath/src/gopkg.in/src-d/hercules.v6/vendor $HOME/gopath/src/gopkg.in/src-d/.vendor
28-
- rm -rf $HOME/gopath/src/gopkg.in/src-d/hercules.v6
29-
- mkdir $HOME/gopath/src/gopkg.in/src-d/hercules.v6
30-
- mv $HOME/gopath/src/gopkg.in/src-d/.vendor $HOME/gopath/src/gopkg.in/src-d/hercules.v6/vendor
27+
- mv $HOME/gopath/src/gopkg.in/src-d/hercules.v7/vendor $HOME/gopath/src/gopkg.in/src-d/.vendor
28+
- rm -rf $HOME/gopath/src/gopkg.in/src-d/hercules.v7
29+
- mkdir $HOME/gopath/src/gopkg.in/src-d/hercules.v7
30+
- mv $HOME/gopath/src/gopkg.in/src-d/.vendor $HOME/gopath/src/gopkg.in/src-d/hercules.v7/vendor
3131

3232
matrix:
3333
fast_finish: true
@@ -69,7 +69,7 @@ script:
6969
- go vet -tags tensorflow ./...
7070
- golint -set_exit_status $(go list ./... | grep -v /vendor/)
7171
- flake8
72-
- go test -coverpkg=all -v -coverprofile=coverage.txt -covermode=count gopkg.in/src-d/hercules.v6/... && sed -i '/cmd\/hercules\|core.go/d' coverage.txt
72+
- go test -coverpkg=all -v -coverprofile=coverage.txt -covermode=count gopkg.in/src-d/hercules.v7/... && sed -i '/cmd\/hercules\|core.go/d' coverage.txt
7373
- $GOPATH/bin/hercules version
7474
- $GOPATH/bin/hercules --burndown --couples --devs --quiet --pb https://github.com/src-d/hercules > 1.pb
7575
- cp 1.pb 2.pb
@@ -95,7 +95,7 @@ jobs:
9595
os: osx
9696
osx_image: xcode9.3
9797
go: 1.11.x
98-
go_import_path: gopkg.in/src-d/hercules.v6
98+
go_import_path: gopkg.in/src-d/hercules.v7
9999
before_install:
100100
- wget -O protoc.zip https://github.com/google/protobuf/releases/download/v$PROTOC_VERSION/protoc-$PROTOC_VERSION-osx-x86_64.zip
101101
- unzip -d ~/.local protoc.zip && rm protoc.zip
@@ -117,7 +117,7 @@ jobs:
117117
- stage: deploy
118118
os: linux
119119
go: 1.11.x
120-
go_import_path: gopkg.in/src-d/hercules.v6
120+
go_import_path: gopkg.in/src-d/hercules.v7
121121
before_install:
122122
- wget -O protoc.zip https://github.com/google/protobuf/releases/download/v$PROTOC_VERSION/protoc-$PROTOC_VERSION-linux-x86_64.zip
123123
- unzip -d ~/.local protoc.zip && rm protoc.zip

Dockerfile

+4-4
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ FROM ubuntu:18.04
33
ENV GOPATH /root
44
ENV PROTOBUF_VERSION 3.5.1
55

6-
COPY . /root/src/gopkg.in/src-d/hercules.v6
6+
COPY . /root/src/gopkg.in/src-d/hercules.v7
77
RUN apt-get update && \
88
apt-get install -y --no-install-suggests --no-install-recommends software-properties-common && \
99
add-apt-repository -y ppa:gophers/archive && \
@@ -14,13 +14,13 @@ RUN apt-get update && \
1414
locale-gen en_US.UTF-8 && \
1515
export PATH=/usr/lib/go-1.10/bin:/root/bin:$PATH && \
1616
go get -v github.com/golang/dep/cmd/dep && \
17-
cd /root/src/gopkg.in/src-d/hercules.v6 && \
17+
cd /root/src/gopkg.in/src-d/hercules.v7 && \
1818
export CGO_CXXFLAGS=-std=c++14 && \
1919
curl -L "https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-cpu-$(go env GOOS)-x86_64-1.7.0.tar.gz" | tar -C /usr/local -xz && \
2020
make && \
2121
rm /usr/local/bin/protoc && rm /usr/local/readme.txt && rm -rf /usr/local/include/google && \
2222
cp /root/bin/hercules /usr/local/bin && \
23-
cp -r /root/src/gopkg.in/src-d/hercules.v6/*.py /root/src/gopkg.in/src-d/hercules.v6/internal /usr/local/bin && \
23+
cp -r /root/src/gopkg.in/src-d/hercules.v7/*.py /root/src/gopkg.in/src-d/hercules.v7/internal /usr/local/bin && \
2424
sed -i 's/parser.add_argument("--backend",/parser.add_argument("--backend", default="Agg",/' /usr/local/bin/labours.py && \
2525
echo '#!/bin/bash\n\
2626
\n\
@@ -30,7 +30,7 @@ echo\n\' > /browser && \
3030
chmod +x /browser && \
3131
curl https://bootstrap.pypa.io/get-pip.py | python3 - pip==18.1 && \
3232
pip3 install --no-cache-dir --no-build-isolation cython && \
33-
pip3 install --no-cache-dir --no-build-isolation -r /root/src/gopkg.in/src-d/hercules.v6/requirements.txt https://github.com/mind/wheels/releases/download/tf1.7-cpu/tensorflow-1.7.0-cp36-cp36m-linux_x86_64.whl && \
33+
pip3 install --no-cache-dir --no-build-isolation -r /root/src/gopkg.in/src-d/hercules.v7/requirements.txt https://github.com/mind/wheels/releases/download/tf1.7-cpu/tensorflow-1.7.0-cp36-cp36m-linux_x86_64.whl && \
3434
rm -rf /root/* && \
3535
apt-get remove -y software-properties-common golang-1.10-go python3-dev libyaml-dev libxml2-dev curl git make unzip g++ && \
3636
apt-get remove -y *-doc *-man && \

Makefile

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ BBLFSH_DEP =
1111
all: ${GOPATH}/bin/hercules${EXE}
1212

1313
test: all
14-
go test gopkg.in/src-d/hercules.v6
14+
go test gopkg.in/src-d/hercules.v7
1515

1616
${GOPATH}/bin/protoc-gen-gogo${EXE}:
1717
go get -v github.com/gogo/protobuf/protoc-gen-gogo
@@ -42,4 +42,4 @@ vendor/gopkg.in/bblfsh/client-go.v2/tools/include:
4242
endif
4343

4444
${GOPATH}/bin/hercules${EXE}: vendor *.go */*.go */*/*.go */*/*/*.go internal/pb/pb.pb.go internal/pb/pb_pb2.py cmd/hercules/plugin_template_source.go ${BBLFSH_DEP}
45-
go get -tags "$(TAGS)" -ldflags "-X gopkg.in/src-d/hercules.v6.BinaryGitHash=$(shell git rev-parse HEAD)" gopkg.in/src-d/hercules.v6/cmd/hercules
45+
go get -tags "$(TAGS)" -ldflags "-X gopkg.in/src-d/hercules.v7.BinaryGitHash=$(shell git rev-parse HEAD)" gopkg.in/src-d/hercules.v7/cmd/hercules

README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<h1 align="center">Hercules</h1>
55
<p align="center">
66
Fast, insightful and highly customizable Git history analysis.<br><br>
7-
<a href="http://godoc.org/gopkg.in/src-d/hercules.v6"><img src="https://godoc.org/gopkg.in/src-d/hercules.v6?status.svg" alt="GoDoc"></a>
7+
<a href="http://godoc.org/gopkg.in/src-d/hercules.v7"><img src="https://godoc.org/gopkg.in/src-d/hercules.v7?status.svg" alt="GoDoc"></a>
88
<a href="https://travis-ci.org/src-d/hercules"><img src="https://travis-ci.org/src-d/hercules.svg?branch=master" alt="Travis build Status"></a>
99
<a href="https://ci.appveyor.com/project/vmarkovtsev/hercules"><img src="https://ci.appveyor.com/api/projects/status/49f0lm3v2y6xyph3?svg=true" alt="AppVeyor build status"></a>
1010
<a href="https://hub.docker.com/r/srcd/hercules"><img src="https://img.shields.io/docker/build/srcd/hercules.svg" alt="Docker build status"></a>
@@ -59,8 +59,8 @@ Numpy and Scipy can be installed on Windows using http://www.lfd.uci.edu/~gohlke
5959
You are going to need Go (>= v1.10), [`protoc`](https://github.com/google/protobuf/releases),
6060
and [`dep`](https://github.com/golang/dep).
6161
```
62-
go get -d gopkg.in/src-d/hercules.v6/cmd/hercules
63-
cd $GOPATH/src/gopkg.in/src-d/hercules.v6
62+
go get -d gopkg.in/src-d/hercules.v7/cmd/hercules
63+
cd $GOPATH/src/gopkg.in/src-d/hercules.v7
6464
make
6565
```
6666

cmd/hercules/combine.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ import (
1212

1313
"github.com/gogo/protobuf/proto"
1414
"github.com/spf13/cobra"
15-
"gopkg.in/src-d/hercules.v6"
16-
"gopkg.in/src-d/hercules.v6/internal/pb"
15+
"gopkg.in/src-d/hercules.v7"
16+
"gopkg.in/src-d/hercules.v7/internal/pb"
1717
)
1818

1919
// combineCmd represents the combine command

cmd/hercules/plugin.template

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ import (
2424

2525
"github.com/gogo/protobuf/proto"
2626
"gopkg.in/src-d/go-git.v4"
27-
"gopkg.in/src-d/hercules.v6"
27+
"gopkg.in/src-d/hercules.v7"
2828
)
2929

3030
// {{.name}} contains the intermediate state which is mutated by Consume(). It should implement

cmd/hercules/root.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@ import (
3434
"gopkg.in/src-d/go-git.v4/storage"
3535
"gopkg.in/src-d/go-git.v4/storage/filesystem"
3636
"gopkg.in/src-d/go-git.v4/storage/memory"
37-
"gopkg.in/src-d/hercules.v6"
38-
"gopkg.in/src-d/hercules.v6/internal/pb"
37+
"gopkg.in/src-d/hercules.v7"
38+
"gopkg.in/src-d/hercules.v7/internal/pb"
3939
)
4040

4141
// oneLineWriter splits the output data by lines and outputs one on top of another using '\r'.

contrib/_plugin_example/churn_analysis.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import (
1313
"gopkg.in/src-d/go-git.v4/plumbing"
1414
"gopkg.in/src-d/go-git.v4/plumbing/object"
1515
"gopkg.in/src-d/go-git.v4/utils/merkletrie"
16-
"gopkg.in/src-d/hercules.v6"
16+
"gopkg.in/src-d/hercules.v7"
1717
)
1818

1919
// ChurnAnalysis contains the intermediate state which is mutated by Consume(). It should implement

core.go

+6-6
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ import (
44
"github.com/spf13/pflag"
55
"gopkg.in/src-d/go-git.v4"
66
"gopkg.in/src-d/go-git.v4/plumbing/object"
7-
"gopkg.in/src-d/hercules.v6/internal/core"
8-
"gopkg.in/src-d/hercules.v6/internal/plumbing"
9-
"gopkg.in/src-d/hercules.v6/internal/plumbing/identity"
10-
"gopkg.in/src-d/hercules.v6/internal/plumbing/uast"
11-
"gopkg.in/src-d/hercules.v6/internal/yaml"
12-
"gopkg.in/src-d/hercules.v6/leaves"
7+
"gopkg.in/src-d/hercules.v7/internal/core"
8+
"gopkg.in/src-d/hercules.v7/internal/plumbing"
9+
"gopkg.in/src-d/hercules.v7/internal/plumbing/identity"
10+
"gopkg.in/src-d/hercules.v7/internal/plumbing/uast"
11+
"gopkg.in/src-d/hercules.v7/internal/yaml"
12+
"gopkg.in/src-d/hercules.v7/leaves"
1313
)
1414

1515
// ConfigurationOptionType represents the possible types of a ConfigurationOption's value.

internal/burndown/file.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ import (
55
"log"
66
"math"
77

8-
"gopkg.in/src-d/hercules.v6/internal"
9-
"gopkg.in/src-d/hercules.v6/internal/rbtree"
8+
"gopkg.in/src-d/hercules.v7/internal"
9+
"gopkg.in/src-d/hercules.v7/internal/rbtree"
1010
)
1111

1212
// Updater is the function which is called back on File.Update().

internal/burndown/file_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import (
66
"testing"
77

88
"github.com/stretchr/testify/assert"
9-
"gopkg.in/src-d/hercules.v6/internal/rbtree"
9+
"gopkg.in/src-d/hercules.v7/internal/rbtree"
1010
)
1111

1212
func updateStatusFile(status map[int]int64, _, previousTime, delta int) {

internal/core/forks.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import (
99

1010
"gopkg.in/src-d/go-git.v4/plumbing"
1111
"gopkg.in/src-d/go-git.v4/plumbing/object"
12-
"gopkg.in/src-d/hercules.v6/internal/toposort"
12+
"gopkg.in/src-d/hercules.v7/internal/toposort"
1313
)
1414

1515
// OneShotMergeProcessor provides the convenience method to consume merges only once.

internal/core/pipeline.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ import (
1818
"gopkg.in/src-d/go-git.v4/plumbing"
1919
"gopkg.in/src-d/go-git.v4/plumbing/object"
2020
"gopkg.in/src-d/go-git.v4/plumbing/storer"
21-
"gopkg.in/src-d/hercules.v6/internal/pb"
22-
"gopkg.in/src-d/hercules.v6/internal/toposort"
21+
"gopkg.in/src-d/hercules.v7/internal/pb"
22+
"gopkg.in/src-d/hercules.v7/internal/toposort"
2323
)
2424

2525
// ConfigurationOptionType represents the possible types of a ConfigurationOption's value.

internal/core/pipeline_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ import (
1414
"gopkg.in/src-d/go-git.v4"
1515
"gopkg.in/src-d/go-git.v4/plumbing"
1616
"gopkg.in/src-d/go-git.v4/plumbing/object"
17-
"gopkg.in/src-d/hercules.v6/internal/pb"
18-
"gopkg.in/src-d/hercules.v6/internal/test"
17+
"gopkg.in/src-d/hercules.v7/internal/pb"
18+
"gopkg.in/src-d/hercules.v7/internal/test"
1919
)
2020

2121
type testPipelineItem struct {

internal/core/registry_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import (
99
"github.com/spf13/pflag"
1010
"github.com/stretchr/testify/assert"
1111
"gopkg.in/src-d/go-git.v4"
12-
"gopkg.in/src-d/hercules.v6/internal/test"
12+
"gopkg.in/src-d/hercules.v7/internal/test"
1313
)
1414

1515
func getRegistry() *PipelineItemRegistry {

internal/global_test.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ import (
77
"testing"
88

99
"github.com/stretchr/testify/assert"
10-
"gopkg.in/src-d/hercules.v6/internal/core"
11-
uast_items "gopkg.in/src-d/hercules.v6/internal/plumbing/uast"
12-
"gopkg.in/src-d/hercules.v6/internal/test"
13-
"gopkg.in/src-d/hercules.v6/leaves"
10+
"gopkg.in/src-d/hercules.v7/internal/core"
11+
uast_items "gopkg.in/src-d/hercules.v7/internal/plumbing/uast"
12+
"gopkg.in/src-d/hercules.v7/internal/test"
13+
"gopkg.in/src-d/hercules.v7/leaves"
1414
)
1515

1616
func TestPipelineSerialize(t *testing.T) {

0 commit comments

Comments
 (0)