Skip to content

Commit a5477b8

Browse files
committed
Merge branch 'main' into acss
* main: Remove publish docs CI workflow (go-gitea#24889) Fix double border and adjust width for user profile page (go-gitea#24870) Support changing git config through `app.ini`, use `diff.algorithm=histogram` by default (go-gitea#24860) Fix flakey test in logger test (go-gitea#24883) Run stylelint on .vue files (go-gitea#24865) Update `CONTRIBUTING.md` (go-gitea#24492) Do not call nil handler for a dummy queue (go-gitea#24880) Remove unnecessary usage prefix from doc titles (go-gitea#24869) Add API for Label templates (go-gitea#24602) Fix install page context, make the install page tests really test (go-gitea#24858) Add validations.required check to dropdown field (go-gitea#24849)
2 parents de96503 + 21add7e commit a5477b8

40 files changed

+904
-383
lines changed

.github/workflows/publish-docs.yml

Lines changed: 0 additions & 29 deletions
This file was deleted.

.stylelintrc.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ overrides:
1111
- files: ["**/chroma/*", "**/codemirror/*"]
1212
rules:
1313
block-no-empty: null
14+
- files: ["**/*.vue"]
15+
customSyntax: postcss-html
1416

1517
rules:
1618
alpha-value-notation: null
@@ -96,7 +98,7 @@ rules:
9698
property-no-vendor-prefix: null
9799
rule-empty-line-before: null
98100
rule-selector-property-disallowed-list: null
99-
scale-unlimited/declaration-strict-value: [[color, background-color, border-color, font-weight], {ignoreValues: /^(inherit|transparent|unset|initial|currentcolor|none)$/, ignoreFunctions: false}]
101+
scale-unlimited/declaration-strict-value: [[color, background-color, border-color, font-weight], {ignoreValues: /^(inherit|transparent|unset|initial|currentcolor|none)$/, ignoreFunctions: false, disableFix: true}]
100102
selector-attribute-name-disallowed-list: null
101103
selector-attribute-operator-allowed-list: null
102104
selector-attribute-operator-disallowed-list: null

CONTRIBUTING.md

Lines changed: 384 additions & 263 deletions
Large diffs are not rendered by default.

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -372,11 +372,11 @@ lint-js-fix: node_modules
372372

373373
.PHONY: lint-css
374374
lint-css: node_modules
375-
npx stylelint --color --max-warnings=0 web_src/css
375+
npx stylelint --color --max-warnings=0 web_src/css web_src/js/components/*.vue
376376

377377
.PHONY: lint-css-fix
378378
lint-css-fix: node_modules
379-
npx stylelint --color --max-warnings=0 web_src/css --fix
379+
npx stylelint --color --max-warnings=0 web_src/css web_src/js/components/*.vue --fix
380380

381381
.PHONY: lint-swagger
382382
lint-swagger: node_modules

cmd/web.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -142,10 +142,8 @@ func runWeb(ctx *cli.Context) error {
142142
return err
143143
}
144144
}
145-
installCtx, cancel := context.WithCancel(graceful.GetManager().HammerContext())
146-
c := install.Routes(installCtx)
145+
c := install.Routes()
147146
err := listen(c, false)
148-
cancel()
149147
if err != nil {
150148
log.Critical("Unable to open listener for installer. Is Gitea already running?")
151149
graceful.GetManager().DoGracefulShutdown()

custom/conf/app.example.ini

Lines changed: 22 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -682,6 +682,28 @@ LEVEL = Info
682682
;; Disable the usage of using partial clones for git.
683683
;DISABLE_PARTIAL_CLONE = false
684684

685+
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
686+
;; Git Operation timeout in seconds
687+
;[git.timeout]
688+
;DEFAULT = 360
689+
;MIGRATE = 600
690+
;MIRROR = 300
691+
;CLONE = 300
692+
;PULL = 300
693+
;GC = 60
694+
695+
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
696+
;; Git Reflog timeout in days
697+
;[git.reflog]
698+
;ENABLED = true
699+
;EXPIRATION = 90
700+
701+
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
702+
;; Git config options
703+
;; This section only does "set" config, a removed config key from this section won't be removed from git config automatically. The format is `some.configKey = value`.
704+
;[git.config]
705+
;diff.algorithm = histogram
706+
685707
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
686708
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
687709
[service]
@@ -2176,32 +2198,6 @@ LEVEL = Info
21762198
;Check at least this proportion of LFSMetaObjects per repo. (This may cause all stale LFSMetaObjects to be checked.)
21772199
;PROPORTION_TO_CHECK_PER_REPO = 0.6
21782200

2179-
2180-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2181-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2182-
;; Git Operation timeout in seconds
2183-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2184-
;[git.timeout]
2185-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2186-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2187-
;DEFAULT = 360
2188-
;MIGRATE = 600
2189-
;MIRROR = 300
2190-
;CLONE = 300
2191-
;PULL = 300
2192-
;GC = 60
2193-
2194-
2195-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2196-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2197-
;; Git Reflog timeout in days
2198-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2199-
;[git.reflog]
2200-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2201-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2202-
;ENABLED = true
2203-
;EXPIRATION = 90
2204-
22052201
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
22062202
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
22072203
;[mirror]

docs/content/doc/administration/backup-and-restore.zh-cn.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
date: "2018-06-06T09:33:00+08:00"
3-
title: "使用:备份与恢复"
3+
title: "备份与恢复"
44
slug: "backup-and-restore"
55
weight: 11
66
toc: false

docs/content/doc/administration/config-cheat-sheet.en-us.md

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1054,12 +1054,7 @@ Default templates for project boards:
10541054
- `DISABLE_CORE_PROTECT_NTFS`: **false** Set to true to forcibly set `core.protectNTFS` to false.
10551055
- `DISABLE_PARTIAL_CLONE`: **false** Disable the usage of using partial clones for git.
10561056

1057-
## Git - Reflog settings (`git.reflog`)
1058-
1059-
- `ENABLED`: **true** Set to true to enable Git to write changes to reflogs in each repo.
1060-
- `EXPIRATION`: **90** Reflog entry lifetime, in days. Entries are removed opportunistically by Git.
1061-
1062-
## Git - Timeout settings (`git.timeout`)
1057+
### Git - Timeout settings (`git.timeout`)
10631058

10641059
- `DEFAULT`: **360**: Git operations default timeout seconds.
10651060
- `MIGRATE`: **600**: Migrate external repositories timeout seconds.
@@ -1068,6 +1063,18 @@ Default templates for project boards:
10681063
- `PULL`: **300**: Git pull from internal repositories timeout seconds.
10691064
- `GC`: **60**: Git repository GC timeout seconds.
10701065

1066+
### Git - Reflog settings (`git.reflog`)
1067+
1068+
- `ENABLED`: **true** Set to true to enable Git to write changes to reflogs in each repo.
1069+
- `EXPIRATION`: **90** Reflog entry lifetime, in days. Entries are removed opportunistically by Git.
1070+
1071+
### Git - Config options (`git.config`)
1072+
1073+
The key/value pairs in this section will be used as git config.
1074+
This section only does "set" config, a removed config key from this section won't be removed from git config automatically. The format is `some.configKey = value`.
1075+
1076+
- `diff.algorithm`: **histogram**
1077+
10711078
## Metrics (`metrics`)
10721079

10731080
- `ENABLED`: **false**: Enables /metrics endpoint for prometheus.

docs/content/doc/administration/customizing-gitea.en-us.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -282,6 +282,22 @@ Place custom files in corresponding sub-folder under `custom/options`.
282282

283283
To add custom .gitignore, add a file with existing [.gitignore rules](https://git-scm.com/docs/gitignore) in it to `$GITEA_CUSTOM/options/gitignore`
284284

285+
## Customizing the git configuration
286+
287+
Starting with Gitea 1.20, you can customize the git configuration via the `git.config` section.
288+
289+
### Enabling signed git pushes
290+
291+
To enable signed git pushes, set these two options:
292+
293+
```ini
294+
[git.config]
295+
receive.advertisePushOptions = true
296+
receive.certNonceSeed = <randomstring>
297+
```
298+
299+
`certNonceSeed` should be set to a random string and be kept secret.
300+
285301
### Labels
286302

287303
Starting with Gitea 1.19, you can add a file that follows the [YAML label format](https://github.com/go-gitea/gitea/blob/main/options/label/Advanced.yaml) to `$GITEA_CUSTOM/options/label`:

docs/content/doc/administration/https-support.zh-cn.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
date: "2023-04-09T11:00:00+02:00"
3-
title: "使用: HTTPS配置"
3+
title: "HTTPS配置"
44
slug: "https-setup"
55
weight: 12
66
toc: false

0 commit comments

Comments
 (0)