Skip to content

Commit 5940d7f

Browse files
authored
Merge branch 'main' into org-oauth2
2 parents 7e5c6dc + bfe2e3d commit 5940d7f

File tree

875 files changed

+6115
-80424
lines changed

Some content is hidden

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

875 files changed

+6115
-80424
lines changed

.drone.yml

Lines changed: 26 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ steps:
2525
- make deps-frontend
2626

2727
- name: deps-backend
28-
image: golang:1.17
28+
image: golang:1.18
2929
pull: always
3030
commands:
3131
- make deps-backend
@@ -49,18 +49,24 @@ steps:
4949
GOSUMDB: sum.golang.org
5050
TAGS: bindata sqlite sqlite_unlock_notify
5151
depends_on: [deps-backend]
52+
volumes:
53+
- name: deps
54+
path: /go
5255

5356
- name: lint-backend-windows
5457
image: gitea/test_env:linux-amd64 # https://gitea.com/gitea/test-env
5558
commands:
56-
- make golangci-lint vet
59+
- make golangci-lint-windows vet
5760
environment:
5861
GOPROXY: https://goproxy.cn # proxy.golang.org is blocked in China, this proxy is not
5962
GOSUMDB: sum.golang.org
6063
TAGS: bindata sqlite sqlite_unlock_notify
6164
GOOS: windows
6265
GOARCH: amd64
6366
depends_on: [deps-backend]
67+
volumes:
68+
- name: deps
69+
path: /go
6470

6571
- name: lint-backend-gogit
6672
image: gitea/test_env:linux-amd64 # https://gitea.com/gitea/test-env
@@ -71,6 +77,9 @@ steps:
7177
GOSUMDB: sum.golang.org
7278
TAGS: bindata gogit sqlite sqlite_unlock_notify
7379
depends_on: [deps-backend]
80+
volumes:
81+
- name: deps
82+
path: /go
7483

7584
- name: checks-frontend
7685
image: node:16
@@ -79,7 +88,7 @@ steps:
7988
depends_on: [deps-frontend]
8089

8190
- name: checks-backend
82-
image: golang:1.17
91+
image: golang:1.18
8392
commands:
8493
- make checks-backend
8594
depends_on: [deps-backend]
@@ -100,7 +109,7 @@ steps:
100109
depends_on: [test-frontend]
101110

102111
- name: build-backend-no-gcc
103-
image: golang:1.16 # this step is kept as the lowest version of golang that we support
112+
image: golang:1.17 # this step is kept as the lowest version of golang that we support
104113
pull: always
105114
environment:
106115
GO111MODULE: on
@@ -113,7 +122,7 @@ steps:
113122
path: /go
114123

115124
- name: build-backend-arm64
116-
image: golang:1.17
125+
image: golang:1.18
117126
environment:
118127
GO111MODULE: on
119128
GOPROXY: https://goproxy.cn
@@ -129,7 +138,7 @@ steps:
129138
path: /go
130139

131140
- name: build-backend-windows
132-
image: golang:1.17
141+
image: golang:1.18
133142
environment:
134143
GO111MODULE: on
135144
GOPROXY: https://goproxy.cn
@@ -144,7 +153,7 @@ steps:
144153
path: /go
145154

146155
- name: build-backend-386
147-
image: golang:1.17
156+
image: golang:1.18
148157
environment:
149158
GO111MODULE: on
150159
GOPROXY: https://goproxy.cn
@@ -233,7 +242,7 @@ steps:
233242
- pull_request
234243

235244
- name: deps-backend
236-
image: golang:1.17
245+
image: golang:1.18
237246
pull: always
238247
commands:
239248
- make deps-backend
@@ -350,7 +359,7 @@ steps:
350359
path: /go
351360

352361
- name: generate-coverage
353-
image: golang:1.17
362+
image: golang:1.18
354363
commands:
355364
- make coverage
356365
environment:
@@ -425,7 +434,7 @@ steps:
425434
- pull_request
426435

427436
- name: deps-backend
428-
image: golang:1.17
437+
image: golang:1.18
429438
pull: always
430439
commands:
431440
- make deps-backend
@@ -567,7 +576,7 @@ trigger:
567576

568577
steps:
569578
- name: download
570-
image: golang:1.17
579+
image: golang:1.18
571580
pull: always
572581
commands:
573582
- timeout -s ABRT 40m make generate-license generate-gitignore
@@ -628,7 +637,7 @@ steps:
628637
- make deps-frontend
629638

630639
- name: deps-backend
631-
image: golang:1.17
640+
image: golang:1.18
632641
pull: always
633642
commands:
634643
- make deps-backend
@@ -637,7 +646,7 @@ steps:
637646
path: /go
638647

639648
- name: static
640-
image: techknowlogick/xgo:go-1.17.x
649+
image: techknowlogick/xgo:go-1.18.x
641650
pull: always
642651
commands:
643652
- curl -sL https://deb.nodesource.com/setup_16.x | bash - && apt-get install -y nodejs
@@ -746,7 +755,7 @@ steps:
746755
- make deps-frontend
747756

748757
- name: deps-backend
749-
image: golang:1.17
758+
image: golang:1.18
750759
pull: always
751760
commands:
752761
- make deps-backend
@@ -755,7 +764,7 @@ steps:
755764
path: /go
756765

757766
- name: static
758-
image: techknowlogick/xgo:go-1.17.x
767+
image: techknowlogick/xgo:go-1.18.x
759768
pull: always
760769
commands:
761770
- curl -sL https://deb.nodesource.com/setup_16.x | bash - && apt-get install -y nodejs
@@ -804,11 +813,12 @@ steps:
804813
depends_on: [gpg-sign]
805814

806815
- name: github
807-
image: plugins/github-release:1
816+
image: plugins/github-release:latest
808817
pull: always
809818
settings:
810819
files:
811820
- "dist/release/*"
821+
file_exists: overwrite
812822
environment:
813823
GITHUB_TOKEN:
814824
from_secret: github_token

.eslintrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -442,6 +442,7 @@ rules:
442442
unicorn/require-post-message-target-origin: [0]
443443
unicorn/string-content: [0]
444444
unicorn/template-indent: [2]
445+
unicorn/text-encoding-identifier-case: [0]
445446
unicorn/throw-new-error: [2]
446447
use-isnan: [2]
447448
valid-typeof: [2, {requireStringLiterals: true}]

.github/ISSUE_TEMPLATE/bug-report.yaml

Lines changed: 36 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
name: Bug Report
22
description: Found something you weren't expecting? Report it here!
3+
labels: kind/bug
34
body:
45
- type: markdown
56
attributes:
@@ -19,13 +20,48 @@ body:
1920
6. In particular it's really important to provide pertinent logs. You must give us DEBUG level logs.
2021
Please read https://docs.gitea.io/en-us/logging-configuration/#debugging-problems
2122
In addition, if your problem relates to git commands set `RUN_MODE=dev` at the top of app.ini
23+
- type: textarea
24+
id: description
25+
attributes:
26+
label: Description
27+
description: |
28+
Please provide a description of your issue here, with a URL if you were able to reproduce the issue (see below)
29+
If you are using a proxy or a CDN (e.g. Cloudflare) in front of Gitea, please disable the proxy/CDN fully and access Gitea directly to confirm the issue still persists without those services.
2230
- type: input
2331
id: gitea-ver
2432
attributes:
2533
label: Gitea Version
2634
description: Gitea version (or commit reference) of your instance
2735
validations:
2836
required: true
37+
- type: dropdown
38+
id: can-reproduce
39+
attributes:
40+
label: Can you reproduce the bug on the Gitea demo site?
41+
description: |
42+
If so, please provide a URL in the Description field
43+
URL of Gitea demo: https://try.gitea.io
44+
options:
45+
- "Yes"
46+
- "No"
47+
validations:
48+
required: true
49+
- type: markdown
50+
attributes:
51+
value: |
52+
It's really important to provide pertinent logs
53+
Please read https://docs.gitea.io/en-us/logging-configuration/#debugging-problems
54+
In addition, if your problem relates to git commands set `RUN_MODE=dev` at the top of app.ini
55+
- type: input
56+
id: logs
57+
attributes:
58+
label: Log Gist
59+
description: Please provide a gist URL of your logs, with any sensitive information (e.g. API keys) removed/hidden
60+
- type: textarea
61+
id: screenshots
62+
attributes:
63+
label: Screenshots
64+
description: If this issue involves the Web Interface, please provide one or more screenshots
2965
- type: input
3066
id: git-ver
3167
attributes:
@@ -56,38 +92,3 @@ body:
5692
- MySQL
5793
- MSSQL
5894
- SQLite
59-
- type: dropdown
60-
id: can-reproduce
61-
attributes:
62-
label: Can you reproduce the bug on the Gitea demo site?
63-
description: |
64-
If so, please provide a URL in the Description field
65-
URL of Gitea demo: https://try.gitea.io
66-
options:
67-
- "Yes"
68-
- "No"
69-
validations:
70-
required: true
71-
- type: markdown
72-
attributes:
73-
value: |
74-
It's really important to provide pertinent logs
75-
Please read https://docs.gitea.io/en-us/logging-configuration/#debugging-problems
76-
In addition, if your problem relates to git commands set `RUN_MODE=dev` at the top of app.ini
77-
- type: input
78-
id: logs
79-
attributes:
80-
label: Log Gist
81-
description: Please provide a gist URL of your logs, with any sensitive information (e.g. API keys) removed/hidden
82-
- type: textarea
83-
id: description
84-
attributes:
85-
label: Description
86-
description: |
87-
Please provide a description of your issue here, with a URL if you were able to reproduce the issue (see above)
88-
If you are using a proxy or a CDN (e.g. Cloudflare) in front of Gitea, please disable the proxy/CDN fully and access Gitea directly to confirm the issue still persists without those services.
89-
- type: textarea
90-
id: screenshots
91-
attributes:
92-
label: Screenshots
93-
description: If this issue involves the Web Interface, please provide one or more screenshots

.github/ISSUE_TEMPLATE/feature-request.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
name: Feature Request
22
description: Got an idea for a feature that Gitea doesn't have currently? Submit your idea here!
3+
labels: ["kind/feature", "kind/proposal"]
34
body:
45
- type: markdown
56
attributes:
Lines changed: 23 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
name: Web Interface Bug Report
22
description: Something doesn't look quite as it should? Report it here!
3+
labels: ["kind/bug", "kind/ui"]
34
body:
45
- type: markdown
56
attributes:
@@ -18,23 +19,25 @@ body:
1819
6. In particular it's really important to provide pertinent logs. If you are certain that this is a javascript
1920
error, show us the javascript console. If the error appears to relate to Gitea the server you must also give us
2021
DEBUG level logs. (See https://docs.gitea.io/en-us/logging-configuration/#debugging-problems)
21-
- type: input
22-
id: gitea-ver
22+
- type: textarea
23+
id: description
2324
attributes:
24-
label: Gitea Version
25-
description: Gitea version (or commit reference) your instance is running
25+
label: Description
26+
description: |
27+
Please provide a description of your issue here, with a URL if you were able to reproduce the issue (see below)
28+
If using a proxy or a CDN (e.g. CloudFlare) in front of gitea, please disable the proxy/CDN fully and connect to gitea directly to confirm the issue still persists without those services.
29+
- type: textarea
30+
id: screenshots
31+
attributes:
32+
label: Screenshots
33+
description: Please provide at least 1 screenshot showing the issue.
2634
validations:
2735
required: true
2836
- type: input
29-
id: os-ver
30-
attributes:
31-
label: Operating System
32-
description: The operating system you are using to access Gitea
33-
- type: input
34-
id: browser-ver
37+
id: gitea-ver
3538
attributes:
36-
label: Browser Version
37-
description: The browser and version that you are using to access Gitea
39+
label: Gitea Version
40+
description: Gitea version (or commit reference) your instance is running
3841
validations:
3942
required: true
4043
- type: dropdown
@@ -49,17 +52,15 @@ body:
4952
- "No"
5053
validations:
5154
required: true
52-
- type: textarea
53-
id: description
55+
- type: input
56+
id: os-ver
5457
attributes:
55-
label: Description
56-
description: |
57-
Please provide a description of your issue here, with a URL if you were able to reproduce the issue (see above)
58-
If using a proxy or a CDN (e.g. CloudFlare) in front of gitea, please disable the proxy/CDN fully and connect to gitea directly to confirm the issue still persists without those services.
59-
- type: textarea
60-
id: screenshots
58+
label: Operating System
59+
description: The operating system you are using to access Gitea
60+
- type: input
61+
id: browser-ver
6162
attributes:
62-
label: Screenshots
63-
description: Please provide at least 1 screenshot showing the issue.
63+
label: Browser Version
64+
description: The browser and version that you are using to access Gitea
6465
validations:
6566
required: true

.golangci.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ linters:
2323
fast: false
2424

2525
run:
26-
timeout: 3m
26+
go: 1.18
27+
timeout: 10m
2728
skip-dirs:
2829
- node_modules
2930
- public
@@ -64,7 +65,7 @@ linters-settings:
6465
- name: modifies-value-receiver
6566
gofumpt:
6667
extra-rules: true
67-
lang-version: 1.16
68+
lang-version: 1.18
6869

6970
issues:
7071
exclude-rules:
@@ -152,3 +153,5 @@ issues:
152153
- path: models/user/openid.go
153154
linters:
154155
- golint
156+
- linters: staticcheck
157+
text: "strings.Title is deprecated: The rule Title uses for word boundaries does not handle Unicode punctuation properly. Use golang.org/x/text/cases instead."

.stylelintrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ rules:
1414
declaration-block-no-redundant-longhand-properties: null
1515
declaration-block-single-line-max-declarations: null
1616
declaration-empty-line-before: null
17+
function-no-unknown: null
1718
hue-degree-notation: null
1819
indentation: 2
1920
max-line-length: null

0 commit comments

Comments
 (0)