Skip to content

Commit 498f15f

Browse files
authored
Merge branch 'master' into delete-times-ui
2 parents f2c8542 + 0c0445c commit 498f15f

File tree

496 files changed

+8088
-4475
lines changed

Some content is hidden

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

496 files changed

+8088
-4475
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,7 @@ fmt:
232232
vet:
233233
@echo "Running go vet..."
234234
@$(GO) vet $(GO_PACKAGES)
235-
@$(GO) build -mod=vendor code.gitea.io/gitea-vet
235+
@GOOS= GOARCH= $(GO) build -mod=vendor code.gitea.io/gitea-vet
236236
@$(GO) vet -vettool=gitea-vet $(GO_PACKAGES)
237237

238238
.PHONY: $(TAGS_EVIDENCE)

custom/conf/app.example.ini

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -688,6 +688,9 @@ AUTO_WATCH_NEW_REPOS = true
688688
; Default value for AutoWatchOnChanges
689689
; Make the user watch a repository When they commit for the first time
690690
AUTO_WATCH_ON_CHANGES = false
691+
; Default value for the minimum age a user has to exist before deletion to keep issue comments.
692+
; If a user deletes his account before that amount of days, his comments will be deleted as well.
693+
USER_DELETE_WITH_COMMENTS_MAX_DAYS = 0
691694

692695
[webhook]
693696
; Hook task queue length, increase if webhook shooting starts hanging
@@ -1095,6 +1098,10 @@ MAX_GIT_DIFF_LINES = 1000
10951098
MAX_GIT_DIFF_LINE_CHARACTERS = 5000
10961099
; Max number of files shown in diff view
10971100
MAX_GIT_DIFF_FILES = 100
1101+
; Set the default commits range size
1102+
COMMITS_RANGE_SIZE = 50
1103+
; Set the default branches range size
1104+
BRANCHES_RANGE_SIZE = 20
10981105
; Arguments for command 'git gc', e.g. "--aggressive --auto"
10991106
; see more on http://git-scm.com/docs/git-gc/
11001107
GC_ARGS =

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

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -474,6 +474,7 @@ relation to port exhaustion.
474474
- `ALLOW_ONLY_EXTERNAL_REGISTRATION`: **false** Set to true to force registration only using third-party services.
475475
- `NO_REPLY_ADDRESS`: **DOMAIN** Default value for the domain part of the user's email address in the git log if he has set KeepEmailPrivate to true.
476476
The user's email will be replaced with a concatenation of the user name in lower case, "@" and NO_REPLY_ADDRESS.
477+
- `USER_DELETE_WITH_COMMENTS_MAX_DAYS`: **0** If a user deletes his account before that amount of days, his comments will be deleted as well.
477478

478479
## SSH Minimum Key Sizes (`ssh.minimum_key_sizes`)
479480

@@ -751,6 +752,8 @@ NB: You must `REDIRECT_MACARON_LOG` and have `DISABLE_ROUTER_LOG` set to `false`
751752
- `MAX_GIT_DIFF_LINES`: **100**: Max number of lines allowed of a single file in diff view.
752753
- `MAX_GIT_DIFF_LINE_CHARACTERS`: **5000**: Max character count per line highlighted in diff view.
753754
- `MAX_GIT_DIFF_FILES`: **100**: Max number of files shown in diff view.
755+
- `COMMITS_RANGE_SIZE`: **50**: Set the default commits range size
756+
- `BRANCHES_RANGE_SIZE`: **20**: Set the default branches range size
754757
- `GC_ARGS`: **\<empty\>**: Arguments for command `git gc`, e.g. `--aggressive --auto`. See more on http://git-scm.com/docs/git-gc/
755758
- `ENABLE_AUTO_GIT_WIRE_PROTOCOL`: **true**: If use git wire protocol version 2 when git version >= 2.18, default is true, set to false when you always want git wire protocol version 1
756759
- `PULL_REQUEST_PUSH_MESSAGE`: **true**: Respond to pushes to a non-default branch with a URL for creating a Pull Request (if the repository has them enabled)

docs/content/doc/usage/backup-and-restore.en-us.md

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -72,15 +72,21 @@ involves moving files to their correct locations and restoring a database dump.
7272
Example:
7373

7474
```sh
75-
apt-get install gitea
76-
unzip gitea-dump-1482906742.zip
77-
cd gitea-dump-1482906742
78-
mv custom/conf/app.ini /etc/gitea/conf/app.ini # or mv app.ini /etc/gitea/conf/app.ini
79-
unzip gitea-repo.zip
80-
mv gitea-repo/* /var/lib/gitea/repositories/
81-
chown -R gitea:gitea /etc/gitea/conf/app.ini /var/lib/gitea/repositories/
75+
unzip gitea-dump-1610949662.zip
76+
cd gitea-dump-1610949662
77+
mv data/conf/app.ini /etc/gitea/conf/app.ini
78+
mv data/* /var/lib/gitea/data/
79+
mv log/* /var/lib/gitea/log/
80+
mv repos/* /var/lib/gitea/repositories/
81+
chown -R gitea:gitea /etc/gitea/conf/app.ini /var/lib/gitea
82+
83+
# mysql
8284
mysql --default-character-set=utf8mb4 -u$USER -p$PASS $DATABASE <gitea-db.sql
83-
# or sqlite3 $DATABASE_PATH <gitea-db.sql
85+
# sqlite3
86+
sqlite3 $DATABASE_PATH <gitea-db.sql
87+
# postgres
88+
psql -U $USER -d $DATABASE < gitea-db.sql
89+
8490
service gitea restart
8591
```
8692

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

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,21 @@ Gitea 已经实现了 `dump` 命令可以用来备份所有需要的文件到一
4646

4747
例如:
4848

49-
```
50-
apt-get install gitea
51-
unzip gitea-dump-1482906742.zip
52-
cd gitea-dump-1482906742
53-
mv custom/conf/app.ini /etc/gitea/conf/app.ini
54-
unzip gitea-repo.zip
55-
mv gitea-repo/* /var/lib/gitea/repositories/
56-
chown -R gitea:gitea /etc/gitea/conf/app.ini /var/lib/gitea/repositories/
49+
```sh
50+
unzip gitea-dump-1610949662.zip
51+
cd gitea-dump-1610949662
52+
mv data/conf/app.ini /etc/gitea/conf/app.ini
53+
mv data/* /var/lib/gitea/data/
54+
mv log/* /var/lib/gitea/log/
55+
mv repos/* /var/lib/gitea/repositories/
56+
chown -R gitea:gitea /etc/gitea/conf/app.ini /var/lib/gitea
57+
58+
# mysql
5759
mysql --default-character-set=utf8mb4 -u$USER -p$PASS $DATABASE <gitea-db.sql
58-
# or sqlite3 $DATABASE_PATH <gitea-db.sql
60+
# sqlite3
61+
sqlite3 $DATABASE_PATH <gitea-db.sql
62+
# postgres
63+
psql -U $USER -d $DATABASE < gitea-db.sql
64+
5965
service gitea restart
6066
```

docs/content/doc/usage/backup-and-restore.zh-tw.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,3 +43,23 @@ Gitea 目前支援 `dump` 指令,用來將資料備份成 zip 檔案,後續
4343
## 還原指令 (`restore`)
4444

4545
持續更新中: 此文件尚未完成.
46+
47+
例:
48+
```sh
49+
unzip gitea-dump-1610949662.zip
50+
cd gitea-dump-1610949662
51+
mv data/conf/app.ini /etc/gitea/conf/app.ini
52+
mv data/* /var/lib/gitea/data/
53+
mv log/* /var/lib/gitea/log/
54+
mv repos/* /var/lib/gitea/repositories/
55+
chown -R gitea:gitea /etc/gitea/conf/app.ini /var/lib/gitea
56+
57+
# mysql
58+
mysql --default-character-set=utf8mb4 -u$USER -p$PASS $DATABASE <gitea-db.sql
59+
# sqlite3
60+
sqlite3 $DATABASE_PATH <gitea-db.sql
61+
# postgres
62+
psql -U $USER -d $DATABASE < gitea-db.sql
63+
64+
service gitea restart
65+
```

go.mod

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,15 @@ require (
2323
github.com/alecthomas/chroma v0.8.2
2424
github.com/andybalholm/brotli v1.0.1 // indirect
2525
github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be // indirect
26-
github.com/blevesearch/bleve v1.0.14
26+
github.com/blevesearch/bleve/v2 v2.0.1
2727
github.com/cpuguy83/go-md2man/v2 v2.0.0 // indirect
2828
github.com/denisenkom/go-mssqldb v0.9.0
2929
github.com/dgrijalva/jwt-go v3.2.0+incompatible
3030
github.com/dlclark/regexp2 v1.4.0 // indirect
3131
github.com/dustin/go-humanize v1.0.0
3232
github.com/editorconfig/editorconfig-core-go/v2 v2.3.9
3333
github.com/emirpasic/gods v1.12.0
34-
github.com/ethantkoenig/rupture v0.0.0-20181029165146-c3b3b810dc77
34+
github.com/ethantkoenig/rupture v1.0.0
3535
github.com/gliderlabs/ssh v0.3.1
3636
github.com/glycerine/go-unsnap-stream v0.0.0-20190901134440-81cf024a9e0a // indirect
3737
github.com/go-chi/chi v1.5.1
@@ -90,7 +90,7 @@ require (
9090
github.com/shurcooL/vfsgen v0.0.0-20200824052919-0d455de96546
9191
github.com/spf13/viper v1.7.1 // indirect
9292
github.com/ssor/bom v0.0.0-20170718123548-6386211fdfcf // indirect
93-
github.com/stretchr/testify v1.6.1
93+
github.com/stretchr/testify v1.7.0
9494
github.com/syndtr/goleveldb v1.0.0
9595
github.com/tinylib/msgp v1.1.5 // indirect
9696
github.com/tstranex/u2f v1.0.0
@@ -111,7 +111,7 @@ require (
111111
golang.org/x/crypto v0.0.0-20201217014255-9d1352758620
112112
golang.org/x/net v0.0.0-20201031054903-ff519b6c9102
113113
golang.org/x/oauth2 v0.0.0-20200902213428-5d25da1a8d43
114-
golang.org/x/sys v0.0.0-20201211090839-8ad439b19e0f
114+
golang.org/x/sys v0.0.0-20210113181707-4bcb84eeeb78
115115
golang.org/x/text v0.3.4
116116
golang.org/x/time v0.0.0-20200630173020-3af7569d3a1e // indirect
117117
golang.org/x/tools v0.0.0-20201022035929-9cf592e881e9

0 commit comments

Comments
 (0)