summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMura Li <typeless@users.noreply.github.com>2018-10-23 19:47:59 +0800
committerLunny Xiao <xiaolunwen@gmail.com>2018-10-23 19:47:59 +0800
commit25c49cf930cb0add769c5596a7317ada1c5f9da7 (patch)
treeaa416e3bf7644875738945935fbceb5b50fe0510
parent2ce72d4e00cc7d2dbf3c445eb18c252c73f605e3 (diff)
downloadgitea-25c49cf930cb0add769c5596a7317ada1c5f9da7.tar.gz
gitea-25c49cf930cb0add769c5596a7317ada1c5f9da7.zip
Update build tags for sqlite_unlock_notify (#5144)
-rw-r--r--.drone.yml31
-rw-r--r--Dockerfile2
-rw-r--r--Makefile6
-rw-r--r--contrib/ide/vscode/launch.json2
-rw-r--r--contrib/ide/vscode/tasks.json2
-rw-r--r--docker/Makefile2
-rw-r--r--snap/snapcraft.yaml2
7 files changed, 24 insertions, 23 deletions
diff --git a/.drone.yml b/.drone.yml
index e4ade4fc1c..682797105e 100644
--- a/.drone.yml
+++ b/.drone.yml
@@ -67,7 +67,7 @@ pipeline:
image: golang:1.11
pull: true
environment:
- TAGS: bindata sqlite
+ TAGS: bindata sqlite sqlite_unlock_notify
commands:
- make clean
- make generate
@@ -87,7 +87,7 @@ pipeline:
pull: true
group: test
environment:
- TAGS: bindata sqlite
+ TAGS: bindata sqlite sqlite_unlock_notify
commands:
- make unit-test-coverage
when:
@@ -99,7 +99,7 @@ pipeline:
pull: true
group: test
environment:
- TAGS: bindata sqlite
+ TAGS: bindata sqlite sqlite_unlock_notify
commands:
- make test
when:
@@ -117,17 +117,18 @@ pipeline:
when:
event: [ tag ]
- # Commented until db locking have been resolved!
- # test-sqlite:
- # image: golang:1.10
- # pull: true
- # group: test
- # environment:
- # TAGS: bindata
- # commands:
- # - make test-sqlite
- # when:
- # event: [ push, tag, pull_request ]
+ test-sqlite:
+ image: golang:1.11
+ pull: true
+ group: test
+ environment:
+ TAGS: bindata
+ commands:
+ - curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash
+ - apt-get install -y git-lfs
+ - make test-sqlite
+ when:
+ event: [ push, tag, pull_request ]
test-mysql:
image: golang:1.11
@@ -196,7 +197,7 @@ pipeline:
image: karalabe/xgo-latest:latest
pull: true
environment:
- TAGS: bindata sqlite
+ TAGS: bindata sqlite sqlite_unlock_notify
commands:
- export PATH=$PATH:$GOPATH/bin
- make release
diff --git a/Dockerfile b/Dockerfile
index 53ffdda5dd..a5b91074ea 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -4,7 +4,7 @@
FROM golang:1.10-alpine3.7 AS build-env
ARG GITEA_VERSION
-ARG TAGS="sqlite"
+ARG TAGS="sqlite sqlite_unlock_notify"
ENV TAGS "bindata $TAGS"
#Build deps
diff --git a/Makefile b/Makefile
index 28f52196ef..6f3779e30b 100644
--- a/Makefile
+++ b/Makefile
@@ -159,7 +159,7 @@ fmt-check:
.PHONY: test
test:
- $(GO) test -tags=sqlite $(PACKAGES)
+ $(GO) test -tags='sqlite sqlite_unlock_notify' $(PACKAGES)
.PHONY: coverage
coverage:
@@ -170,7 +170,7 @@ coverage:
.PHONY: unit-test-coverage
unit-test-coverage:
- for PKG in $(PACKAGES); do $(GO) test -tags=sqlite -cover -coverprofile $$GOPATH/src/$$PKG/coverage.out $$PKG || exit 1; done;
+ for PKG in $(PACKAGES); do $(GO) test -tags='sqlite sqlite_unlock_notify' -cover -coverprofile $$GOPATH/src/$$PKG/coverage.out $$PKG || exit 1; done;
.PHONY: vendor
vendor:
@@ -234,7 +234,7 @@ integrations.test: $(SOURCES)
$(GO) test -c code.gitea.io/gitea/integrations -o integrations.test
integrations.sqlite.test: $(SOURCES)
- $(GO) test -c code.gitea.io/gitea/integrations -o integrations.sqlite.test -tags 'sqlite'
+ $(GO) test -c code.gitea.io/gitea/integrations -o integrations.sqlite.test -tags 'sqlite sqlite_unlock_notify'
integrations.cover.test: $(SOURCES)
$(GO) test -c code.gitea.io/gitea/integrations -coverpkg $(shell echo $(PACKAGES) | tr ' ' ',') -o integrations.cover.test
diff --git a/contrib/ide/vscode/launch.json b/contrib/ide/vscode/launch.json
index af1594cd5d..6e90aa0eaa 100644
--- a/contrib/ide/vscode/launch.json
+++ b/contrib/ide/vscode/launch.json
@@ -19,7 +19,7 @@
"type": "go",
"request": "launch",
"mode": "debug",
- "buildFlags": "-tags=\"sqlite\"",
+ "buildFlags": "-tags=\"sqlite sqlite_unlock_notify\"",
"port": 2345,
"host": "127.0.0.1",
"program": "${workspaceRoot}/main.go",
diff --git a/contrib/ide/vscode/tasks.json b/contrib/ide/vscode/tasks.json
index 8527d91c8f..ac42806d67 100644
--- a/contrib/ide/vscode/tasks.json
+++ b/contrib/ide/vscode/tasks.json
@@ -35,7 +35,7 @@
"focus": false,
"panel": "shared"
},
- "args": ["build", "-tags=\"sqlite\""],
+ "args": ["build", "-tags=\"sqlite sqlite_unlock_notify\""],
"linux": {
"args": ["-o", "gitea", "${workspaceRoot}/main.go"]
},
diff --git a/docker/Makefile b/docker/Makefile
index 7f55251860..80e7ae34b3 100644
--- a/docker/Makefile
+++ b/docker/Makefile
@@ -8,7 +8,7 @@ DOCKER_REF := $(DOCKER_IMAGE):$(DOCKER_TAG)
.PHONY: docker
docker:
docker build --disable-content-trust=false -t $(DOCKER_REF) .
-# support also build args docker build --build-arg GITEA_VERSION=v1.2.3 --build-arg TAGS="bindata sqlite" .
+# support also build args docker build --build-arg GITEA_VERSION=v1.2.3 --build-arg TAGS="bindata sqlite sqlite_unlock_notify" .
.PHONY: docker-build
docker-build:
diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml
index 7439f50f25..aab1c2b05c 100644
--- a/snap/snapcraft.yaml
+++ b/snap/snapcraft.yaml
@@ -67,7 +67,7 @@ parts:
export GOPATH=$SNAPCRAFT_PART_INSTALL/../go
go get -u github.com/jteeuwen/go-bindata/...
cd $GOPATH/src/code.gitea.io/gitea
- TAGS="bindata sqlite pam cert" make generate build
+ TAGS="bindata sqlite sqlite_unlock_notify pam cert" make generate build
install: |
# Set Convenience Variables
src=$SNAPCRAFT_PART_INSTALL/../go/src/code.gitea.io/gitea