Skip to content

Commit 423c69e

Browse files
committed
Merge remote-tracking branch 'origin/main' into fix-3796-add-reindex-button-to-settings
* ensure that reindex request can only be performed by Admin * rename form.Index to form.RequestReindexType
2 parents cd6391b + f58e687 commit 423c69e

File tree

1,014 files changed

+25628
-20329
lines changed

Some content is hidden

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

1,014 files changed

+25628
-20329
lines changed

.air.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@ bin = "gitea"
77
include_ext = ["go", "tmpl"]
88
exclude_dir = ["modules/git/tests", "services/gitdiff/testdata", "modules/avatar/testdata"]
99
include_dir = ["cmd", "models", "modules", "options", "routers", "services", "templates"]
10+
exclude_regex = ["_test.go$"]

.drone.yml

Lines changed: 36 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
---
22
kind: pipeline
3+
type: docker
34
name: compliance
45

56
platform:
@@ -130,6 +131,7 @@ steps:
130131

131132
---
132133
kind: pipeline
134+
type: docker
133135
name: testing-amd64
134136

135137
platform:
@@ -191,26 +193,30 @@ steps:
191193
exclude:
192194
- pull_request
193195

194-
- name: build
195-
pull: always
196-
image: golang:1.17
197-
commands:
198-
- make backend
199-
environment:
200-
GOPROXY: https://goproxy.cn # proxy.golang.org is blocked in China, this proxy is not
201-
GOSUMDB: sum.golang.org
202-
TAGS: bindata sqlite sqlite_unlock_notify
203-
204196
- name: tag-pre-condition
205197
pull: always
206198
image: drone/git
207199
commands:
208200
- git update-ref refs/heads/tag_test ${DRONE_COMMIT_SHA}
209201

210-
- name: fix-permissions
202+
- name: prepare-test-env
211203
image: gitea/test_env:linux-amd64 # https://gitea.com/gitea/test-env
212204
commands:
213-
- chown -R gitea:gitea .
205+
- ./build/test-env-prepare.sh
206+
207+
- name: build
208+
pull: always
209+
image: gitea/test_env:linux-amd64 # https://gitea.com/gitea/test-env
210+
user: gitea
211+
commands:
212+
- ./build/test-env-check.sh
213+
- make backend
214+
environment:
215+
GOPROXY: https://goproxy.cn # proxy.golang.org is blocked in China, this proxy is not
216+
GOSUMDB: sum.golang.org
217+
TAGS: bindata sqlite sqlite_unlock_notify
218+
depends_on:
219+
- prepare-test-env
214220

215221
- name: unit-test
216222
image: gitea/test_env:linux-amd64 # https://gitea.com/gitea/test-env
@@ -353,21 +359,24 @@ steps:
353359
exclude:
354360
- pull_request
355361

356-
- name: fix-permissions
362+
- name: prepare-test-env
357363
image: gitea/test_env:linux-arm64 # https://gitea.com/gitea/test-env
358364
commands:
359-
- chown -R gitea:gitea .
365+
- ./build/test-env-prepare.sh
360366

361367
- name: build
362368
pull: always
363369
image: gitea/test_env:linux-arm64 # https://gitea.com/gitea/test-env
364370
user: gitea
365371
commands:
372+
- ./build/test-env-check.sh
366373
- make backend
367374
environment:
368375
GOPROXY: https://goproxy.cn # proxy.golang.org is blocked in China, this proxy is not
369376
GOSUMDB: sum.golang.org
370377
TAGS: bindata gogit sqlite sqlite_unlock_notify
378+
depends_on:
379+
- prepare-test-env
371380

372381
- name: test-sqlite
373382
image: gitea/test_env:linux-arm64 # https://gitea.com/gitea/test-env
@@ -461,6 +470,7 @@ steps:
461470

462471
---
463472
kind: pipeline
473+
type: docker
464474
name: update_gitignore_and_licenses
465475

466476
platform:
@@ -497,6 +507,7 @@ steps:
497507

498508
---
499509
kind: pipeline
510+
type: docker
500511
name: release-latest
501512

502513
platform:
@@ -526,7 +537,7 @@ steps:
526537

527538
- name: static
528539
pull: always
529-
image: techknowlogick/xgo:go-1.16.x
540+
image: techknowlogick/xgo:go-1.17.x
530541
commands:
531542
- curl -sL https://deb.nodesource.com/setup_16.x | bash - && apt-get install -y nodejs
532543
- export PATH=$PATH:$GOPATH/bin
@@ -622,7 +633,7 @@ steps:
622633

623634
- name: static
624635
pull: always
625-
image: techknowlogick/xgo:go-1.16.x
636+
image: techknowlogick/xgo:go-1.17.x
626637
commands:
627638
- curl -sL https://deb.nodesource.com/setup_16.x | bash - && apt-get install -y nodejs
628639
- export PATH=$PATH:$GOPATH/bin
@@ -675,6 +686,7 @@ steps:
675686

676687
---
677688
kind: pipeline
689+
type: docker
678690
name: docs
679691

680692
platform:
@@ -716,6 +728,7 @@ steps:
716728

717729
---
718730
kind: pipeline
731+
type: docker
719732
name: docker-linux-amd64-release-version
720733

721734
platform:
@@ -780,6 +793,7 @@ steps:
780793

781794
---
782795
kind: pipeline
796+
type: docker
783797
name: docker-linux-amd64-release
784798

785799
platform:
@@ -844,6 +858,7 @@ steps:
844858

845859
---
846860
kind: pipeline
861+
type: docker
847862
name: docker-linux-arm64-dry-run
848863

849864
platform:
@@ -876,6 +891,7 @@ steps:
876891

877892
---
878893
kind: pipeline
894+
type: docker
879895
name: docker-linux-arm64-release-version
880896

881897
platform:
@@ -943,6 +959,7 @@ steps:
943959

944960
---
945961
kind: pipeline
962+
type: docker
946963
name: docker-linux-arm64-release
947964

948965
platform:
@@ -1009,6 +1026,7 @@ steps:
10091026
- pull_request
10101027
---
10111028
kind: pipeline
1029+
type: docker
10121030
name: docker-manifest-version
10131031

10141032
platform:
@@ -1052,6 +1070,7 @@ depends_on:
10521070

10531071
---
10541072
kind: pipeline
1073+
type: docker
10551074
name: docker-manifest
10561075

10571076
platform:
@@ -1095,6 +1114,7 @@ depends_on:
10951114

10961115
---
10971116
kind: pipeline
1117+
type: docker
10981118
name: notifications
10991119

11001120
platform:

.eslintrc

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,14 @@ ignorePatterns:
66

77
parserOptions:
88
sourceType: module
9-
ecmaVersion: 2021
9+
ecmaVersion: latest
1010

1111
plugins:
1212
- eslint-plugin-unicorn
1313
- eslint-plugin-import
1414
- eslint-plugin-vue
1515
- eslint-plugin-html
16+
- eslint-plugin-github
1617

1718
extends:
1819
- plugin:vue/recommended
@@ -96,6 +97,23 @@ rules:
9697
function-paren-newline: [0]
9798
generator-star-spacing: [0]
9899
getter-return: [2]
100+
github/array-foreach: [2]
101+
github/async-currenttarget: [2]
102+
github/async-preventdefault: [2]
103+
github/authenticity-token: [0]
104+
github/get-attribute: [2]
105+
github/js-class-name: [0]
106+
github/no-blur: [0]
107+
github/no-d-none: [0]
108+
github/no-dataset: [2]
109+
github/no-implicit-buggy-globals: [0]
110+
github/no-inner-html: [0]
111+
github/no-innerText: [2]
112+
github/no-then: [0]
113+
github/no-useless-passive: [2]
114+
github/prefer-observers: [0]
115+
github/require-passive-events: [2]
116+
github/unescaped-html-literal: [0]
99117
grouped-accessor-pairs: [2]
100118
guard-for-in: [0]
101119
id-blacklist: [0]
@@ -366,6 +384,7 @@ rules:
366384
unicorn/no-array-instanceof: [0]
367385
unicorn/no-array-method-this-argument: [2]
368386
unicorn/no-array-push-push: [2]
387+
unicorn/no-await-expression-member: [0]
369388
unicorn/no-console-spaces: [0]
370389
unicorn/no-document-cookie: [2]
371390
unicorn/no-empty-file: [2]
@@ -401,6 +420,7 @@ rules:
401420
unicorn/prefer-array-index-of: [2]
402421
unicorn/prefer-array-some: [2]
403422
unicorn/prefer-at: [0]
423+
unicorn/prefer-code-point: [2]
404424
unicorn/prefer-dataset: [2]
405425
unicorn/prefer-date-now: [2]
406426
unicorn/prefer-default-parameters: [0]

.golangci.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ linters:
1414
- gofmt
1515
- misspell
1616
- gocritic
17+
- bidichk
18+
- ineffassign
1719
enable-all: false
1820
disable-all: true
1921
fast: false
@@ -110,3 +112,6 @@ issues:
110112
linters:
111113
- staticcheck
112114
text: "svc.IsAnInteractiveSession is deprecated: Use IsWindowsService instead."
115+
- path: models/user/openid.go
116+
linters:
117+
- golint

CHANGELOG.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,37 @@ This changelog goes through all the changes that have been made in each release
44
without substantial changes to our git log; to see the highlights of what has
55
been added to each release, please refer to the [blog](https://blog.gitea.io).
66

7+
## [1.15.7](https://github.com/go-gitea/gitea/releases/tag/v1.15.7) - 2021-12-01
8+
9+
* ENHANCEMENTS
10+
* Only allow webhook to send requests to allowed hosts (#17482) (#17510)
11+
* Fix login redirection links (#17451) (#17473)
12+
* BUGFIXES
13+
* Fix database inconsistent when admin change user email (#17549) (#17840)
14+
* Use correct user on releases (#17806) (#17818)
15+
* Fix commit count in tag view (#17698) (#17790)
16+
* Fix close issue but time watcher still running (#17643) (#17761)
17+
* Fix Migrate Description (#17692) (#17727)
18+
* Fix bug when project board get open issue number (#17703) (#17726)
19+
* Return 400 but not 500 when request archive with wrong format (#17691) (#17700)
20+
* Fix bug when read mysql database max lifetime (#17682) (#17690)
21+
* Fix database deadlock when update issue labels (#17649) (#17665)
22+
* Fix bug on detect issue/comment writer (#17592)
23+
* Remove appSubUrl from pasted images (#17572) (#17588)
24+
* Make `ParsePatch` more robust (#17573) (#17580)
25+
* Fix stats upon searching issues (#17566) (#17578)
26+
* Escape issue titles in comments list (#17555) (#17556)
27+
* Fix zero created time bug on commit api (#17546) (#17547)
28+
* Fix database keyword quote problem on migration v161 (#17522) (#17523)
29+
* Fix email with + when active (#17518) (#17520)
30+
* Stop double encoding blame commit messages (#17498) (#17500)
31+
* Quote the table name in CountOrphanedObjects (#17487) (#17488)
32+
* Run Migrate in Install rather than just SyncTables (#17475) (#17486)
33+
* BUILD
34+
* Fix golangci-lint warnings (#17598 et al) (#17668)
35+
* MISC
36+
* Preserve color when inverting emojis (#17797) (#17799)
37+
738
## [1.15.6](https://github.com/go-gitea/gitea/releases/tag/v1.15.6) - 2021-10-28
839

940
* BUGFIXES

Dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,5 @@ CMD ["/bin/s6-svscan", "/etc/s6"]
6666
COPY docker/root /
6767
COPY --from=build-env /go/src/code.gitea.io/gitea/gitea /app/gitea/gitea
6868
COPY --from=build-env /go/src/code.gitea.io/gitea/environment-to-ini /usr/local/bin/environment-to-ini
69-
RUN chmod 755 /usr/bin/entrypoint /app/gitea/gitea /usr/local/bin/environment-to-ini
69+
RUN chmod 755 /usr/bin/entrypoint /app/gitea/gitea /usr/local/bin/gitea /usr/local/bin/environment-to-ini
7070
RUN chmod 755 /etc/s6/gitea/* /etc/s6/openssh/* /etc/s6/.s6-svscan/*
71-
RUN ln -s /app/gitea/gitea /usr/local/bin/gitea

Dockerfile.rootless

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,9 @@ RUN mkdir -p /var/lib/gitea /etc/gitea
5353
RUN chown git:git /var/lib/gitea /etc/gitea
5454

5555
COPY docker/rootless /
56-
COPY --from=build-env --chown=root:root /go/src/code.gitea.io/gitea/gitea /usr/local/bin/gitea
56+
COPY --from=build-env --chown=root:root /go/src/code.gitea.io/gitea/gitea /app/gitea/gitea
5757
COPY --from=build-env --chown=root:root /go/src/code.gitea.io/gitea/environment-to-ini /usr/local/bin/environment-to-ini
58-
RUN chmod 755 /usr/local/bin/docker-entrypoint.sh /usr/local/bin/docker-setup.sh /usr/local/bin/gitea /usr/local/bin/environment-to-ini
58+
RUN chmod 755 /usr/local/bin/docker-entrypoint.sh /usr/local/bin/docker-setup.sh /app/gitea/gitea /usr/local/bin/gitea /usr/local/bin/environment-to-ini
5959

6060
#git:git
6161
USER 1000:1000

0 commit comments

Comments
 (0)