mirror of
https://github.com/go-gitea/gitea.git
synced 2025-08-10 04:21:48 +02:00
Compare commits
715 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
f3cacf1332 | ||
|
a15dc93011 | ||
|
66b31786d3 | ||
|
931ddfec6d | ||
|
7e0a5b17db | ||
|
07688231c2 | ||
|
21eaeb8418 | ||
|
9a929ad17f | ||
|
c19ac41b34 | ||
|
fd85d31cb4 | ||
|
c9e4d7a564 | ||
|
9990430e32 | ||
|
6f5656ab0e | ||
|
e4a876cee1 | ||
|
abb534ba7a | ||
|
65dceb6a40 | ||
|
db26f0aca9 | ||
|
76878fd69b | ||
|
3444fa2dd7 | ||
|
caa2aeaa52 | ||
|
11300ee582 | ||
|
c6b78c3d31 | ||
|
4c40aa5be9 | ||
|
50f2e90b76 | ||
|
5d11ccc9e1 | ||
|
93860af542 | ||
|
7bf5834f2c | ||
|
1fbdd9335f | ||
|
e9061a537c | ||
|
ed664a9e1d | ||
|
4cb18601ff | ||
|
3abb25166c | ||
|
9e6ad64d48 | ||
|
b51d7c459e | ||
|
d3b6f001fe | ||
|
e938f1d945 | ||
|
7284327a00 | ||
|
919f3f11e2 | ||
|
3cee15e6f9 | ||
|
34e3644ada | ||
|
14bd120cdc | ||
|
3e40f8bebc | ||
|
df5f1d9dca | ||
|
457ee1ab5a | ||
|
4f64688902 | ||
|
117dcf1c02 | ||
|
4529a262c0 | ||
|
ff24f81a05 | ||
|
e3cb4f9d0e | ||
|
9b7890f1cc | ||
|
eb064dfda2 | ||
|
f9e66e5a46 | ||
|
ef89260cf1 | ||
|
315d928626 | ||
|
5525452bdf | ||
|
987cd277f6 | ||
|
5cdfde2ebf | ||
|
1cd6233cef | ||
|
cb81e39f7a | ||
|
8efd6b32e2 | ||
|
c95d9603ea | ||
|
9169b39458 | ||
|
80eb50655a | ||
|
b16c555541 | ||
|
b5b44364e3 | ||
|
6af58022c8 | ||
|
e48b460a0a | ||
|
2cd2614eaa | ||
|
0129e76ef5 | ||
|
6896dad675 | ||
|
1ed4323005 | ||
|
049af0d3d0 | ||
|
f5727d83dd | ||
|
912ce27421 | ||
|
b3549bb5ec | ||
|
491cbeca67 | ||
|
895d92ffe5 | ||
|
4b11f967bd | ||
|
1e73dd2446 | ||
|
315026c2c5 | ||
|
16dfd9ffbe | ||
|
16f7b43903 | ||
|
043febdbc9 | ||
|
60f91d56f0 | ||
|
16fc15ae6a | ||
|
ef8f6d99f1 | ||
|
4b688135f9 | ||
|
e24861a546 | ||
|
128cc34344 | ||
|
f82a805478 | ||
|
0dced15c1a | ||
|
db9342c854 | ||
|
79c1d48532 | ||
|
05b9864086 | ||
|
ff508c9c9b | ||
|
f96c1a2c79 | ||
|
ce756ee89f | ||
|
f2e9d4b851 | ||
|
e878d743f4 | ||
|
3fa14d89a2 | ||
|
bcb722daec | ||
|
8add1dfacc | ||
|
aa6ed1b7c1 | ||
|
95cb921097 | ||
|
6730df9e8c | ||
|
b577500a54 | ||
|
fe46185407 | ||
|
69a2a29c33 | ||
|
f766719895 | ||
|
e2ddc42377 | ||
|
3521177a34 | ||
|
c8bb0ecf52 | ||
|
dbe6136348 | ||
|
6d1f7e90cf | ||
|
42663a687c | ||
|
73c90c26d4 | ||
|
c579ad92b5 | ||
|
602c5da953 | ||
|
1980e59ac2 | ||
|
28508792ba | ||
|
3e23dad075 | ||
|
b13b9d3dbd | ||
|
4072f28e60 | ||
|
dbeef6bb02 | ||
|
fec35440db | ||
|
f8ea50cc7a | ||
|
0e53a16cca | ||
|
7eaba6ba8a | ||
|
ff16099c6d | ||
|
a516a7ba0f | ||
|
11bce6fd3d | ||
|
3fb906dc02 | ||
|
3a00a690c9 | ||
|
a2b7cc1bb1 | ||
|
04a77b1f42 | ||
|
f523372d07 | ||
|
e39c238ef4 | ||
|
bb4476908d | ||
|
c181070f9e | ||
|
1e9b3d4743 | ||
|
b9309e52f0 | ||
|
e5d8e2d10c | ||
|
9406368633 | ||
|
b6fa229dcf | ||
|
0d515474b8 | ||
|
c88f0fed36 | ||
|
62eb1b0f25 | ||
|
f71e1c8e79 | ||
|
143f88d975 | ||
|
5749b26cdd | ||
|
abc0f53539 | ||
|
bcac7cb934 | ||
|
2a1cf5bae9 | ||
|
133ae18b61 | ||
|
7e4f490482 | ||
|
444c3a1184 | ||
|
a5a79f702d | ||
|
4f54a4628a | ||
|
08424648ae | ||
|
03d59bcd1d | ||
|
8b24073713 | ||
|
6a5a2f493a | ||
|
fb3a6aba7d | ||
|
07439d8059 | ||
|
2b8b0f66ed | ||
|
ee9b9365be | ||
|
bedd7b2833 | ||
|
4a768e1c3e | ||
|
34c5eee703 | ||
|
ea707f5a77 | ||
|
b39fab41c8 | ||
|
134e3fdf3d | ||
|
b3c5b4b0d1 | ||
|
09bf77bc4f | ||
|
4ab072d9c2 | ||
|
5b9283ddfe | ||
|
b2b10858c6 | ||
|
9cf7048a6a | ||
|
c620eb5b2d | ||
|
d1798f77f6 | ||
|
a864d61ee6 | ||
|
7bdf17ec29 | ||
|
8941f7fc01 | ||
|
0989404d2f | ||
|
9600c27085 | ||
|
655aea13a5 | ||
|
27757714d0 | ||
|
0c07f1de5b | ||
|
b983ff4473 | ||
|
c2d854cfd2 | ||
|
d59536c222 | ||
|
ae9d342f54 | ||
|
98bc3e1da8 | ||
|
a70e822100 | ||
|
261c3a56a2 | ||
|
599c0ee75f | ||
|
ed67bbe444 | ||
|
1ea447aedf | ||
|
81e63d0714 | ||
|
10455a88dc | ||
|
55cd33e124 | ||
|
884173232f | ||
|
4ee97465e9 | ||
|
e64880ef07 | ||
|
4acca9d2e8 | ||
|
f2d03cda96 | ||
|
0bcf644da4 | ||
|
e3a5b83212 | ||
|
145c1ea0b6 | ||
|
154424623a | ||
|
3d5f31f77d | ||
|
2401779aac | ||
|
d86e587186 | ||
|
5748755e8e | ||
|
1db2381546 | ||
|
7bfb83e064 | ||
|
114d474f02 | ||
|
c0f8795462 | ||
|
3e166bd055 | ||
|
8b2f29c0d2 | ||
|
f88715e29c | ||
|
8e655728e9 | ||
|
30181d459d | ||
|
34688e1db3 | ||
|
e394504937 | ||
|
40e99ea010 | ||
|
017f314b5a | ||
|
546523a57c | ||
|
e6ceb6880a | ||
|
071e7c4f0a | ||
|
2de8b27dd1 | ||
|
89b4e0477b | ||
|
2f9564f993 | ||
|
1df701fd1a | ||
|
875d6b2f8e | ||
|
8149ed7040 | ||
|
4f42e03a35 | ||
|
f8a6eb8f32 | ||
|
a13654562c | ||
|
2848c5eb8f | ||
|
050a8af424 | ||
|
e2fc0a0dfd | ||
|
db5524a9ab | ||
|
d9a0ba2cac | ||
|
f5a25d5349 | ||
|
e57f763937 | ||
|
4147cc91ed | ||
|
559fb6ccf0 | ||
|
8873a80276 | ||
|
d644934956 | ||
|
21f84a6315 | ||
|
d66ae50fd5 | ||
|
1b8a9197b3 | ||
|
90057ca27e | ||
|
6d811bcb14 | ||
|
3b4682e172 | ||
|
8a208e4349 | ||
|
c939d610b9 | ||
|
04ab1138f6 | ||
|
669791be99 | ||
|
ba8f93a14e | ||
|
590d56dbb3 | ||
|
601b0cf4c1 | ||
|
2b0e4e0cb8 | ||
|
412679fd8b | ||
|
2b7e4cc1bd | ||
|
59fc29db38 | ||
|
ffc904b1e0 | ||
|
d1a49977b0 | ||
|
1707f59966 | ||
|
33662399d5 | ||
|
1bbb2a637c | ||
|
4714fa6642 | ||
|
121977c36f | ||
|
61db834904 | ||
|
59d6401486 | ||
|
43ada65571 | ||
|
67b316a954 | ||
|
c6b3c5bcef | ||
|
7217b703e9 | ||
|
60b31c8f01 | ||
|
f6b29012e0 | ||
|
7cc16740a5 | ||
|
3abe17f9e0 | ||
|
e3c3b33ea7 | ||
|
8bea92c3dc | ||
|
ce2d488c94 | ||
|
6715677b2b | ||
|
47c24be293 | ||
|
7b2ff82d20 | ||
|
2904abdc22 | ||
|
484e3dc5a9 | ||
|
f6ba912cd6 | ||
|
bfcce5f86c | ||
|
f46176a418 | ||
|
81a52442a1 | ||
|
74179d1b5e | ||
|
8f16a2c37b | ||
|
f09cdb239c | ||
|
6e6936d73d | ||
|
39db99a595 | ||
|
6442e003c5 | ||
|
27f68bc96f | ||
|
ba1acf5b50 | ||
|
dc2fe9801f | ||
|
751cfb805d | ||
|
aceb1085c7 | ||
|
382936a668 | ||
|
3bf5a07537 | ||
|
c3d31e5534 | ||
|
50da9f7dae | ||
|
2c83dac5d4 | ||
|
4dc3993b22 | ||
|
d3a9c4ceec | ||
|
2d8a89563d | ||
|
7f0d7c0a17 | ||
|
c34fdf7e33 | ||
|
baae90e163 | ||
|
be06dee04c | ||
|
baf089e5b9 | ||
|
3f42934b9a | ||
|
95a57394af | ||
|
15254f5762 | ||
|
cbf18f61d1 | ||
|
3da6d256f4 | ||
|
37e10d4543 | ||
|
ee7df7ba8c | ||
|
cecc31951c | ||
|
0e56337f64 | ||
|
ef98b168f7 | ||
|
9cb418e623 | ||
|
82e0383d21 | ||
|
1583c48e3a | ||
|
eba816e826 | ||
|
0a9abcb84c | ||
|
d672206800 | ||
|
e3081c667a | ||
|
77730db257 | ||
|
9ff5b75559 | ||
|
d7c52b8dce | ||
|
1718a9591c | ||
|
43f7b97c4a | ||
|
48be1889cd | ||
|
d9c67a8c90 | ||
|
e80fe201c0 | ||
|
7ccaf54140 | ||
|
8875586570 | ||
|
bac4b78e09 | ||
|
6460284085 | ||
|
9a33adcdd3 | ||
|
bdbdd6608f | ||
|
18236973e9 | ||
|
4256781781 | ||
|
e43de0db4c | ||
|
e459f99ef2 | ||
|
23ef9ff516 | ||
|
51432ebb9c | ||
|
a00d7200b1 | ||
|
1aa7e27dd0 | ||
|
33fc48c8ae | ||
|
6e81eafdd6 | ||
|
2fc3eb1d15 | ||
|
66028d58f9 | ||
|
668eaf95d5 | ||
|
674bc772fb | ||
|
6a90c7e3dd | ||
|
2011a5b818 | ||
|
7c6f2e27be | ||
|
61c59bd695 | ||
|
60c5339042 | ||
|
8f8c250ddb | ||
|
15a5c10d33 | ||
|
c9d50bcab5 | ||
|
d7c1310353 | ||
|
e151674cfa | ||
|
54dab5aed9 | ||
|
3bdce82ce9 | ||
|
ef9a0370ca | ||
|
6e578dd0c9 | ||
|
9591185c8f | ||
|
b50dee5a61 | ||
|
7b7d382b8b | ||
|
9d9e6ac411 | ||
|
055f6d2296 | ||
|
f5bd0884d2 | ||
|
802aa6d5f3 | ||
|
62bcb2b7f1 | ||
|
95c3dc856a | ||
|
e8241bf55e | ||
|
d0edb607a3 | ||
|
e84326aaec | ||
|
f25fd5c8eb | ||
|
7523314ef8 | ||
|
d779deef6e | ||
|
8ab35eefc4 | ||
|
e3f22ad2cc | ||
|
bb2c0c3729 | ||
|
e6036d9899 | ||
|
9856ac5818 | ||
|
7b4d2f7a2a | ||
|
eb1b225d9a | ||
|
a4e398dc45 | ||
|
cbd2bebec0 | ||
|
675f275237 | ||
|
30fde478db | ||
|
513b9fc988 | ||
|
ba9a2d2abb | ||
|
7bc8c6b180 | ||
|
f0aaffeedc | ||
|
cbaa1de9ec | ||
|
d7ac9727bb | ||
|
d5261b9aab | ||
|
51ed4cc063 | ||
|
dd82e401fd | ||
|
8f49b1232a | ||
|
1615b3c187 | ||
|
2ab8c78c30 | ||
|
dfd8b94923 | ||
|
69a255defb | ||
|
35c3ea952a | ||
|
a85d916d3e | ||
|
a88a58a83e | ||
|
05f6eccf27 | ||
|
108bed2023 | ||
|
e4ec32de2e | ||
|
4a357f4188 | ||
|
c57edb6c7b | ||
|
eb0359cad4 | ||
|
af7f08bca8 | ||
|
5a3af7992c | ||
|
9ccb50f162 | ||
|
2c2b9718e6 | ||
|
f128e06ea6 | ||
|
d338e8238f | ||
|
64769c8a6b | ||
|
b15f26b1cf | ||
|
08ae6bb7ed | ||
|
9ff6312627 | ||
|
ba4e8f221b | ||
|
ef513e1af3 | ||
|
f8bd90ba60 | ||
|
06984bbcbf | ||
|
1c911aa825 | ||
|
9275390423 | ||
|
aa178176db | ||
|
8f09aff427 | ||
|
184e47f6ce | ||
|
86cff86b46 | ||
|
3dfe9190b0 | ||
|
f4bdcd6e2b | ||
|
9feab29405 | ||
|
4f9443cf8e | ||
|
1b7182e5ec | ||
|
6fbfffeeb8 | ||
|
11208f3381 | ||
|
69cfff1541 | ||
|
e0e4473172 | ||
|
c58fba944d | ||
|
7719009706 | ||
|
9930d47be2 | ||
|
97dc314652 | ||
|
c0c2624079 | ||
|
21ae9838e0 | ||
|
b30d744e09 | ||
|
896ad1d9cf | ||
|
149a9df9e8 | ||
|
42ada741e3 | ||
|
06a8504c78 | ||
|
dd1beee2ef | ||
|
3621944c2d | ||
|
4b5ebb93e4 | ||
|
ae36ed7ecb | ||
|
665ce1dcb3 | ||
|
9bd879bef8 | ||
|
856a9f8181 | ||
|
a99b4dbe01 | ||
|
a3e42bfebd | ||
|
1716150ced | ||
|
c9b564ccdb | ||
|
04e6d761bc | ||
|
dad67cae54 | ||
|
16a43156a8 | ||
|
7b75603ffe | ||
|
b41f303ae0 | ||
|
8282f26250 | ||
|
3b0303a4fc | ||
|
afe50873a5 | ||
|
71395dffd0 | ||
|
27ac1d0952 | ||
|
be869e8881 | ||
|
722a7c902d | ||
|
7b97e04555 | ||
|
cda8de2004 | ||
|
253fdfb7fa | ||
|
fd1b2a31f3 | ||
|
3ddca774fc | ||
|
4b3fc74937 | ||
|
e4e6d48e30 | ||
|
a0d4014517 | ||
|
bb6879d339 | ||
|
555b1f6581 | ||
|
173da1b5ae | ||
|
561044e422 | ||
|
74a6add4d9 | ||
|
74bb292fe3 | ||
|
8d9e625f83 | ||
|
273a24f226 | ||
|
0e281384b5 | ||
|
ee1d64ddd1 | ||
|
44ec9b933a | ||
|
01a4a7cb14 | ||
|
8eeb2877d5 | ||
|
31416a5f4e | ||
|
daab245167 | ||
|
1b7402bd1d | ||
|
bb04fb55d7 | ||
|
c54145174f | ||
|
a647a54a08 | ||
|
1f3ba6919d | ||
|
f4937879b0 | ||
|
c15d371939 | ||
|
6e1912c73a | ||
|
9ae4c17cb1 | ||
|
d2aee2a3e2 | ||
|
f02138a148 | ||
|
55bdc9aa38 | ||
|
016a5d0438 | ||
|
fb459f2c2c | ||
|
1274ad864e | ||
|
d9be82bd00 | ||
|
b747501337 | ||
|
884acf8295 | ||
|
065bbddab9 | ||
|
1f90147f39 | ||
|
d5b1e6bc51 | ||
|
f05cd3e317 | ||
|
12170d26a7 | ||
|
72aa5a20ec | ||
|
0109229928 | ||
|
6d42add37f | ||
|
8a84d82d53 | ||
|
36b8c081f6 | ||
|
9395805512 | ||
|
45f219239e | ||
|
79fd422a92 | ||
|
aaeef295bb | ||
|
05e7715c4b | ||
|
2f4ef84cbf | ||
|
c0f4675a68 | ||
|
a91679c9e3 | ||
|
8d8aecd3cf | ||
|
86a44f6b48 | ||
|
3fb9e3afe3 | ||
|
0471aae348 | ||
|
ee5249889d | ||
|
2282c659dd | ||
|
a966a0298e | ||
|
491887d441 | ||
|
7971b05d2b | ||
|
dce22efbee | ||
|
022d2d8beb | ||
|
fe7a6d9bfc | ||
|
61a3eae923 | ||
|
76185edd76 | ||
|
729708e878 | ||
|
5a187f4bcc | ||
|
dd9cb32bff | ||
|
21dfe1b256 | ||
|
232340f5e3 | ||
|
9d663dfde6 | ||
|
8f26397928 | ||
|
f518fe6662 | ||
|
4b8d9e58c5 | ||
|
484edb7583 | ||
|
0e7f7df3cf | ||
|
ba336f6f45 | ||
|
9175556da0 | ||
|
7cf56a16d2 | ||
|
ebcc38188e | ||
|
ac0fb36c41 | ||
|
4ee986e4c9 | ||
|
a2bd8fe8dc | ||
|
cb1048d780 | ||
|
887a8fe242 | ||
|
086a46994a | ||
|
690a8ec502 | ||
|
7432396514 | ||
|
de2f45f95e | ||
|
1286473386 | ||
|
b48cad6a2a | ||
|
bda70b848f | ||
|
bc1775b490 | ||
|
7d9351779f | ||
|
f9944c0e69 | ||
|
ac6accef09 | ||
|
f694bb45d7 | ||
|
56ebc0c003 | ||
|
e6706df49d | ||
|
7bb817e6d1 | ||
|
e7fbc551ab | ||
|
559803025d | ||
|
9513a6983a | ||
|
c0f97f2687 | ||
|
c4f9d06855 | ||
|
c4bc5abda3 | ||
|
d6f6f9db3f | ||
|
09b281a6ac | ||
|
fd40c9d024 | ||
|
5e6a008fba | ||
|
af8957bc4c | ||
|
e3875ace91 | ||
|
c66c9dabc7 | ||
|
495d5e4329 | ||
|
018b0e8180 | ||
|
478f7db68e | ||
|
5b33ffe7c5 | ||
|
70fa80df11 | ||
|
9e85358777 | ||
|
d2d5910894 | ||
|
8b07823680 | ||
|
6aa3f8bc29 | ||
|
c34e58fc00 | ||
|
560a511a35 | ||
|
516fd7d3ae | ||
|
fc0580a4b7 | ||
|
a520236cb5 | ||
|
0a80164bec | ||
|
3c63c3ace4 | ||
|
bd7709a602 | ||
|
ab791fe7bb | ||
|
ee7b153dd9 | ||
|
c84174b764 | ||
|
22272fe1e4 | ||
|
ace0346c66 | ||
|
3e61a9628c | ||
|
dbd9d8dd54 | ||
|
637e3219ab | ||
|
f067e12859 | ||
|
7d1a7c05db | ||
|
c2fca23b2c | ||
|
b4b0e22f5f | ||
|
2f10bfa0f6 | ||
|
3fe9646564 | ||
|
fe41f71ba1 | ||
|
a41a965db2 | ||
|
00629fea95 | ||
|
d0c7a08d75 | ||
|
2f9a66a76c | ||
|
d8161ee3fd | ||
|
73f8069249 | ||
|
b59a905394 | ||
|
41c7aa5a3a | ||
|
969a540ce2 | ||
|
bfdcedfe89 | ||
|
0bfe5eb10b | ||
|
b1c1e1549b | ||
|
b539a6e6e3 | ||
|
481c66a91f | ||
|
28f60bb5cb | ||
|
c8f3146cd5 | ||
|
2657e718b6 | ||
|
85e4190761 | ||
|
bcd96421dd | ||
|
3b379691fa | ||
|
f37b87f81e | ||
|
85609efaad | ||
|
b2b9bdaf26 | ||
|
5a62ae5cbf | ||
|
280f4bebbf | ||
|
240f46a422 | ||
|
0a004a69cd | ||
|
05e437f8fd | ||
|
23045c7d53 | ||
|
945f121262 | ||
|
fecd8f949d | ||
|
7c4c01c0fd | ||
|
d44053eeda | ||
|
17c96ee52b | ||
|
37028f0e4e | ||
|
115a1cc680 | ||
|
d151503d34 | ||
|
ae132632a9 | ||
|
cf42cb0ae6 | ||
|
c43feedb96 | ||
|
c748deef33 | ||
|
de4f10be86 | ||
|
d4cd4ed442 | ||
|
fcb535c5c3 | ||
|
1b72690cb8 | ||
|
8f0e63c80a | ||
|
50b66b66e7 | ||
|
8edf3d5804 | ||
|
1d9a1a0d45 | ||
|
0b44f0c465 | ||
|
e1505d6250 | ||
|
31655aabfc | ||
|
66e99d722a | ||
|
80655026d2 | ||
|
9b9b67cd31 | ||
|
167e8f18da | ||
|
4a290bd64c | ||
|
8c909820a9 | ||
|
d7d348ea86 | ||
|
1e9b330525 | ||
|
6fa14ac3c8 | ||
|
20477a69ea | ||
|
34fb9d68a5 | ||
|
ebe8ff782f | ||
|
cea8ea5ae6 | ||
|
8ad2697611 | ||
|
733c898a90 | ||
|
0be992a1e2 | ||
|
b6ef539ef4 | ||
|
086bfb8b4b | ||
|
3083522620 |
@@ -1,44 +1,57 @@
|
||||
# The full repository name
|
||||
repo: go-gitea/gitea
|
||||
|
||||
# Service type (gitea or github)
|
||||
service: github
|
||||
|
||||
# Base URL for Gitea instance if using gitea service type (optional)
|
||||
# Default: https://gitea.com
|
||||
base-url:
|
||||
|
||||
# Changelog groups and which labeled PRs to add to each group
|
||||
groups:
|
||||
-
|
||||
-
|
||||
name: BREAKING
|
||||
labels:
|
||||
- kind/breaking
|
||||
-
|
||||
-
|
||||
name: FEATURE
|
||||
labels:
|
||||
- kind/feature
|
||||
-
|
||||
name: SECURITY
|
||||
labels:
|
||||
- kind/security
|
||||
-
|
||||
name: BUGFIXES
|
||||
labels:
|
||||
- kind/bug
|
||||
-
|
||||
-
|
||||
name: ENHANCEMENT
|
||||
labels:
|
||||
- kind/enhancement
|
||||
- kind/refactor
|
||||
- kind/ui
|
||||
-
|
||||
name: SECURITY
|
||||
labels:
|
||||
- kind/security
|
||||
-
|
||||
name: TESTING
|
||||
labels:
|
||||
- kind/testing
|
||||
-
|
||||
-
|
||||
name: TRANSLATION
|
||||
labels:
|
||||
- kind/translation
|
||||
-
|
||||
-
|
||||
name: BUILD
|
||||
labels:
|
||||
- kind/build
|
||||
- kind/lint
|
||||
-
|
||||
-
|
||||
name: DOCS
|
||||
labels:
|
||||
- kind/docs
|
||||
-
|
||||
-
|
||||
name: MISC
|
||||
default: true
|
||||
default: true
|
||||
|
||||
# regex indicating which labels to skip for the changelog
|
||||
skip-labels: skip-changelog|backport\/.+
|
||||
|
448
.drone.yml
448
.drone.yml
@@ -1,62 +1,19 @@
|
||||
---
|
||||
kind: pipeline
|
||||
name: testing
|
||||
name: compliance
|
||||
|
||||
platform:
|
||||
os: linux
|
||||
arch: amd64
|
||||
arch: arm64
|
||||
|
||||
workspace:
|
||||
base: /go
|
||||
path: src/code.gitea.io/gitea
|
||||
|
||||
services:
|
||||
- name: mysql
|
||||
pull: default
|
||||
image: mysql:5.7
|
||||
environment:
|
||||
MYSQL_ALLOW_EMPTY_PASSWORD: yes
|
||||
MYSQL_DATABASE: test
|
||||
|
||||
- name: mysql8
|
||||
pull: default
|
||||
image: mysql:8.0
|
||||
environment:
|
||||
MYSQL_ALLOW_EMPTY_PASSWORD: yes
|
||||
MYSQL_DATABASE: testgitea
|
||||
|
||||
- name: pgsql
|
||||
pull: default
|
||||
image: postgres:9.5
|
||||
environment:
|
||||
POSTGRES_DB: test
|
||||
|
||||
- name: mssql
|
||||
pull: default
|
||||
image: microsoft/mssql-server-linux:latest
|
||||
environment:
|
||||
ACCEPT_EULA: Y
|
||||
MSSQL_PID: Standard
|
||||
SA_PASSWORD: MwantsaSecurePassword1
|
||||
|
||||
- name: ldap
|
||||
pull: default
|
||||
image: gitea/test-openldap:latest
|
||||
|
||||
steps:
|
||||
- name: fetch-tags
|
||||
pull: default
|
||||
image: docker:git
|
||||
commands:
|
||||
- git fetch --tags --force
|
||||
when:
|
||||
event:
|
||||
exclude:
|
||||
- pull_request
|
||||
|
||||
- name: pre-build
|
||||
pull: always
|
||||
image: webhippie/nodejs:latest
|
||||
image: node:10 # this step is kept at the lowest version of node that we support
|
||||
commands:
|
||||
- make css
|
||||
- make js
|
||||
@@ -81,23 +38,88 @@ steps:
|
||||
commands:
|
||||
- go build -mod=vendor -o gitea_linux_386 # test if compatible with 32 bit
|
||||
|
||||
- name: build
|
||||
- name: check
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- make clean
|
||||
- make generate
|
||||
- make golangci-lint
|
||||
- make revive
|
||||
- make swagger-check
|
||||
- make swagger-validate
|
||||
- make test-vendor
|
||||
environment:
|
||||
GOPROXY: https://goproxy.cn # proxy.golang.org is blocked in China, this proxy is not
|
||||
GOSUMDB: sum.golang.org
|
||||
TAGS: bindata sqlite sqlite_unlock_notify
|
||||
|
||||
---
|
||||
kind: pipeline
|
||||
name: testing-amd64
|
||||
|
||||
platform:
|
||||
os: linux
|
||||
arch: amd64
|
||||
|
||||
workspace:
|
||||
base: /go
|
||||
path: src/code.gitea.io/gitea
|
||||
|
||||
services:
|
||||
- name: mysql
|
||||
pull: default
|
||||
image: mysql:5.7
|
||||
environment:
|
||||
MYSQL_ALLOW_EMPTY_PASSWORD: yes
|
||||
MYSQL_DATABASE: test
|
||||
|
||||
- name: mysql8
|
||||
pull: default
|
||||
image: mysql:8.0
|
||||
environment:
|
||||
MYSQL_ALLOW_EMPTY_PASSWORD: yes
|
||||
MYSQL_DATABASE: testgitea
|
||||
|
||||
- name: mssql
|
||||
pull: default
|
||||
image: mcr.microsoft.com/mssql/server:latest
|
||||
environment:
|
||||
ACCEPT_EULA: Y
|
||||
MSSQL_PID: Standard
|
||||
SA_PASSWORD: MwantsaSecurePassword1
|
||||
|
||||
- name: ldap
|
||||
pull: default
|
||||
image: gitea/test-openldap:latest
|
||||
|
||||
steps:
|
||||
- name: fetch-tags
|
||||
pull: default
|
||||
image: docker:git
|
||||
commands:
|
||||
- git fetch --tags --force
|
||||
when:
|
||||
event:
|
||||
exclude:
|
||||
- pull_request
|
||||
|
||||
- name: build
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- curl -sL https://deb.nodesource.com/setup_12.x | bash - && apt -y install nodejs
|
||||
- make build
|
||||
environment:
|
||||
GOPROXY: https://goproxy.cn # proxy.golang.org is blocked in China, this proxy is not
|
||||
GOSUMDB: sum.golang.org
|
||||
TAGS: bindata sqlite sqlite_unlock_notify
|
||||
|
||||
- name: tag-pre-condition
|
||||
pull: always
|
||||
image: alpine/git
|
||||
commands:
|
||||
- git update-ref refs/heads/tag_test ${DRONE_COMMIT_SHA}
|
||||
|
||||
- name: unit-test
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
@@ -106,70 +128,8 @@ steps:
|
||||
environment:
|
||||
GOPROXY: off
|
||||
TAGS: bindata sqlite sqlite_unlock_notify
|
||||
depends_on:
|
||||
- build
|
||||
when:
|
||||
branch:
|
||||
- master
|
||||
event:
|
||||
- push
|
||||
- pull_request
|
||||
|
||||
- name: release-test
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- make test
|
||||
environment:
|
||||
GOPROXY: off
|
||||
TAGS: bindata sqlite sqlite_unlock_notify
|
||||
depends_on:
|
||||
- build
|
||||
when:
|
||||
branch:
|
||||
- "release/*"
|
||||
event:
|
||||
- push
|
||||
- pull_request
|
||||
|
||||
- name: tag-pre-condition
|
||||
pull: always
|
||||
image: alpine/git
|
||||
commands:
|
||||
- git update-ref refs/heads/tag_test ${DRONE_COMMIT_SHA}
|
||||
depends_on:
|
||||
- build
|
||||
when:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: tag-test
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- make test
|
||||
environment:
|
||||
GOPROXY: off
|
||||
TAGS: bindata
|
||||
depends_on:
|
||||
- tag-pre-condition
|
||||
when:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: test-sqlite
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- "curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash"
|
||||
- apt-get install -y git-lfs
|
||||
- timeout -s ABRT 20m make test-sqlite-migration
|
||||
- timeout -s ABRT 20m make test-sqlite
|
||||
environment:
|
||||
GOPROXY: off
|
||||
TAGS: bindata
|
||||
depends_on:
|
||||
- build
|
||||
GITHUB_READ_TOKEN:
|
||||
from_secret: github_read_token
|
||||
|
||||
- name: test-mysql
|
||||
pull: always
|
||||
@@ -185,30 +145,6 @@ steps:
|
||||
TEST_LDAP: 1
|
||||
depends_on:
|
||||
- build
|
||||
when:
|
||||
branch:
|
||||
- master
|
||||
event:
|
||||
- push
|
||||
- pull_request
|
||||
|
||||
- name: tag-test-mysql
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- "curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash"
|
||||
- apt-get install -y git-lfs
|
||||
- timeout -s ABRT 20m make test-mysql-migration
|
||||
- timeout -s ABRT 20m make test-mysql
|
||||
environment:
|
||||
GOPROXY: off
|
||||
TAGS: bindata
|
||||
TEST_LDAP: 1
|
||||
depends_on:
|
||||
- build
|
||||
when:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: test-mysql8
|
||||
pull: always
|
||||
@@ -225,21 +161,6 @@ steps:
|
||||
depends_on:
|
||||
- build
|
||||
|
||||
- name: test-pgsql
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- "curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash"
|
||||
- apt-get install -y git-lfs
|
||||
- timeout -s ABRT 20m make test-pgsql-migration
|
||||
- timeout -s ABRT 20m make test-pgsql
|
||||
environment:
|
||||
GOPROXY: off
|
||||
TAGS: bindata
|
||||
TEST_LDAP: 1
|
||||
depends_on:
|
||||
- build
|
||||
|
||||
- name: test-mssql
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
@@ -291,13 +212,90 @@ steps:
|
||||
- push
|
||||
- pull_request
|
||||
|
||||
|
||||
|
||||
---
|
||||
kind: pipeline
|
||||
name: testing-arm64
|
||||
|
||||
platform:
|
||||
os: linux
|
||||
arch: arm64
|
||||
|
||||
workspace:
|
||||
base: /go
|
||||
path: src/code.gitea.io/gitea
|
||||
|
||||
services:
|
||||
- name: pgsql
|
||||
pull: default
|
||||
image: postgres:9.5
|
||||
environment:
|
||||
POSTGRES_DB: test
|
||||
POSTGRES_PASSWORD: postgres
|
||||
|
||||
- name: ldap
|
||||
pull: default
|
||||
image: gitea/test-openldap:latest
|
||||
|
||||
steps:
|
||||
- name: fetch-tags
|
||||
pull: default
|
||||
image: docker:git
|
||||
commands:
|
||||
- git fetch --tags --force
|
||||
when:
|
||||
event:
|
||||
exclude:
|
||||
- pull_request
|
||||
|
||||
- name: build
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- curl -sL https://deb.nodesource.com/setup_12.x | bash - && apt -y install nodejs
|
||||
- make build
|
||||
environment:
|
||||
GOPROXY: https://goproxy.cn # proxy.golang.org is blocked in China, this proxy is not
|
||||
GOSUMDB: sum.golang.org
|
||||
TAGS: bindata sqlite sqlite_unlock_notify
|
||||
|
||||
- name: test-sqlite
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- "curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash"
|
||||
- apt-get install -y git-lfs
|
||||
- timeout -s ABRT 20m make test-sqlite-migration
|
||||
- timeout -s ABRT 20m make test-sqlite
|
||||
environment:
|
||||
GOPROXY: off
|
||||
TAGS: bindata
|
||||
depends_on:
|
||||
- build
|
||||
|
||||
- name: test-pgsql
|
||||
pull: always
|
||||
image: golang:1.13
|
||||
commands:
|
||||
- "curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash"
|
||||
- apt-get install -y git-lfs
|
||||
- timeout -s ABRT 20m make test-pgsql-migration
|
||||
- timeout -s ABRT 20m make test-pgsql
|
||||
environment:
|
||||
GOPROXY: off
|
||||
TAGS: bindata
|
||||
TEST_LDAP: 1
|
||||
depends_on:
|
||||
- build
|
||||
|
||||
---
|
||||
kind: pipeline
|
||||
name: translations
|
||||
|
||||
platform:
|
||||
os: linux
|
||||
arch: amd64
|
||||
arch: arm64
|
||||
|
||||
workspace:
|
||||
base: /go
|
||||
@@ -324,7 +322,7 @@ steps:
|
||||
|
||||
- name: update
|
||||
pull: default
|
||||
image: alpine:3.10
|
||||
image: alpine:3.11
|
||||
commands:
|
||||
- mv ./options/locale/locale_en-US.ini ./options/
|
||||
- "sed -i -e 's/=\"/=/g' -e 's/\"$$//g' ./options/locale/*.ini"
|
||||
@@ -376,7 +374,8 @@ trigger:
|
||||
- push
|
||||
|
||||
depends_on:
|
||||
- testing
|
||||
- testing-amd64
|
||||
- testing-arm64
|
||||
- translations
|
||||
|
||||
steps:
|
||||
@@ -388,10 +387,11 @@ steps:
|
||||
|
||||
- name: static
|
||||
pull: always
|
||||
image: techknowlogick/xgo:latest
|
||||
image: techknowlogick/xgo:go-1.13.x
|
||||
commands:
|
||||
- apt update && apt -y install curl
|
||||
- curl -sL https://deb.nodesource.com/setup_12.x | bash - && apt -y install nodejs
|
||||
- export PATH=$PATH:$GOPATH/bin
|
||||
- make generate
|
||||
- make release
|
||||
environment:
|
||||
GOPROXY: off
|
||||
@@ -411,8 +411,6 @@ steps:
|
||||
from_secret: gpgsign_key
|
||||
GPGSIGN_PASSPHRASE:
|
||||
from_secret: gpgsign_passphrase
|
||||
depends_on:
|
||||
- static
|
||||
|
||||
- name: release-branch-release
|
||||
pull: always
|
||||
@@ -430,8 +428,6 @@ steps:
|
||||
from_secret: aws_access_key_id
|
||||
AWS_SECRET_ACCESS_KEY:
|
||||
from_secret: aws_secret_access_key
|
||||
depends_on:
|
||||
- gpg-sign
|
||||
when:
|
||||
branch:
|
||||
- "release/*"
|
||||
@@ -454,8 +450,6 @@ steps:
|
||||
from_secret: aws_access_key_id
|
||||
AWS_SECRET_ACCESS_KEY:
|
||||
from_secret: aws_secret_access_key
|
||||
depends_on:
|
||||
- gpg-sign
|
||||
when:
|
||||
branch:
|
||||
- master
|
||||
@@ -479,7 +473,8 @@ trigger:
|
||||
- tag
|
||||
|
||||
depends_on:
|
||||
- testing
|
||||
- testing-arm64
|
||||
- testing-amd64
|
||||
|
||||
steps:
|
||||
- name: fetch-tags
|
||||
@@ -490,10 +485,11 @@ steps:
|
||||
|
||||
- name: static
|
||||
pull: always
|
||||
image: techknowlogick/xgo:latest
|
||||
image: techknowlogick/xgo:go-1.13.x
|
||||
commands:
|
||||
- apt update && apt -y install curl
|
||||
- curl -sL https://deb.nodesource.com/setup_12.x | bash - && apt -y install nodejs
|
||||
- export PATH=$PATH:$GOPATH/bin
|
||||
- make generate
|
||||
- make release
|
||||
environment:
|
||||
GOPROXY: off
|
||||
@@ -513,8 +509,6 @@ steps:
|
||||
from_secret: gpgsign_key
|
||||
GPGSIGN_PASSPHRASE:
|
||||
from_secret: gpgsign_passphrase
|
||||
depends_on:
|
||||
- static
|
||||
|
||||
- name: release
|
||||
pull: always
|
||||
@@ -532,8 +526,6 @@ steps:
|
||||
from_secret: aws_access_key_id
|
||||
AWS_SECRET_ACCESS_KEY:
|
||||
from_secret: aws_secret_access_key
|
||||
depends_on:
|
||||
- gpg-sign
|
||||
|
||||
- name: github
|
||||
pull: always
|
||||
@@ -544,8 +536,6 @@ steps:
|
||||
environment:
|
||||
GITHUB_TOKEN:
|
||||
from_secret: github_token
|
||||
depends_on:
|
||||
- gpg-sign
|
||||
|
||||
---
|
||||
kind: pipeline
|
||||
@@ -553,17 +543,14 @@ name: docs
|
||||
|
||||
platform:
|
||||
os: linux
|
||||
arch: amd64
|
||||
|
||||
workspace:
|
||||
base: /go
|
||||
path: src/code.gitea.io/gitea
|
||||
arch: arm64
|
||||
|
||||
steps:
|
||||
- name: build-docs
|
||||
pull: always
|
||||
image: webhippie/hugo:latest
|
||||
image: plugins/hugo:latest
|
||||
commands:
|
||||
- apk add --no-cache make bash curl
|
||||
- cd docs
|
||||
- make trans-copy
|
||||
- make clean
|
||||
@@ -571,7 +558,7 @@ steps:
|
||||
|
||||
- name: publish-docs
|
||||
pull: always
|
||||
image: lucap/drone-netlify:latest
|
||||
image: techknowlogick/drone-netlify:latest
|
||||
settings:
|
||||
path: docs/public/
|
||||
site_id: d2260bae-7861-4c02-8646-8f6440b12672
|
||||
@@ -586,7 +573,7 @@ steps:
|
||||
|
||||
---
|
||||
kind: pipeline
|
||||
name: docker-linux-amd64
|
||||
name: docker-linux-amd64-release
|
||||
|
||||
platform:
|
||||
os: linux
|
||||
@@ -597,13 +584,13 @@ workspace:
|
||||
path: src/code.gitea.io/gitea
|
||||
|
||||
depends_on:
|
||||
- testing
|
||||
- testing-amd64
|
||||
- testing-arm64
|
||||
|
||||
trigger:
|
||||
ref:
|
||||
- refs/heads/master
|
||||
- "refs/tags/**"
|
||||
- "refs/pull/**"
|
||||
|
||||
steps:
|
||||
- name: fetch-tags
|
||||
@@ -611,23 +598,6 @@ steps:
|
||||
image: docker:git
|
||||
commands:
|
||||
- git fetch --tags --force
|
||||
when:
|
||||
event:
|
||||
exclude:
|
||||
- pull_request
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:linux-amd64
|
||||
settings:
|
||||
dry_run: true
|
||||
repo: gitea/gitea
|
||||
tags: linux-amd64
|
||||
build_args:
|
||||
- GOPROXY=off
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
@@ -647,11 +617,9 @@ steps:
|
||||
exclude:
|
||||
- pull_request
|
||||
|
||||
|
||||
|
||||
---
|
||||
kind: pipeline
|
||||
name: docker-linux-arm64
|
||||
name: docker-linux-arm64-dry-run
|
||||
|
||||
platform:
|
||||
os: linux
|
||||
@@ -662,25 +630,13 @@ workspace:
|
||||
path: src/code.gitea.io/gitea
|
||||
|
||||
depends_on:
|
||||
- testing
|
||||
- compliance
|
||||
|
||||
trigger:
|
||||
ref:
|
||||
- refs/heads/master
|
||||
- "refs/tags/**"
|
||||
- "refs/pull/**"
|
||||
|
||||
steps:
|
||||
- name: fetch-tags
|
||||
pull: default
|
||||
image: docker:git
|
||||
commands:
|
||||
- git fetch --tags --force
|
||||
when:
|
||||
event:
|
||||
exclude:
|
||||
- pull_request
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:linux-arm64
|
||||
@@ -694,6 +650,33 @@ steps:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
---
|
||||
kind: pipeline
|
||||
name: docker-linux-arm64-release
|
||||
|
||||
platform:
|
||||
os: linux
|
||||
arch: arm64
|
||||
|
||||
workspace:
|
||||
base: /go
|
||||
path: src/code.gitea.io/gitea
|
||||
|
||||
depends_on:
|
||||
- testing-amd64
|
||||
- testing-arm64
|
||||
|
||||
trigger:
|
||||
ref:
|
||||
- refs/heads/master
|
||||
- "refs/tags/**"
|
||||
steps:
|
||||
- name: fetch-tags
|
||||
pull: default
|
||||
image: docker:git
|
||||
commands:
|
||||
- git fetch --tags --force
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:linux-arm64
|
||||
@@ -739,42 +722,49 @@ trigger:
|
||||
- "refs/tags/**"
|
||||
|
||||
depends_on:
|
||||
- docker-linux-amd64
|
||||
- docker-linux-arm64
|
||||
- docker-linux-amd64-release
|
||||
- docker-linux-arm64-release
|
||||
|
||||
---
|
||||
kind: pipeline
|
||||
name: notify
|
||||
name: notifications
|
||||
|
||||
platform:
|
||||
os: linux
|
||||
arch: amd64
|
||||
arch: arm64
|
||||
|
||||
workspace:
|
||||
base: /go
|
||||
path: src/code.gitea.io/gitea
|
||||
clone:
|
||||
disable: true
|
||||
|
||||
when:
|
||||
trigger:
|
||||
branch:
|
||||
- master
|
||||
- "release/*"
|
||||
event:
|
||||
- push
|
||||
- tag
|
||||
status:
|
||||
- success
|
||||
- failure
|
||||
|
||||
depends_on:
|
||||
- testing
|
||||
- testing-amd64
|
||||
- testing-arm64
|
||||
- translations
|
||||
- release-version
|
||||
- release-master
|
||||
- docker-linux-amd64
|
||||
- docker-linux-arm64
|
||||
- docker-linux-amd64-release
|
||||
- docker-linux-arm64-release
|
||||
- docker-manifest
|
||||
- docs
|
||||
|
||||
steps:
|
||||
- name: discord
|
||||
pull: always
|
||||
image: appleboy/drone-discord:1.0.0
|
||||
environment:
|
||||
DISCORD_WEBHOOK_ID:
|
||||
image: appleboy/drone-discord:1.2.4
|
||||
settings:
|
||||
message: "{{#success build.status}} ✅ Build #{{build.number}} of `{{repo.name}}` succeeded.\n\n📝 Commit by {{commit.author}} on `{{commit.branch}}`:\n``` {{commit.message}} ```\n\n🌐 {{ build.link }} {{else}} ❌ Build #{{build.number}} of `{{repo.name}}` failed.\n\n📝 Commit by {{commit.author}} on `{{commit.branch}}`:\n``` {{commit.message}} ```\n\n🌐 {{ build.link }} {{/success}}\n"
|
||||
webhook_id:
|
||||
from_secret: discord_webhook_id
|
||||
DISCORD_WEBHOOK_TOKEN:
|
||||
webhook_token:
|
||||
from_secret: discord_webhook_token
|
||||
|
@@ -5,6 +5,7 @@ root = true
|
||||
charset = utf-8
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
end_of_line = lf
|
||||
|
||||
[*.go]
|
||||
indent_style = tab
|
||||
@@ -24,7 +25,7 @@ indent_size = 2
|
||||
|
||||
[*.js]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
indent_size = 2
|
||||
|
||||
[Makefile]
|
||||
indent_style = tab
|
||||
|
1
.eslintignore
Normal file
1
.eslintignore
Normal file
@@ -0,0 +1 @@
|
||||
/web_src/js/semanticDropdown.js
|
42
.eslintrc
42
.eslintrc
@@ -1,27 +1,53 @@
|
||||
root: true
|
||||
|
||||
extends:
|
||||
- eslint-config-airbnb-base
|
||||
- eslint:recommended
|
||||
|
||||
parserOptions:
|
||||
ecmaVersion: 2015
|
||||
ecmaVersion: 2020
|
||||
|
||||
env:
|
||||
browser: true
|
||||
jquery: true
|
||||
es6: true
|
||||
jquery: true
|
||||
node: true
|
||||
|
||||
globals:
|
||||
__webpack_public_path__: true
|
||||
Clipboard: false
|
||||
CodeMirror: false
|
||||
emojify: false
|
||||
SimpleMDE: false
|
||||
Vue: false
|
||||
Dropzone: false
|
||||
u2fApi: false
|
||||
emojify: false
|
||||
hljs: false
|
||||
SimpleMDE: false
|
||||
u2fApi: false
|
||||
Vue: false
|
||||
|
||||
rules:
|
||||
no-unused-vars: [error, {args: all, argsIgnorePattern: ^_, varsIgnorePattern: ^_, ignoreRestSiblings: true}]
|
||||
prefer-const: [2, {destructuring: all}]
|
||||
arrow-body-style: [0]
|
||||
camelcase: [0]
|
||||
comma-dangle: [2, only-multiline]
|
||||
consistent-return: [0]
|
||||
default-case: [0]
|
||||
func-names: [0]
|
||||
import/extensions: [0]
|
||||
max-len: [0]
|
||||
newline-per-chained-call: [0]
|
||||
no-alert: [0]
|
||||
no-continue: [0]
|
||||
no-mixed-operators: [0]
|
||||
no-multi-assign: [0]
|
||||
no-new: [0]
|
||||
no-param-reassign: [0]
|
||||
no-plusplus: [0]
|
||||
no-restricted-syntax: [0]
|
||||
no-shadow: [0]
|
||||
no-unused-vars: [2, {args: all, argsIgnorePattern: ^_, varsIgnorePattern: ^_, ignoreRestSiblings: true}]
|
||||
no-use-before-define: [0]
|
||||
no-var: [2]
|
||||
one-var-declaration-per-line: [0]
|
||||
one-var: [0]
|
||||
prefer-const: [2, {destructuring: all}]
|
||||
prefer-destructuring: [0]
|
||||
radix: [2, as-needed]
|
||||
|
3
.gitattributes
vendored
3
.gitattributes
vendored
@@ -1,6 +1,7 @@
|
||||
* text=auto eol=lf
|
||||
conf/* linguist-vendored
|
||||
docker/* linguist-vendored
|
||||
options/* linguist-vendored
|
||||
public/* linguist-vendored
|
||||
scripts/* linguist-vendored
|
||||
templates/* linguist-vendored
|
||||
templates/* linguist-vendored
|
||||
|
8
.gitignore
vendored
8
.gitignore
vendored
@@ -12,6 +12,7 @@ _test
|
||||
|
||||
# MS VSCode
|
||||
.vscode
|
||||
__debug_bin
|
||||
|
||||
# Architecture specific extensions/prefixes
|
||||
*.[568vq]
|
||||
@@ -65,9 +66,10 @@ coverage.all
|
||||
/integrations/pgsql.ini
|
||||
/integrations/mssql.ini
|
||||
/node_modules
|
||||
/modules/indexer/issues/indexers
|
||||
routers/repo/authorized_keys
|
||||
/yarn.lock
|
||||
/public/js
|
||||
/public/css
|
||||
/VERSION
|
||||
|
||||
# Snapcraft
|
||||
snap/.snapcraft/
|
||||
@@ -77,4 +79,4 @@ prime/
|
||||
*.snap
|
||||
*.snap-build
|
||||
*_source.tar.bz2
|
||||
.DS_Store
|
||||
.DS_Store
|
||||
|
@@ -73,6 +73,9 @@ issues:
|
||||
- path: routers/routes/routes.go
|
||||
linters:
|
||||
- dupl
|
||||
- path: routers/api/v1/repo/issue_subscription.go
|
||||
linters:
|
||||
- dupl
|
||||
- path: routers/repo/view.go
|
||||
linters:
|
||||
- dupl
|
||||
|
5
.ignore
Normal file
5
.ignore
Normal file
@@ -0,0 +1,5 @@
|
||||
/vendor
|
||||
/public/vendor
|
||||
/modules/options/bindata.go
|
||||
/modules/public/bindata.go
|
||||
/modules/templates/bindata.go
|
652
CHANGELOG.md
652
CHANGELOG.md
@@ -4,6 +4,598 @@ This changelog goes through all the changes that have been made in each release
|
||||
without substantial changes to our git log; to see the highlights of what has
|
||||
been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
|
||||
## [1.11.3](https://github.com/go-gitea/gitea/releases/tag/v1.11.3) - 2020-03-10
|
||||
|
||||
* BUGFIXES
|
||||
* Prevent panic in stopwatch (#10670) (#10673)
|
||||
* Fix bug on pull view when required status check no ci result (#10648) (#10651)
|
||||
* Build explicitly with Go 1.13 (#10684)
|
||||
|
||||
## [1.11.2](https://github.com/go-gitea/gitea/releases/tag/v1.11.2) - 2020-03-06
|
||||
|
||||
* BREAKING
|
||||
* Various fixes in login sources (#10428) (#10429)
|
||||
* SECURITY
|
||||
* Ensure only own addresses are updated (#10397) (#10399)
|
||||
* Logout POST action (#10582) (#10585)
|
||||
* Org action fixes and form cleanup (#10512) (#10514)
|
||||
* Change action GETs to POST (#10462) (#10464)
|
||||
* Fix admin notices (#10480) (#10483)
|
||||
* Change admin dashboard to POST (#10465) (#10466)
|
||||
* Update markbates/goth (#10444) (#10445)
|
||||
* Update crypto vendors (#10385) (#10398)
|
||||
* BUGFIXES
|
||||
* Allow users with write permissions to modify issue descriptions and comments. (#10623) (#10626)
|
||||
* Handle deleted base branch in PR (#10618) (#10619)
|
||||
* Delete dependencies when deleting a repository (#10608) (#10616)
|
||||
* Ensure executable bit is kept on the web editor (#10607) (#10614)
|
||||
* Update mergebase in pr checker (#10586) (#10605)
|
||||
* Fix release attachments being deleted while upgrading (#10572) (#10573)
|
||||
* Fix redirection path if Slack webhook channel is invalid (#10566)
|
||||
* Fix head.tmpl og:image picture location (#10531) (#10556)
|
||||
* Fix 404 after activating secondary email (#10547) (#10553)
|
||||
* Show Signer in commit lists and add basic trust (#10425 & #10511) (#10524)
|
||||
* Fix potential bugs (#10513) (#10518)
|
||||
* Use \[:space:\] instead of \\s (#10508) (#10509)
|
||||
* Avoid mailing users that have explicitly unwatched an issue (#10475) (#10500)
|
||||
* Handle push rejection message in Merge & Web Editor (#10373) (#10497)
|
||||
* Fix SQLite concurrency problems by using BEGIN IMMEDIATE (#10368) (#10493)
|
||||
* Fix double PR notification from API (#10482) (#10486)
|
||||
* Show the username as a fallback on feeds if full name is blank (#10461)
|
||||
* Trigger webhooks on issue label-change via API too (#10421) (#10439)
|
||||
* Fix git reference type in webhooks (#10427) (#10432)
|
||||
* Prevent panic on merge to PR (#10403) (#10408)
|
||||
* Fix wrong num closed issues on repository when close issue via commit… (#10364) (#10380)
|
||||
* Reading pull attachments should depend on read UnitTypePullRequests (#10346) (#10354)
|
||||
* Set max-width on review-box comment box (#10348) (#10353)
|
||||
* Prevent nil pointer in GetPullRequestCommitStatusState (#10342) (#10344)
|
||||
* Fix protected branch status check settings (#10341) (#10343)
|
||||
* Truncate long commit message header (#10301) (#10319)
|
||||
* Set the initial commit status to Success otherwise it will always be Pending (#10317) (#10318)
|
||||
* Don't manually replace whitespace during render (#10291) (#10315)
|
||||
* ENHANCEMENT
|
||||
* Admin page for managing user e-mail activation (#10557) (#10579)
|
||||
|
||||
## [1.11.1](https://github.com/go-gitea/gitea/releases/tag/v1.11.1) - 2020-02-15
|
||||
|
||||
* BUGFIXES
|
||||
* Repo name added to automatically generated commit message when merging (#9997) (#10285)
|
||||
* Fix Workerpool deadlock (#10283) (#10284)
|
||||
* Divide GetIssueStats query in smaller chunks (#10176) (#10282)
|
||||
* Fix reply on code review (#10257)
|
||||
* Stop hanging issue indexer initialisation from preventing shutdown (#10243) (#10249)
|
||||
* Fix filter label emoji width (#10241) (#10244)
|
||||
* Fix issue sidebar menus having an infinite height (#10239) (#10240)
|
||||
* Fix commit between two commits calculation if there is only last commit (#10225) (#10226)
|
||||
* Only check for conflicts/merging if the PR has not been merged in the interim (#10132) (#10206)
|
||||
* Blacklist manifest.json & milestones user (#10292) (#10293)
|
||||
|
||||
## [1.11.0](https://github.com/go-gitea/gitea/releases/tag/v1.11.0) - 2020-02-10
|
||||
* BREAKING
|
||||
* Fix followers and following tabs in profile (#10202) (#10203)
|
||||
* Make CertFile and KeyFile relative to CustomPath (#9868) (#9874)
|
||||
* Remove unused endpoints (#9538)
|
||||
* Prefix all user-generated IDs in markup (#9477)
|
||||
* Enforce Gitea environment for pushes (#8982)
|
||||
* Hide some user information via API if user have not enough permissions (#8655)
|
||||
* Move startpage/homepage translation to crowdin (#8596)
|
||||
* SECURITY
|
||||
* Never allow an empty password to validate (#9682) (#9683)
|
||||
* Prevent redirect to Host (#9678) (#9679)
|
||||
* Swagger hide search field (#9554)
|
||||
* Add "search" to reserved usernames (#9063)
|
||||
* Switch to fomantic-ui (#9374)
|
||||
* Only serve attachments when linked to issue/release and if accessible by user (#9340)
|
||||
* FEATURES
|
||||
* Webhooks should only show sender if it makes sense (#9601)
|
||||
* Provide Default messages for merges (#9393)
|
||||
* Add description to labels on create issue (#9392)
|
||||
* Graceful Queues: Issue Indexing and Tasks (#9363)
|
||||
* Default NO_REPLY_ADDRESS to DOMAIN (#9325)
|
||||
* Allow FCGI over unix sockets (#9298)
|
||||
* Graceful: Xorm, RepoIndexer, Cron and Others (#9282)
|
||||
* Add API for Reactions (#9220)
|
||||
* Graceful: Cancel Process on monitor pages & HammerTime (#9213)
|
||||
* Graceful: Allow graceful restart for unix sockets (#9113)
|
||||
* Graceful: Allow graceful restart for fcgi (#9112)
|
||||
* Sign protected branches (#8993)
|
||||
* Add Graceful shutdown for Windows and hooks for shutdown of goroutines (#8964)
|
||||
* Add Gitea icon to Emojis (#8950)
|
||||
* Expand/Collapse Files and Blob Excerpt while Reviewing/Comparing code (#8924)
|
||||
* Allow Custom Reactions (#8886)
|
||||
* Close/reopen issues by keywords in titles and comments (#8866)
|
||||
* Allow incompletely specified Time Formats (#8816)
|
||||
* Prevent upload (overwrite) of lfs locked file (#8769)
|
||||
* Template Repositories (#8768)
|
||||
* Add /milestones endpoint (#8733)
|
||||
* Make repository management section handle lfs locks (#8726)
|
||||
* Respect LFS File Lock on UI (#8719)
|
||||
* Add team option to grant rights for all organization repositories (#8688)
|
||||
* Enabling and disabling the commit button to prevent empty commits (web editor) (#8590)
|
||||
* Add setting to disable BASIC authentication (#8586)
|
||||
* Expose db.SetMaxOpenConns and allow non MySQL dbs to set conn pool params (#8528)
|
||||
* Allow Protected Branches to Whitelist Deploy Keys (#8483)
|
||||
* Push to create repo (#8419)
|
||||
* Sign merges, CRUD, Wiki and Repository initialisation with gpg key (#7631)
|
||||
* Add basic repository lfs management (#7199)
|
||||
* BUGFIXES
|
||||
* Fix code-expansion arc-green theme bug (#10180) (#10185)
|
||||
* Prevent double wait-group decrement (#10170) (#10175)
|
||||
* Allow emoji on review head comments (#10159) (#10174)
|
||||
* Fix issue/pull link (#10158) (#10173)
|
||||
* Fix push-create SSH bugs (#10145) (#10151)
|
||||
* Prevent DeleteUser API abuse (#10125) (#10128)
|
||||
* Fix issues/pulls dashboard paging error (#10114) (#10115)
|
||||
* Add button to revert SimpleMDE to plain textarea (#10099) (#10102)
|
||||
* Fix branch page pull request title and link error (#10092) (#10097)
|
||||
* Fix PR API: Only try to get HeadBranch if HeadRepo exist (#10029) (#10088)
|
||||
* Update topics repo count when deleting repository (#10051) (#10081)
|
||||
* Show pull icon on pull requests (#10061) (#10062)
|
||||
* Fix milestone API state parameter unhandled (#10049) (#10052)
|
||||
* Move to using a temporary repo for pushing new PRs (#10009) (#10042)
|
||||
* Fix wiki raw view on sub path (#10002) (#10040)
|
||||
* Ensure that feeds are appropriately restricted (#10018) (#10019)
|
||||
* Sanitize credentials in mirror form (#9975) (#9991)
|
||||
* Close related pull requests when deleting head repository or head branch (#9927) (#9974)
|
||||
* Switch to use -f instead of -F for sendmail (#9961) (#9970)
|
||||
* Fix file rename/copy not supported by indexer (#9965) (#9967)
|
||||
* Fix repo indexer not updating upon push (#9957) (#9963)
|
||||
* Don't convert ellipsis in markdown (#9905) (#9937)
|
||||
* Fixed repo link in generated comment for cross repository dependency (#9863) (#9935)
|
||||
* Check if diff actually contains sections when rendering (#9926) (#9933)
|
||||
* Fix wrong hint when status checking is running on pull request view (#9886) (#9928)
|
||||
* Fix RocketChat (#9908) (#9921)
|
||||
* Do not try to recreate ldap user if they are already created (#9900) (#9919)
|
||||
* Create terminated channel in queue_redis (#9910) (#9911)
|
||||
* Prevent empty LDAP search result from deactivating all users (#9879) (#9896)
|
||||
* Fix wrong permissions check when issues/prs shared operations (#9885) (#9889)
|
||||
* Check user != nil before checking values (#9881) (#9883)
|
||||
* Allow hyphen in language name (#9873) (#9880)
|
||||
* Ensure that 2fa is checked on reset-password (#9857) (#9876)
|
||||
* Fix issues/pulls dependencies problems (#9842) (#9864)
|
||||
* Fix markdown anchor links (#9673) (#9840)
|
||||
* Allow assignee on Pull Creation when Issue Unit is deactivated (#9836) (#9837)
|
||||
* Fix download file wrong content-type (#9825) (#9834)
|
||||
* Fix wrong poster identity on a migrated pull request when submit review (#9827) (#9830)
|
||||
* Fix database dump when log directory is missing (#9818) (#9819)
|
||||
* Fix compare (#9808) (#9814)
|
||||
* Fix push-to-create (#9772) (#9797)
|
||||
* Fix missing msteam webhook on organization (#9781) (#9794)
|
||||
* Fix missing unlock in uniquequeue (#9790) (#9791)
|
||||
* Fix add team on collaborator page when same name as organization (#9778)
|
||||
* DeleteRepoFile incorrectly handles Delete to new branch (#9769) (#9775)
|
||||
* Fix milestones page (#9771)
|
||||
* Fix SimpleMDE quote reply (#9757) (#9768)
|
||||
* Fix missing updated time on migrated issues and comments (#9744) (#9764)
|
||||
* Move Errored PRs out of StatusChecking (#9675) (#9726)
|
||||
* Make hook status printing configurable with delay (#9641) (#9725)
|
||||
* Fix /repos/issues/search (#9698) (#9724)
|
||||
* Silence fomantic error regarding tabs (#9713) (#9718)
|
||||
* Remove unused lock (#9709) (#9710)
|
||||
* Remove q.lock.Unlock() in setInternal to prevent panic (#9705) (#9706)
|
||||
* Load milestone in API PR list (#9671) (#9700)
|
||||
* Don't attempt to close issue if already closed (#9696) (#9699)
|
||||
* Remove google font call (#9668) (#9681)
|
||||
* Eliminate horizontal scroll caused by footer (#9674)
|
||||
* Fix nil reference in repo generation (#9660) (#9666)
|
||||
* Add HTML URL to API Issues (#9654) (#9661)
|
||||
* Add PR review webhook to Telegram (#9653) (#9655)
|
||||
* Use filepath.IsAbs instead of path.IsAbs (#9651) (#9652)
|
||||
* Disable remove button on repository teams when have access to all (#9640)
|
||||
* Clean up old references on branch delete (#9614)
|
||||
* Hide public repos owned by private orgs (#9609)
|
||||
* Fix access issues on milestone and issue overview pages. (#9603)
|
||||
* Fix error logged when repos qs is empty (#9591)
|
||||
* Dont trigger notification twice on issue assignee change (#9582)
|
||||
* Fix mirror pushed commit actions (#9572)
|
||||
* Allow only specific columns to be updated on issue via API (#9189) (#9539)
|
||||
* Fix default avatar for ghost user (#9536)
|
||||
* Fix download of release attachments with same name (#9529)
|
||||
* Resolve deprecated INI conversion (#9525)
|
||||
* Ignore empty avatars during database migration (#9520)
|
||||
* Fix deleted branch isn't removed when push the branch again (#9516)
|
||||
* Fix repository issues pagination bug when there are more than one label filter (#9512)
|
||||
* Fix SetExpr failed (#9506)
|
||||
* Remove obsolete file private/push_update.go (#9503)
|
||||
* When recreating hooks, delete them first so they are recreated with the umask (#9502)
|
||||
* Properly enforce gitea environment for pushes (#9501)
|
||||
* Fix datarace on repo indexer queue (#9490)
|
||||
* Add call to load repo prior to redirect in add/remove dependency code (#9484)
|
||||
* Wrap the code indexer (#9476)
|
||||
* Use Req.URL.RequestURI() to cope with FCGI urls (#9473)
|
||||
* Set default ssh.minimum_key_sizes (#9466)
|
||||
* Fixed issue with paging in /repos/{owner}/{repo}/git/trees/{sha} api (#9459)
|
||||
* Fix wrong notification on merge (#9450)
|
||||
* Issue with Migration rule v111 (#9449)
|
||||
* Trigger webhook when deleting a branch after merging a PR (#9424)
|
||||
* Add migration to sanitize repository original_url (#9423)
|
||||
* Use OriginalURL instead of CloneAddr in migration logging (#9418)
|
||||
* Push update after branch is restored (#9416)
|
||||
* Fix wrong migration (#9381)
|
||||
* Fix show repositories filter (#9234) (#9379)
|
||||
* Fix Slack webhook payload title generation to work with Mattermost (#9378)
|
||||
* Fix double webhook for new PR (#9375)
|
||||
* AuthorizedKeysCommand should not query db directly (#9371)
|
||||
* Fix missed change to GetManager() (#9361)
|
||||
* Fix cache problem on dashboard (#9358)
|
||||
* RepoIndexer: DefaultBranch needs to be prefixed by BranchPrefix (#9356)
|
||||
* Fix protected branch using IssueID (#9348)
|
||||
* Fix nondeterministic behavior (#9341)
|
||||
* Fix PR/issue redirects when having external tracker (#9339)
|
||||
* Remove release attachments which repository has been deleted (#9334)
|
||||
* Fix issue indexer not triggered when migrating a repository (#9332)
|
||||
* Add SyncTags to uploader interface (#9326)
|
||||
* Fix bug that release attachment files not deleted when deleting repository (#9322)
|
||||
* Only sync tags after all migration release batches are completed (#9319)
|
||||
* File Edit: Author/Committer interchanged (#9297)
|
||||
* prebuild CSS/JS before xgo release binaries (#9293)
|
||||
* Log: Ensure FLAGS=none shows no flags (#9287)
|
||||
* Make Diff Detail on Pull Request Changed File UI always on Top (#9280)
|
||||
* Switch CSS minifier to cssnano (#9260)
|
||||
* Fix latest docker image haven't include static files. (#9252)
|
||||
* Don't link wiki revision to commit (#9244)
|
||||
* Change review content column to type text in db (#9229)
|
||||
* Fixed topic regex pattern and added search by topic links after save (#9219)
|
||||
* Add language to user API responce (#9215)
|
||||
* Correct tooltip message blocked by dependencies (#9211)
|
||||
* Add SimpleMDE and Fix Image Paste for Issue/Comment Editor (#9197)
|
||||
* Fix panic when diff (#9187)
|
||||
* Fix #9151 - smtp logger configuration sendTos should be an array (#9154)
|
||||
* Fix max length check and limit in multiple repo forms (#9148)
|
||||
* Always Show Password Field on Link Account Sign-in Page (#9147)
|
||||
* Properly fix displaying virtual session provider in admin panel (#9137)
|
||||
* Fix race condition on indexer (#9136)
|
||||
* Fix team links in HTML rendering (#9127)
|
||||
* Fix race condition in ReplaceSanitizer (#9123)
|
||||
* Fix what information is shown about user in API (#9115)
|
||||
* Fix nil context user for template repositories (#9099)
|
||||
* Hide given credentials for migrated repos. (#9097)
|
||||
* Fix reCAPTCHA API URL (#9083)
|
||||
* Fix password checks on admin create/edit user (#9076)
|
||||
* Update golang.org/x/crypto vendor to use acme v2 (#9056)
|
||||
* Ensure Written is set in GZIP ProxyResponseWriter (#9018)
|
||||
* Fix wrong system notice when repository is empty (#9010)
|
||||
* Fix broken link to branch from issue list (#9003)
|
||||
* Fix bug when pack js (#8992)
|
||||
* New review approvals shouldn't require a message (#8991)
|
||||
* Shadow password correctly for session config (#8984)
|
||||
* Don't send notification on pending reviews (#8943)
|
||||
* Fix Notify Create Ref Error on tag creation (#8936)
|
||||
* Convert EOL to UNIX-style to render MD properly (#8925)
|
||||
* Migrate temp_repo.go to use git.NewCommand (#8918)
|
||||
* Fix issue with user.fullname (#8902)
|
||||
* Add Close() method to gogitRepository (#8901)
|
||||
* Enable punctuations ending mentions (#8889)
|
||||
* Fix password complexity check on registration (#8887)
|
||||
* Fix require external registration password (#8885)
|
||||
* Fix edit content button on migrated issue content (#8877)
|
||||
* Fix permission checks for close/reopen from commit (#8875)
|
||||
* Fix API Bug (fail on empty assignees) (#8873)
|
||||
* Stop using git count-objects and use raw directory size for repository (#8848)
|
||||
* Fix count for commit graph last page (#8843)
|
||||
* Fix to close opened io resources as soon as not needed (#8839)
|
||||
* Improve notification (#8835)
|
||||
* Fix new user form for non-local users (#8826)
|
||||
* Fix: remove duplicated signed commit icons (#8820)
|
||||
* Fix (open/closed) issue count when label excluded (#8815)
|
||||
* Fix SSH2 conditional in key parsing code (#8806)
|
||||
* Fix 500 when edit hook (#8782)
|
||||
* On windows set core.longpaths true (#8776)
|
||||
* Fix commit expand button to not go to commit link (#8745)
|
||||
* Avoid re-issuing redundant cross-references. (#8734)
|
||||
* Fix milestone close timestamp function (#8728)
|
||||
* Move webhook codes from service to webhook notification (#8712)
|
||||
* Show zero lines on the line counter if the file empty (#8700)
|
||||
* Fix deadline on update issue or PR via API (#8696)
|
||||
* make call createMilestoneComment on newIssue func (#8678)
|
||||
* Send tag create and push webhook when release created on UI (#8671)
|
||||
* Prevent chrome download page as html with alt + click (#8669)
|
||||
* Fix 500 when getting user as unauthenticated user (#8653)
|
||||
* Graceful fixes (#8645)
|
||||
* Add SubURL to redirect path (#8632) (#8634)
|
||||
* Fix extra columns from `label` table (#8633)
|
||||
* Add SubURL to redirect path for transferred/renamed repos (#8632)
|
||||
* Fix bug when migrate from API (#8631)
|
||||
* Allow to merge if file path contains " or \ (#8629)
|
||||
* Prevent removal of non-empty emoji panel following selection of duplicate (#8609)
|
||||
* Ensure default gpg settings not nil and found commits have reference to repo (#8604)
|
||||
* Set webhook Content-Type for application/x-www-form-urlencoded (#8599)
|
||||
* Fix #8582 by handling empty repos (#8587)
|
||||
* Fix of the diff statistics view on pull request's (#8581)
|
||||
* Fix bug on pull requests when transfer head repository (#8564)
|
||||
* Fix template error on account page (#8562)
|
||||
* Allow externalID to be UUID (#8551)
|
||||
* Fix ignored error on editorconfig api (#8550)
|
||||
* Fix user avatar name (#8547)
|
||||
* Ensure that GitRepo is set on Empty repositories (#8539)
|
||||
* Add missed close in ServeBlobLFS (#8527)
|
||||
* Fix migrate mirror 500 bug (#8526)
|
||||
* Fix password complexity regex for special characters (on master) (#8525)
|
||||
* ENHANCEMENTS
|
||||
* Explicitly refer to PR in squash-merge commit message in case of external tracker (#9844) (#9855)
|
||||
* Add a /user/login landing page option (#9622)
|
||||
* Some more e-mail notification fixes (#9596)
|
||||
* Add branch protection option to block merge on requested changes. (#9592)
|
||||
* Add footer extra links template (#9576)
|
||||
* Fix for a wrong URL in activity page of repository. (#9571)
|
||||
* Update default issue template (#9568)
|
||||
* Change markdown rendering from blackfriday to goldmark (#9533)
|
||||
* Extend file create api with dates (#9464)
|
||||
* Add ActionCommentPull action (#9456)
|
||||
* Response for context on retry database connection (#9444)
|
||||
* Refactor webhooks to reduce code duplication (#9422)
|
||||
* update couchbase deps for new license (#9419)
|
||||
* Add .ignore file for search tools (#9417)
|
||||
* Remove unsued struct (#9405)
|
||||
* Hide not allowed Reactions (#9387)
|
||||
* Remove text from action-only webhooks (#9377)
|
||||
* Move PushToBaseRepo from models to services/pull (#9352)
|
||||
* Site admin could view org's members (#9346)
|
||||
* Sleep longer if request speed is over github limitation (#9335)
|
||||
* Refactor comment (#9330)
|
||||
* Refactor code indexer (#9313)
|
||||
* Remove SavePatch and generate patches on the fly (#9302)
|
||||
* Move some pull request functions from models to services (#9266)
|
||||
* Update JS dependencies (#9255)
|
||||
* Show label list on label set (#9251)
|
||||
* Redirect issue if repo has configured external tracker. (#9247)
|
||||
* Allow kbd tags (#9245)
|
||||
* Remove unused comment actions (#9222)
|
||||
* Fixed errors logging in dump.go (#9218)
|
||||
* Expose release counter to repo API response (#9214)
|
||||
* Make consistent links to repository in the Slack/Mattermost notificiations (#9205)
|
||||
* Expose pull request counter to repo API response (#9202)
|
||||
* Extend TrackedTimes API (#9200)
|
||||
* Extend StopWatch API (#9196)
|
||||
* Move code indexer related code to a new package (#9191)
|
||||
* Docker: ask s6 to stop all service when gitea stop (#9171)
|
||||
* Variable expansion in repository templates (#9163)
|
||||
* Add avatar and issue labels to template repositories (#9149)
|
||||
* Show single review comments in the PR conversation tab (#9143)
|
||||
* Extract createComment (#9125)
|
||||
* Move PushUpdateOptions from models to repofiles (#9124)
|
||||
* Alternate syntax for cross references (#9116)
|
||||
* Add USE_SERVICE_WORKER setting (#9110)
|
||||
* Only show part of members on orgnization dashboard and add paging for orgnization members page (#9092)
|
||||
* Explore page: Add topic param to pagination (#9077) (#9078)
|
||||
* Markdown: Sanitizier Configuration (#9075)
|
||||
* Add password requirement info on error (#9074)
|
||||
* Allow authors to use act keywords in PR content (#9059)
|
||||
* Move modules/gzip to gitea.com/macaron/gzip (#9058)
|
||||
* Branch protection: Possibility to not use whitelist but allow anyone with write access (#9055)
|
||||
* Context menus for comments, add quote reply (#9043)
|
||||
* Update branch API endpoint to show effective branch protection. (#9031)
|
||||
* Move git graph from models to modules/graph (#9027)
|
||||
* Move merge actions to notification (#9024)
|
||||
* Move mirror sync actions to notification (#9022)
|
||||
* Add retry for migration http/https requests (#9019)
|
||||
* Rewrite delivery of issue and comment mails (#9009)
|
||||
* Add review comments to mail notifications (#8996)
|
||||
* Refactor pull request review (#8954)
|
||||
* Githook highlighter (#8932)
|
||||
* Add git hooks and webhooks to template repositories; move to services (#8926)
|
||||
* Only view branch or tag if it match refType requested. (#8899)
|
||||
* Drop Admin attribute based on LDAP when login (continue #1743) (#8849)
|
||||
* Add additional periods to activity page (#8829)
|
||||
* Update go-org to optimize code (#8824)
|
||||
* Move some actions to notification/action (#8779)
|
||||
* Webhook support custom proxy (#8760)
|
||||
* Fix API deadline removal (#8759)
|
||||
* Mark review comment as invalidated when file is deleted (#8751)
|
||||
* Move pull list code to a separate file (#8748)
|
||||
* Move webhook to a standalone package under modules (#8747)
|
||||
* Multi repo select on issue page (#8741)
|
||||
* apply exclude label on milestone issue list (#8739)
|
||||
* Move issue notifications and assignee man (#8713)
|
||||
* Move issue change content from models to service (#8711)
|
||||
* Move issue change status from models to service (#8691)
|
||||
* Move more issue assignee code from models to issue service (#8690)
|
||||
* Create PR on Current Repository by Default (#8670)
|
||||
* Improve Open Graph Protocol (#8637)
|
||||
* Batch hook pre- and post-receive calls (#8602)
|
||||
* Improve webhooks (#8583)
|
||||
* Move transfer repository and rename repository on a service package and start action notification (#8573)
|
||||
* Implement/Fix PR review webhooks (#8570)
|
||||
* Rewrite markdown rendering to blackfriday v2 and rewrite orgmode rendering to go-org (#8560)
|
||||
* Move some repositories' operations to a standalone service package (#8557)
|
||||
* Allow more than 255 characters for tokens in external_login_user table (#8554)
|
||||
* Move issue label operations to issue service package (#8553)
|
||||
* Adjust error reporting from merge failures and use LC_ALL=C for git (#8548)
|
||||
* Mail assignee when issue/pull request is assigned (#8546)
|
||||
* Allow committing / adding empty files using the web ui (#8420) (#8532)
|
||||
* Move sync mirror actions to mirror service package (#8518)
|
||||
* Remove arrows on numeric inputs (#8516)
|
||||
* Support inline rendering of CUSTOM_URL_SCHEMES (#8496)
|
||||
* Recalculate repository access only for specific user (#8481)
|
||||
* Add download button for rull request diff- and patch-file (#8470)
|
||||
* Add single sign-on support via SSPI on Windows (#8463)
|
||||
* Move change issue title from models to issue service package (#8456)
|
||||
* Add included tag on branch view (#8449)
|
||||
* Make static resouces web browser cache time customized on app.ini (#8442)
|
||||
* Enable Uploading/Removing Attachments When Editing an Issue/Comment (#8426)
|
||||
* Add pagination to commit graph page (#8360)
|
||||
* Use templates for issue e-mail subject and body (#8329)
|
||||
* Move clearlabels from models to issue service (#8326)
|
||||
* Move AddTestPullRequestTask to pull service package from models (#8324)
|
||||
* Team permission to create repository in organization (#8312)
|
||||
* Allows external rendering of other filetypes (#8300)
|
||||
* Add 'Alt + click' feature to exclude labels (#8199)
|
||||
* Configurable close and reopen keywords for PRs (#8120)
|
||||
* Configurable URL for static resources (#7911)
|
||||
* Unifies commit list in repository commit table and wiki revision page (#7907)
|
||||
* Allow cross-repository dependencies on issues (#7901)
|
||||
* Auto-subscribe user to repository when they commit/tag to it (#7657)
|
||||
* Restore Graceful Restarting & Socket Activation (#7274)
|
||||
* wiki - add 'write' 'preview' buttons to wiki edit like in issues (#7241)
|
||||
* Change target branch for pull request (#6488)
|
||||
* Display PR commits and diffs using base repo rather than forked (#3648)
|
||||
* TESTING
|
||||
* Add debug option to serv to help debug problems (#9492)
|
||||
* Fix the intermittent TestGPGGit failures (#9360)
|
||||
* Testing: Update postgres sequences (#9304)
|
||||
* Missed defer prepareTestEnv (#9285)
|
||||
* Fix "data race" in testlogger (#9159)
|
||||
* Yet another attempt to fix the intermittent failure of gpg git test (#9146)
|
||||
* integrations: Fix Dropped Test Errors (#9040)
|
||||
* services/mirror: fix dropped test errors (#9007)
|
||||
* Fix intermittent GPG Git test failure (#8968)
|
||||
* Update Github Migration Tests (#8893) (#8938)
|
||||
* Update heatmap fixtures to restore tests (#8615)
|
||||
* TRANSLATION
|
||||
* Fix Korean locales (#9761) (#9780)
|
||||
* Fix placeholders in the error message (#9060)
|
||||
* Fix spelling of admin.users.max_repo_creation (#8934)
|
||||
* Improve german translation of homepage (#8549)
|
||||
* BUILD
|
||||
* Fix webpack polyfills (#9735) (#9738)
|
||||
* Update gitea.com/macaron to 1.4.0 (#9608)
|
||||
* Upgrade lato fonts to v16. (#9498)
|
||||
* Update alpine to 3.11 (#9440)
|
||||
* Upgrade blevesearch (#9177)
|
||||
* Remove built js/css files from git (#9114)
|
||||
* Move semantic.dropdown.custom.js to webpack (#9064)
|
||||
* Check compiled files during build (#9042)
|
||||
* Enable lazy-loading of gitgraph.js (#9036)
|
||||
* Pack web_src/js/draw.js to public/js/index.js (#8975)
|
||||
* Modernize js and use babel (#8973)
|
||||
* Move index.js to web_src and use webpack to pack them (#8598)
|
||||
* Restrict modules/graceful to non-windows build and shim IsChild (#8537)
|
||||
* Upgrade gopkg.in/editorconfig/editorconfig-core-go.v1 (#8501)
|
||||
* DOCS
|
||||
* Swagger info corrections (#9441) (#9558)
|
||||
* Add ALLOW_ONLY_EXTERNAL_REGISTRATION to config cheat sheet (#8986)
|
||||
* Rephrase comment about RuntimeDirectory option in systemd config (#8912)
|
||||
* Explicitly indicate the socket unit to use the service unit "gitea.service" (#8804)
|
||||
* Adjust the must-change-password help (#8755)
|
||||
* Add notice to docs for migrating from more recent versions of Gogs (#8724)
|
||||
* Add explicit info about customization of homepage (#8694)
|
||||
* Change external asciidoctor tool to embedded mode (#8677)
|
||||
* Add Docker fail2ban configuration (#8642)
|
||||
* Correct some outdated statements in the contributing guidelines (#8612)
|
||||
* Basic Design guidelines (describing different parts of the code) (#8601)
|
||||
* Display Gitea logo in Readme (#8592)
|
||||
* Fix building from source docs to ref AppWorkPath (#8567)
|
||||
* Update the provided gitea.service to mention socket activation (#8531)
|
||||
* Doc added how to setup email (#8520)
|
||||
* MISC
|
||||
* Backport Locales [2020-01-14] (#9773)
|
||||
* Add translatable Powered by Gitea text in footer (#9600)
|
||||
* Add contrib/environment-to-ini (#9519)
|
||||
* Remove unnecessary loading of settings in update hook (#9496)
|
||||
* Update gitignore list (#9437)
|
||||
* Update license list (#9436)
|
||||
* Fix background reactions in the arc-green theme (#9421)
|
||||
* Update and fix chardet import (#9351)
|
||||
* Ensure LF on checkouts and in editors (#9259)
|
||||
* Fixed topics margin (#9248)
|
||||
* Add comment to exported function WindowsServiceName (make revive) (#9241)
|
||||
* Remove empty lines on issues/pulls page (#9232)
|
||||
* Fix Add Comment Button's "+" Position (#9140)
|
||||
* Add first issue comment hashtag (#9052)
|
||||
* Change some label colors (#9051)
|
||||
* Fix double scroll in branch dropdown (#9048)
|
||||
* Add comment highlight when target from url (#9047)
|
||||
* Update display of reactions to issues and comments (#9038)
|
||||
* Button tooltip formatting under Branches (#9034)
|
||||
* Allow setting default branch via API (#9030)
|
||||
* Update dashboard context for PR reviews (#8995)
|
||||
* Show repository size in repo home page and settings (#8940)
|
||||
* Allow to add and remove all repositories to/from team. (#8867)
|
||||
* Show due date in dashboard issues list (#8860)
|
||||
* Theme arc-green: reverse heatmap colors (#8840)
|
||||
* Project files table style update (#8757)
|
||||
* gitignore debugging file from vscode (#8740)
|
||||
* Add API for Issue set Subscription (#8729)
|
||||
* Make 100% width search bar (#8710)
|
||||
* Update color theme for heatmap (#8709)
|
||||
* Add margin to title_wip_desc (#8705)
|
||||
* Improve visibility of "Pending" indicator (#8685)
|
||||
* Improve accessibility of dropdown menus (#8638)
|
||||
* Make /users/{username}/repos list private repos the current user has access to (#8621)
|
||||
* Prevent .code-view from overriding font on icon fonts (#8614)
|
||||
* Add id references on all issue events to allow internal linking (#8608)
|
||||
* Upgrade xorm to v0.8.0 (#8536)
|
||||
* Upgrade gopkg.in/ini.v1 (#8500)
|
||||
* Update CodeMirror to version 5.49.0 (#8381)
|
||||
* Wiki editor: enable side-by-side button (#7242)
|
||||
|
||||
## [1.10.5](https://github.com/go-gitea/gitea/releases/tag/v1.10.5) - 2020-03-06
|
||||
|
||||
* BUGFIXES
|
||||
* Fix release attachments being deleted while upgrading (#10572) (#10574)
|
||||
|
||||
## [1.10.4](https://github.com/go-gitea/gitea/releases/tag/v1.10.4) - 2020-02-16
|
||||
|
||||
* FEATURE
|
||||
* Prevent empty LDAP search from deactivating all users (#9879) (#9890)
|
||||
* BUGFIXES
|
||||
* Fix reply on code review (#10261) (#10227)
|
||||
* Fix branch page pull request title and link error (#10092) (#10098)
|
||||
* Fix milestone API state parameter unhandled (#10049) (#10053)
|
||||
* Fix wiki raw view on sub path (#10002) (#10041)
|
||||
* Fix RocketChat Webhook (#9908) (#9921) (#9925)
|
||||
* Fix bug about wrong dependencies permissions check and other wrong permissions check (#9884) (Partial backport #9842)
|
||||
* Ensure that 2fa is checked on reset-password (#9857) (#9877)
|
||||
|
||||
## [1.10.3](https://github.com/go-gitea/gitea/releases/tag/v1.10.3) - 2020-01-17
|
||||
* SECURITY
|
||||
* Hide credentials when submitting migration (#9102) (#9704)
|
||||
* Never allow an empty password to validate (#9682) (#9684)
|
||||
* Prevent redirect to Host (#9678) (#9680)
|
||||
* Hide public repos owned by private orgs (#9609) (#9616)
|
||||
* BUGFIXES
|
||||
* Allow assignee on Pull Creation when Issue Unit is deactivated (#9836) (#9838)
|
||||
* Fix download file wrong content-type (#9825) (#9835)
|
||||
* Fix wrong identify poster on a migrated pull request when submit review (#9827) (#9831)
|
||||
* Fix dump non-exist log directory (#9818) (#9820)
|
||||
* Fix compare (#9808) (#9815)
|
||||
* Fix missing msteam webhook on organization (#9781) (#9795)
|
||||
* Fix add team on collaborator page when same name as organization (#9783)
|
||||
* Fix cache problem on dashboard (#9358) (#9703)
|
||||
* Send tag create and push webhook when release created on UI (#8671) (#9702)
|
||||
* Branches not at ref commit ID should not be listed as Merged (#9614) (#9639)
|
||||
|
||||
## [1.10.2](https://github.com/go-gitea/gitea/releases/tag/v1.10.2) - 2020-01-02
|
||||
* BUGFIXES
|
||||
* Allow only specific Columns to be updated on Issue via API (#9539) (#9580)
|
||||
* Add ErrReactionAlreadyExist error (#9550) (#9564)
|
||||
* Fix bug when migrate from API (#8631) (#9563)
|
||||
* Use default avatar for ghost user (#9536) (#9537)
|
||||
* Fix repository issues pagination bug when there are more than one label filter (#9512) (#9528)
|
||||
* Fix deleted branch not removed when push the branch again (#9516) (#9524)
|
||||
* Fix missing repository status when migrating repository via API (#9511)
|
||||
* Trigger webhook when deleting a branch after merging a PR (#9510)
|
||||
* Fix paging on /repos/{owner}/{repo}/git/trees/{sha} API endpoint (#9482)
|
||||
* Fix NewCommitStatus (#9434) (#9435)
|
||||
* Use OriginalURL instead of CloneAddr in migration logging (#9418) (#9420)
|
||||
* Fix Slack webhook payload title generation to work with Mattermost (#9404)
|
||||
* DefaultBranch needs to be prefixed by BranchPrefix (#9356) (#9359)
|
||||
* Fix issue indexer not triggered when migrating a repository (#9333)
|
||||
* Fix bug that release attachment files not deleted when deleting repository (#9322) (#9329)
|
||||
* Fix migration releases (#9319) (#9326) (#9328)
|
||||
* Fix File Edit: Author/Committer interchanged (#9297) (#9300)
|
||||
|
||||
## [1.10.1](https://github.com/go-gitea/gitea/releases/tag/v1.10.1) - 2019-12-05
|
||||
* BUGFIXES
|
||||
* Fix max length check and limit in multiple repo forms (#9148) (#9204)
|
||||
* Properly fix displaying virtual session provider in admin panel (#9137) (#9203)
|
||||
* Upgrade levelqueue to 0.1.0 (#9192) (#9199)
|
||||
* Fix panic when diff (#9187) (#9193)
|
||||
* Smtp logger configuration sendTos should be an array (#9154) (#9157)
|
||||
* Always Show Password Field on Link Account Sign-in Page (#9150)
|
||||
* Create PR on Current Repository by Default (#8670) (#9141)
|
||||
* Fix race on indexer (#9136) (#9139)
|
||||
* Fix reCAPTCHA URL (#9119)
|
||||
* Hide migrated credentials (#9098)
|
||||
* Update golang.org/x/crypto vendor to use acme v2 (#9056) (#9085)
|
||||
* Fix password checks on admin create/edit user (#9076) (#9081)
|
||||
* Fix add search as a reserved username (#9063) (#9065)
|
||||
* Fix permission checks for close/reopen from commit (#8875) (#9033)
|
||||
* Ensure Written is set in GZIP ProxyResponseWriter (#9018) (#9025)
|
||||
* Fix broken link to branch from issue list (#9003) (#9021)
|
||||
* Fix wrong system notice when repository is empty (#9020)
|
||||
* Shadow password correctly for session config (#8984) (#9002)
|
||||
|
||||
## [1.10.0](https://github.com/go-gitea/gitea/releases/tag/v1.10.0) - 2019-11-13
|
||||
* BREAKING
|
||||
* Fix deadline on update issue or PR via API (#8698)
|
||||
@@ -13,10 +605,12 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Add pagination for admin api get orgs and fix only list public orgs bug (#7742)
|
||||
* Implement the ability to change the ssh port to match what is in the gitea config (#7286)
|
||||
* SECURITY
|
||||
* Fix issue with user.fullname (#8903)
|
||||
* Ignore mentions for users with no access (#8395)
|
||||
* Be more strict with git arguments (#7715)
|
||||
* Extract the username and password from the mirror url (#7651)
|
||||
* reserve .well-known username (#7637)
|
||||
* FEATURE
|
||||
* FEATURES
|
||||
* Org/Members: display 2FA members states + optimize sql requests (#7621)
|
||||
* SetDefaultBranch on pushing to empty repository (#7610)
|
||||
* Adds side-by-side diff for images (#6784)
|
||||
@@ -25,7 +619,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Add option to initialize repository with labels (#6061)
|
||||
* Add additional password hash algorithms (#6023)
|
||||
* BUGFIXES
|
||||
* Allow to merge if file path contains " or \ (#8629) (#8771)
|
||||
* Allow to merge if file path contains " or \ (#8629) (#8771)
|
||||
* On windows set core.longpaths true (#8776) (#8786)
|
||||
* Fix 500 when edit hook (#8782) (#8789)
|
||||
* Fix Checkbox at RepoSettings Protected Branch (#8799) (#8801)
|
||||
@@ -37,8 +631,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Fix require external registration password (#8885) (#8890)
|
||||
* Fix password complexity check on registration (#8887) (#8888)
|
||||
* Update Github Migration Tests (#8896) (#8938) (#8945)
|
||||
* Fix issue with user.fullname (#8903)
|
||||
* Enable punctuations ending mentions (#8889) (#8894)
|
||||
* Enable punctuations ending mentions (#8889) (#8894)
|
||||
* Add Close() method to gogitRepository (#8901) (#8956)
|
||||
* Hotfix for review actions and notifications (#8965)
|
||||
* Expose db.SetMaxOpenConns and allow non MySQL dbs to set conn pool params (#8528) (#8618)
|
||||
@@ -176,7 +769,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* fix post parameter - on issue list - unset assignee (#7380)
|
||||
* fix/define autochecked checkboxes on issue list in firefox (#7320)
|
||||
* only return head: null if source branch was deleted (#6705)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Add nofollow to sign in links (#8509)
|
||||
* vendor: update mvdan.cc/xurls/v2 to v2.1.0 (#8495)
|
||||
* Update milestone issues numbers when save milestone and other code improvements (#8411)
|
||||
@@ -288,7 +881,6 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Fix global search result CSS, misc CSS tweaks (#7789)
|
||||
* Tweak label border CSS (#7739)
|
||||
* Fix create menu item widths (#7708)
|
||||
* Extract the username and password from the mirror url (#7651)
|
||||
* [Branch View] Delete duplicate protection symbol (#7624)
|
||||
* [Branch View] Delete Table Header (#7622)
|
||||
* [Branch View] icons to buttons (#7602)
|
||||
@@ -371,7 +963,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Fix adding default Telegram webhook (#7972) (#7992)
|
||||
* Abort synchronization from LDAP source if there is some error (#7965)
|
||||
* Fix deformed emoji in commit message (#8071)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Keep blame view buttons sequence consistent with normal view when viewing a file (#8007) (#8009)
|
||||
|
||||
## [1.9.2](https://github.com/go-gitea/gitea/releases/tag/v1.9.2) - 2019-08-22
|
||||
@@ -383,7 +975,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* SECURITY
|
||||
* Fix No PGP signature on 1.9.1 tag (#7874)
|
||||
* Release built with go 1.12.9 to fix security fixes in golang std lib, ref: https://groups.google.com/forum/#!msg/golang-announce/oeMaeUnkvVE/a49yvTLqAAAJ
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Fix pull creation with empty changes (#7920) (#7926)
|
||||
* BUILD
|
||||
* Drone/docker: prepare multi-arch release + provide arm64 image (#7571) (#7884)
|
||||
@@ -424,7 +1016,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Reserve .well-known username (#7638)
|
||||
* Do not leak secrets via timing side channel (#7364)
|
||||
* Ensure that decryption of cookie actually suceeds (#7363)
|
||||
* FEATURE
|
||||
* FEATURES
|
||||
* Content API for Creating, Updating, Deleting Files (#6314)
|
||||
* Enable tls-alpn-01: Use certmanager provided TLSConfig for LetsEncrypt (#7229)
|
||||
* Add command to convert mysql database from utf8 to utf8mb4 (#7144)
|
||||
@@ -615,7 +1207,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Fix bug manifest.json will not request with cookie so that session will created every request (#6372)
|
||||
* Disable benchmarking during tag events on DroneIO (#6365)
|
||||
* Comments list performance optimization (#5305)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Update Drone docker generation to standard format (#7480) (#7496) (#7504)
|
||||
* Add API Endpoint for Repo Edit (#7006)
|
||||
* Add state param to milestone listing API (#7131)
|
||||
@@ -835,7 +1427,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Releases API paging (#5831)
|
||||
* Allow Macaron to be set to log through to gitea.log (#5667)
|
||||
* Don't close issues via commits on non-default branch (#5622)
|
||||
* FEATURE
|
||||
* FEATURES
|
||||
* Add regenerate secret feature for oauth2 (#6291)
|
||||
* Expose issue stopwatch toggling via API (#5970)
|
||||
* Add other session providers (#5963)
|
||||
@@ -846,7 +1438,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Discord Oauth2 support (#4476)
|
||||
* Allow to set organization visibility (public, internal, private) (#1763)
|
||||
* Added URL mapping for Release attachments like on github.com (#1707)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Add support for client basic auth for exchanging access tokens (#6293)
|
||||
* Add ability to sort issues by due date (#6206) (#6244)
|
||||
* Style tweaks to issue selection (#6196)
|
||||
@@ -1062,13 +1654,13 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* BUGFIXES
|
||||
* Allow resend of confirmation email when logged in (#6482) (#6487)
|
||||
|
||||
## [1.7.5](https://github.com/go-gitea/gitea/releases/tag/v1.7.5) - 2019-03-27
|
||||
## [1.7.5](https://github.com/go-gitea/gitea/releases/tag/v1.7.5) - 2019-03-27
|
||||
* BUGFIXES
|
||||
* Fix unitTypeCode not being used in accessLevelUnit (#6419) (#6423)
|
||||
* Fix bug where manifest.json was being requested without cookies and continuously creating new sessions (#6372) (#6383)
|
||||
* Fix ParsePatch function to work with quoted diff --git strings (#6323) (#6332)
|
||||
|
||||
## [1.7.4](https://github.com/go-gitea/gitea/releases/tag/v1.7.4) - 2019-03-12
|
||||
## [1.7.4](https://github.com/go-gitea/gitea/releases/tag/v1.7.4) - 2019-03-12
|
||||
* SECURITY
|
||||
* Fix potential XSS vulnerability in repository description. (#6306) (#6308)
|
||||
* BUGFIXES
|
||||
@@ -1136,7 +1728,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* BREAKING
|
||||
* Restrict permission check on repositories and fix some problems (#5314)
|
||||
* Show only opened milestones on issues page milestone filter (#5051)
|
||||
* FEATURE
|
||||
* FEATURES
|
||||
* Implement git refs API for listing references (branches, tags and other) (#5354)
|
||||
* Approvals at Branch Protection (#5350)
|
||||
* Add raw blob endpoint to get objects by SHA ID (#5334)
|
||||
@@ -1221,7 +1813,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* LDAP via simple auth separate bind user and search base (#5055)
|
||||
* Fix markdown image with link (#4675)
|
||||
* Fix to 3819 - Filtering issues by tags on main screen issues (#3824)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Delete organization endpoint added (#5601)
|
||||
* Update Licenses (#5558)
|
||||
* Support reverse proxy providing email (#5554)
|
||||
@@ -1331,7 +1923,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Make cookies HttpOnly and obey COOKIE_SECURE flag (#4706)
|
||||
* Don't disclose emails of all users when sending out emails (#4664)
|
||||
* Check that repositories can only be migrated to own user or organizations (#4366)
|
||||
* FEATURE
|
||||
* FEATURES
|
||||
* Add comment replies (#5147) (#5104)
|
||||
* Pull request review/approval and comment on code (#3748)
|
||||
* Added dependencies for issues (#2196) (#2531)
|
||||
@@ -1344,7 +1936,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Add push webhook support for mirrored repositories (#4127)
|
||||
* Add csv file render support defaultly (#4105)
|
||||
* Add Recaptcha functionality to Gitea (#4044)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Fix milestones sorted wrongly (#4987)
|
||||
* Allow api to create tags for releases if they don't exist (#4890)
|
||||
* Fix #4877 to follow the OpenID Connect Audiences spec (#4878)
|
||||
@@ -1526,7 +2118,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Fix bugs when too many IN variables (#4594) (#4597)
|
||||
* Push whitelist now doesn't apply to branch deletion (#4601) (#4640)
|
||||
* Site admin could create repos even MAX_CREATION_LIMIT=0 (#4645) (#4650)
|
||||
* FEATURE
|
||||
* FEATURES
|
||||
* Add cli commands to regen hooks & keys (#3979)
|
||||
* Add support for FIDO U2F (#3971)
|
||||
* Added user language setting (#3875)
|
||||
@@ -1540,7 +2132,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Add repository setting to enable/disable health checks (#3607)
|
||||
* Emoji Autocomplete (#3433)
|
||||
* Implements generator cli for secrets (#3531)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Add more webhooks support and refactor webhook templates directory (#3929)
|
||||
* Add new option to allow only OAuth2/OpenID user registration (#3910)
|
||||
* Add option to use paged LDAP search when synchronizing users (#3895)
|
||||
@@ -1624,7 +2216,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Fix escaping changed title in comments (#3530) (#3534)
|
||||
* Escape search query (#3486) (#3488)
|
||||
* Sanitize logs for mirror sync (#3057)
|
||||
* FEATURE
|
||||
* FEATURES
|
||||
* Serve .patch and .diff for pull requests (#3305, #3293)
|
||||
* Add repo-sync-releases admin command (#3254)
|
||||
* Support default private when creating or migrating repository (#3239)
|
||||
@@ -1687,7 +2279,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Fix go-get, src and raw urls to new scheme (#2978)
|
||||
* Fix error when add user has full name to team (#2973)
|
||||
* Fix memcache support when value is returned as string always (#2924)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Use GiteaServer as the user agent for http requests (#3404)
|
||||
* Delete indexer DB entries when (re)creating index (#3385)
|
||||
* Change how merged PR commit info are prepared (#3368)
|
||||
@@ -1746,7 +2338,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
## [1.3.0](https://github.com/go-gitea/gitea/releases/tag/v1.3.0) - 2017-11-29
|
||||
* BREAKING
|
||||
* Make URL scheme unambiguous (#2408)
|
||||
* FEATURE
|
||||
* FEATURES
|
||||
* Add branch overiew page (#2108)
|
||||
* Code/repo search (#2582)
|
||||
* Add Activity page to repository (#2674)
|
||||
@@ -1850,7 +2442,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Fix typos in app.ini (#2732)
|
||||
* Fix duplicated rel attribute (#2549)
|
||||
* Fix tests code to prevent some runtime errors (#2381)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Memory usage improvements and lower minimal git requirement to 1.7.2 (#3013) (#3028)
|
||||
* Set OpenID support on by default when installing new instance (#3010) (#3027)
|
||||
* Use api.TrackedTime in API (#2807)
|
||||
@@ -1996,7 +2588,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Sanitation fix from Gogs (#1461)
|
||||
* BREAKING
|
||||
* Rename /forget_password url to /forgot_password (#1219)
|
||||
* FEATURE
|
||||
* FEATURES
|
||||
* Logo: Add task to generate images from SVG and change to new logo (#2194)
|
||||
* Status-API (#1332)
|
||||
* Show commit status icon in commits table (#1688)
|
||||
@@ -2023,7 +2615,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Add change-password admin command (#1304)
|
||||
* Only use issue and wiki on repo. (#1297)
|
||||
* Allow push to init a wiki repo (#1279)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Make time diff translatable (#2057)
|
||||
* Smaller watch, star, and fork buttons (#2052)
|
||||
* Display config file path on admin panel (#2030)
|
||||
@@ -2518,7 +3110,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
|
||||
* BREAKING
|
||||
* The SSH keys can potentially break, make sure to regenerate the authorized keys
|
||||
* FEATURE
|
||||
* FEATURES
|
||||
* Git LFSv2 support [#122](https://github.com/go-gitea/gitea/pull/122)
|
||||
* API endpoints for repo watching [#191](https://github.com/go-gitea/gitea/pull/191)
|
||||
* Search within private repos [#222](https://github.com/go-gitea/gitea/pull/222)
|
||||
@@ -2570,7 +3162,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Don't rewrite non-gitea public keys [#906](https://github.com/go-gitea/gitea/pull/906)
|
||||
* Use fingerprint to check instead content for public key [#911](https://github.com/go-gitea/gitea/pull/911)
|
||||
* Fix random avatars [#1147](https://github.com/go-gitea/gitea/pull/1147)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Refactored process manager [#75](https://github.com/go-gitea/gitea/pull/75)
|
||||
* Restrict rights to create new orgs [#193](https://github.com/go-gitea/gitea/pull/193)
|
||||
* Added label and milestone sorting [#199](https://github.com/go-gitea/gitea/pull/199)
|
||||
@@ -2632,7 +3224,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
|
||||
* BREAKING
|
||||
* We have various changes on the API, scripting against API must be updated
|
||||
* FEATURE
|
||||
* FEATURES
|
||||
* Show last login for admins [#121](https://github.com/go-gitea/gitea/pull/121)
|
||||
* BUGFIXES
|
||||
* Fixed sender of notifications [#2](https://github.com/go-gitea/gitea/pull/2)
|
||||
@@ -2645,7 +3237,7 @@ been added to each release, please refer to the [blog](https://blog.gitea.io).
|
||||
* Replace tabs with spaces on wiki title [#371](https://github.com/go-gitea/gitea/pull/371)
|
||||
* Fixed vulnerability on labels and releases [#409](https://github.com/go-gitea/gitea/pull/409)
|
||||
* Fixed issue comment API [#449](https://github.com/go-gitea/gitea/pull/449)
|
||||
* ENHANCEMENT
|
||||
* ENHANCEMENTS
|
||||
* Use proper import path for libravatar [#3](https://github.com/go-gitea/gitea/pull/3)
|
||||
* Integrated DroneCI for tests and builds [#24](https://github.com/go-gitea/gitea/issues/24)
|
||||
* Integrated dependency manager [#29](https://github.com/go-gitea/gitea/issues/29)
|
||||
|
@@ -11,6 +11,8 @@
|
||||
- [Translation](#translation)
|
||||
- [Code review](#code-review)
|
||||
- [Styleguide](#styleguide)
|
||||
- [Design guideline](#design-guideline)
|
||||
- [API v1](#api-v1)
|
||||
- [Developer Certificate of Origin (DCO)](#developer-certificate-of-origin-dco)
|
||||
- [Release Cycle](#release-cycle)
|
||||
- [Maintainers](#maintainers)
|
||||
@@ -71,13 +73,15 @@ Here's how to run the test suite:
|
||||
|
||||
- Install the correct version of the drone-cli package. As of this
|
||||
writing, the correct drone-cli version is
|
||||
[1.1.0](https://docs.drone.io/cli/install/).
|
||||
[1.2.0](https://docs.drone.io/cli/install/).
|
||||
- Ensure you have enough free disk space. You will need at least
|
||||
15-20 Gb of free disk space to hold all of the containers drone
|
||||
creates (a default AWS or GCE disk size won't work -- see
|
||||
[#6243](https://github.com/go-gitea/gitea/issues/6243)).
|
||||
- Change into the base directory of your copy of the gitea repository,
|
||||
and run `drone exec --event pull_request`.
|
||||
- At the moment `drone exec` doesn't support the Docker Toolbox on Windows 10
|
||||
(see [drone-cli#135](https://github.com/drone/drone-cli/issues/135))
|
||||
|
||||
The drone version, command line, and disk requirements do change over
|
||||
time (see [#4053](https://github.com/go-gitea/gitea/issues/4053) and
|
||||
@@ -111,13 +115,15 @@ included in the next released version.
|
||||
## Building Gitea
|
||||
|
||||
Generally, the go build tools are installed as-needed in the `Makefile`.
|
||||
An exception are the tools to build the CSS and images.
|
||||
An exception are the tools to build the CSS, JS and images.
|
||||
|
||||
- To build CSS: Install [Node.js](https://nodejs.org/en/download/package-manager) at version 8.0 or above
|
||||
with `npm` and then run `npm install` and `make css`.
|
||||
- To build CSS and JS: Install [Node.js](https://nodejs.org/en/download/package-manager) at version 10.0 or above
|
||||
with `npm` and then run `npm install`, `make css` and `make js`.
|
||||
- To build Images: ImageMagick, inkscape and zopflipng binaries must be
|
||||
available in your `PATH` to run `make generate-images`.
|
||||
|
||||
For more details on how to generate files, build and test Gitea, see the [hacking instructions](https://docs.gitea.io/en-us/hacking-on-gitea/)
|
||||
|
||||
## Code review
|
||||
|
||||
Changes to Gitea must be reviewed before they are accepted—no matter who
|
||||
@@ -157,6 +163,59 @@ import (
|
||||
)
|
||||
```
|
||||
|
||||
## Design guideline
|
||||
|
||||
To maintain understandable code and avoid circular dependencies it is important to have a good structure of the code. The gitea code is divided into the following parts:
|
||||
|
||||
- **integration:** Integrations tests
|
||||
- **models:** Contains the data structures used by xorm to construct database tables. It also contains supporting functions to query and update the database. Dependecies to other code in Gitea should be avoided although some modules might be needed (for example for logging).
|
||||
- **models/fixtures:** Sample model data used in integration tests.
|
||||
- **models/migrations:** Handling of database migrations between versions. PRs that changes a database structure shall also have a migration step.
|
||||
- **modules:** Different modules to handle specific functionality in Gitea.
|
||||
- **public:** Frontend files (javascript, images, css, etc.)
|
||||
- **routers:** Handling of server requests. As it uses other Gitea packages to serve the request, other packages (models, modules or services) shall not depend on routers
|
||||
- **services:** Support functions for common routing operations. Uses models and modules to handle the request.
|
||||
- **templates:** Golang templates for generating the html output.
|
||||
- **vendor:** External code that Gitea depends on.
|
||||
|
||||
## API v1
|
||||
|
||||
The API is documented by [swagger](http://try.gitea.io/api/swagger) and is based on [GitHub API v3](https://developer.github.com/v3/).
|
||||
Thus, Gitea´s API should use the same endpoints and fields as GitHub´s API as far as possible, unless there are good reasons to deviate.
|
||||
If Gitea provides functionality that GitHub does not, a new endpoint can be created.
|
||||
If information is provided by Gitea that is not provided by the GitHub API, a new field can be used that doesn't collide with any GitHub fields.
|
||||
|
||||
Updating an existing API should not remove existing fields unless there is a really good reason to do so.
|
||||
The same applies to status responses. If you notice a problem, feel free to leave a comment in the code for future refactoring to APIv2 (which is currently not planned).
|
||||
|
||||
All expected results (errors, success, fail messages) should be documented
|
||||
([example](https://github.com/go-gitea/gitea/blob/c620eb5b2d0d874da68ebd734d3864c5224f71f7/routers/api/v1/repo/issue.go#L319-L327)).
|
||||
|
||||
All JSON input types must be defined as a struct in `models/structs/`
|
||||
([example](https://github.com/go-gitea/gitea/blob/c620eb5b2d0d874da68ebd734d3864c5224f71f7/modules/structs/issue.go#L76-L91))
|
||||
and referenced in
|
||||
[routers/api/v1/swagger/options.go](https://github.com/go-gitea/gitea/blob/c620eb5b2d0d874da68ebd734d3864c5224f71f7/routers/api/v1/swagger/options.go).
|
||||
They can then be used like the following:
|
||||
([example](https://github.com/go-gitea/gitea/blob/c620eb5b2d0d874da68ebd734d3864c5224f71f7/routers/api/v1/repo/issue.go#L318)).
|
||||
|
||||
All JSON responses must be defined as a struct in `models/structs/`
|
||||
([example](https://github.com/go-gitea/gitea/blob/c620eb5b2d0d874da68ebd734d3864c5224f71f7/modules/structs/issue.go#L36-L68))
|
||||
and referenced in its category in `routers/api/v1/swagger/`
|
||||
([example](https://github.com/go-gitea/gitea/blob/c620eb5b2d0d874da68ebd734d3864c5224f71f7/routers/api/v1/swagger/issue.go#L11-L16))
|
||||
They can be used like the following:
|
||||
([example](https://github.com/go-gitea/gitea/blob/c620eb5b2d0d874da68ebd734d3864c5224f71f7/routers/api/v1/repo/issue.go#L277-L279))
|
||||
|
||||
In general, HTTP methods are chosen as follows:
|
||||
* **GET** endpoints return requested object and status **OK (200)**
|
||||
* **DELETE** endpoints return status **No Content (204)**
|
||||
* **POST** endpoints return status **Created (201)**, used to **create** new objects (e.g. a User)
|
||||
* **PUT** endpoints return status **No Content (204)**, used to **add/assign** existing Obejcts (e.g. User) to something (e.g. Org-Team)
|
||||
* **PATCH** endpoints return changed object and status **OK (200)**, used to **edit/change** an existing object
|
||||
|
||||
|
||||
An endpoint which changes/edits an object expects all fields to be optional (except ones to identify the object, which are required).
|
||||
|
||||
|
||||
## Developer Certificate of Origin (DCO)
|
||||
|
||||
We consider the act of contributing to the code by submitting a Pull
|
||||
@@ -257,7 +316,12 @@ they served:
|
||||
* 2019-01-01 ~ 2019-12-31
|
||||
* [Lunny Xiao](https://github.com/lunny) <xiaolunwen@gmail.com>
|
||||
* [Lauris Bukšis-Haberkorns](https://github.com/lafriks) <lauris@nix.lv>
|
||||
* [Matti Ranta](https://github.com/techknowlogick) <matti@mdranta.net>
|
||||
* [Matti Ranta](https://github.com/techknowlogick) <techknowlogick@gitea.io>
|
||||
|
||||
* 2020-01-01 ~ 2020-12-31
|
||||
* [Lunny Xiao](https://gitea.com/lunny) <xiaolunwen@gmail.com>
|
||||
* [Lauris Bukšis-Haberkorns](https://gitea.com/lafriks) <lauris@nix.lv>
|
||||
* [Matti Ranta](https://gitea.com/techknowlogick) <techknowlogick@gitea.io>
|
||||
|
||||
## Versions
|
||||
|
||||
@@ -283,7 +347,7 @@ be reviewed by two maintainers and must pass the automatic tests.
|
||||
* Add a tag as `git tag -s -F release.notes v$vmaj.$vmin.$`, release.notes file could be a temporary file to only include the changelog this version which you added to `CHANGELOG.md`.
|
||||
* And then push the tag as `git push origin v$vmaj.$vmin.$`. Drone CI will automatically created a release and upload all the compiled binary. (But currently it didn't add the release notes automatically. Maybe we should fix that.)
|
||||
* If needed send PR for changelog on branch `master`.
|
||||
* Send PR to [blog repository](https://github.com/go-gitea/blog) announcing the release.
|
||||
* Send PR to [blog repository](https://gitea.com/gitea/blog) announcing the release.
|
||||
|
||||
## Copyright
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
|
||||
###################################
|
||||
#Build stage
|
||||
FROM golang:1.13-alpine3.10 AS build-env
|
||||
FROM golang:1.13-alpine3.11 AS build-env
|
||||
|
||||
ARG GOPROXY
|
||||
ENV GOPROXY ${GOPROXY:-direct}
|
||||
@@ -11,7 +11,7 @@ ARG TAGS="sqlite sqlite_unlock_notify"
|
||||
ENV TAGS "bindata $TAGS"
|
||||
|
||||
#Build deps
|
||||
RUN apk --no-cache add build-base git
|
||||
RUN apk --no-cache add build-base git nodejs npm
|
||||
|
||||
#Setup repo
|
||||
COPY . ${GOPATH}/src/code.gitea.io/gitea
|
||||
@@ -19,9 +19,9 @@ WORKDIR ${GOPATH}/src/code.gitea.io/gitea
|
||||
|
||||
#Checkout version if set
|
||||
RUN if [ -n "${GITEA_VERSION}" ]; then git checkout "${GITEA_VERSION}"; fi \
|
||||
&& make clean generate build
|
||||
&& make clean build
|
||||
|
||||
FROM alpine:3.10
|
||||
FROM alpine:3.11
|
||||
LABEL maintainer="maintainers@gitea.io"
|
||||
|
||||
EXPOSE 22 3000
|
||||
|
@@ -19,7 +19,7 @@ Lauris Bukšis-Haberkorns <lauris@nix.lv> (@lafriks)
|
||||
Jonas Östanbäck <jonas.ostanback@gmail.com> (@cez81)
|
||||
David Schneiderbauer <dschneiderbauer@gmail.com> (@daviian)
|
||||
Peter Žeby <morlinest@gmail.com> (@morlinest)
|
||||
Matti Ranta <matti@mdranta.net> (@techknowlogick)
|
||||
Matti Ranta <techknowlogick@gitea.io> (@techknowlogick)
|
||||
Jonas Franz <info@jonasfranz.software> (@jonasfranz)
|
||||
Alexey Terentyev <axifnx@gmail.com> (@axifive)
|
||||
Lanre Adelowo <yo@lanre.wtf> (@adelowo)
|
||||
@@ -34,3 +34,5 @@ Gary Kim <gary@garykim.dev> (@gary-kim)
|
||||
Guillermo Prandi <gitea.maint@mailfilter.com.ar> (@guillep2k)
|
||||
Mura Li <typeless@ctli.io> (@typeless)
|
||||
6543 <6543@obermui.de> (@6543)
|
||||
jaqra <jaqra@hotmail.com> (@jaqra)
|
||||
David Svantesson <davidsvantesson@gmail.com> (@davidsvantesson)
|
||||
|
178
Makefile
178
Makefile
@@ -16,16 +16,20 @@ else
|
||||
ifeq ($(UNAME_S),Darwin)
|
||||
SED_INPLACE := sed -i ''
|
||||
endif
|
||||
ifeq ($(UNAME_S),FreeBSD)
|
||||
SED_INPLACE := sed -i ''
|
||||
endif
|
||||
endif
|
||||
|
||||
BINDATA := modules/{options,public,templates}/bindata.go
|
||||
GOFILES := $(shell find . -name "*.go" -type f ! -path "./vendor/*" ! -path "*/bindata.go")
|
||||
GOFMT ?= gofmt -s
|
||||
|
||||
GOFLAGS := -v
|
||||
EXTRA_GOFLAGS ?=
|
||||
|
||||
MAKE_VERSION := $(shell make -v | head -n 1)
|
||||
MAKE_VERSION := $(shell $(MAKE) -v | head -n 1)
|
||||
|
||||
STORED_VERSION_FILE := VERSION
|
||||
|
||||
ifneq ($(DRONE_TAG),)
|
||||
VERSION ?= $(subst v,,$(DRONE_TAG))
|
||||
@@ -36,13 +40,29 @@ else
|
||||
else
|
||||
VERSION ?= master
|
||||
endif
|
||||
GITEA_VERSION ?= $(shell git describe --tags --always | sed 's/-/+/' | sed 's/^v//')
|
||||
|
||||
STORED_VERSION=$(shell cat $(STORED_VERSION_FILE) 2>/dev/null)
|
||||
ifneq ($(STORED_VERSION),)
|
||||
GITEA_VERSION ?= $(STORED_VERSION)
|
||||
else
|
||||
GITEA_VERSION ?= $(shell git describe --tags --always | sed 's/-/+/' | sed 's/^v//')
|
||||
endif
|
||||
endif
|
||||
|
||||
LDFLAGS := $(LDFLAGS) -X "main.MakeVersion=$(MAKE_VERSION)" -X "main.Version=$(GITEA_VERSION)" -X "main.Tags=$(TAGS)"
|
||||
|
||||
PACKAGES ?= $(filter-out code.gitea.io/gitea/integrations/migration-test,$(filter-out code.gitea.io/gitea/integrations,$(shell GO111MODULE=on $(GO) list -mod=vendor ./... | grep -v /vendor/)))
|
||||
SOURCES ?= $(shell find . -name "*.go" -type f)
|
||||
|
||||
GO_SOURCES ?= $(shell find . -name "*.go" -type f)
|
||||
JS_SOURCES ?= $(shell find web_src/js web_src/css -type f)
|
||||
CSS_SOURCES ?= $(shell find web_src/less -type f)
|
||||
|
||||
JS_DEST := public/js/index.js
|
||||
CSS_DEST := public/css/index.css
|
||||
BINDATA_DEST := modules/public/bindata.go modules/options/bindata.go modules/templates/bindata.go
|
||||
|
||||
JS_DEST_DIR := public/js
|
||||
CSS_DEST_DIR := public/css
|
||||
|
||||
TAGS ?=
|
||||
|
||||
@@ -80,10 +100,59 @@ all: build
|
||||
|
||||
include docker/Makefile
|
||||
|
||||
.PHONY: help
|
||||
help:
|
||||
@echo "Make Routines:"
|
||||
@echo " - \"\" equivalent to \"build\""
|
||||
@echo " - build build everything"
|
||||
@echo " - frontend build frontend files"
|
||||
@echo " - backend build backend files"
|
||||
@echo " - clean delete backend and integration files"
|
||||
@echo " - clean-all delete backend, frontend and integration files"
|
||||
@echo " - css rebuild only css files"
|
||||
@echo " - js rebuild only js files"
|
||||
@echo " - generate run \"go generate\""
|
||||
@echo " - fmt format the Go code"
|
||||
@echo " - generate-swagger generate the swagger spec from code comments"
|
||||
@echo " - swagger-validate check if the swagger spec is valide"
|
||||
@echo " - revive run code linter revive"
|
||||
@echo " - misspell check if a word is written wrong"
|
||||
@echo " - vet examines Go source code and reports suspicious constructs"
|
||||
@echo " - test run unit test"
|
||||
@echo " - test-sqlite run integration test for sqlite"
|
||||
|
||||
.PHONY: go-check
|
||||
go-check:
|
||||
$(eval GO_VERSION := $(shell printf "%03d%03d%03d" $(shell go version | grep -Eo '[0-9]+\.?[0-9]+?\.?[0-9]?[[:space:]]' | tr '.' ' ');))
|
||||
@if [ "$(GO_VERSION)" -lt "001011000" ]; then \
|
||||
echo "Gitea requires Go 1.11.0 or greater to build. You can get it at https://golang.org/dl/"; \
|
||||
exit 1; \
|
||||
fi
|
||||
|
||||
.PHONY: git-check
|
||||
git-check:
|
||||
@if git lfs >/dev/null 2>&1 ; then : ; else \
|
||||
echo "Gitea requires git with lfs support to run tests." ; \
|
||||
exit 1; \
|
||||
fi
|
||||
|
||||
.PHONY: node-check
|
||||
node-check:
|
||||
$(eval NODE_VERSION := $(shell printf "%03d%03d%03d" $(shell node -v | grep -Eo '[0-9]+\.?[0-9]+?\.?[0-9]?' | tr '.' ' ');))
|
||||
$(eval NPM_MISSING := $(shell hash npm > /dev/null 2>&1 || echo 1))
|
||||
@if [ "$(NODE_VERSION)" -lt "010000000" -o "$(NPM_MISSING)" = "1" ]; then \
|
||||
echo "Gitea requires Node.js 10.0.0 or greater and npm to build. You can get it at https://nodejs.org/en/download/"; \
|
||||
exit 1; \
|
||||
fi
|
||||
|
||||
.PHONY: clean-all
|
||||
clean-all: clean
|
||||
rm -rf $(JS_DEST_DIR) $(CSS_DEST_DIR)
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
$(GO) clean -i ./...
|
||||
rm -rf $(EXECUTABLE) $(DIST) $(BINDATA) \
|
||||
rm -rf $(EXECUTABLE) $(DIST) $(BINDATA_DEST) \
|
||||
integrations*.test \
|
||||
integrations/gitea-integration-pgsql/ integrations/gitea-integration-mysql/ integrations/gitea-integration-mysql8/ integrations/gitea-integration-sqlite/ \
|
||||
integrations/gitea-integration-mssql/ integrations/indexers-mysql/ integrations/indexers-mysql8/ integrations/indexers-pgsql integrations/indexers-sqlite \
|
||||
@@ -97,10 +166,6 @@ fmt:
|
||||
vet:
|
||||
$(GO) vet $(PACKAGES)
|
||||
|
||||
.PHONY: generate
|
||||
generate:
|
||||
GO111MODULE=on $(GO) generate -mod=vendor $(PACKAGES)
|
||||
|
||||
.PHONY: generate-swagger
|
||||
generate-swagger:
|
||||
$(SWAGGER) generate spec -o './$(SWAGGER_SPEC)'
|
||||
@@ -168,6 +233,10 @@ fmt-check:
|
||||
test:
|
||||
GO111MODULE=on $(GO) test -mod=vendor -tags='sqlite sqlite_unlock_notify' $(PACKAGES)
|
||||
|
||||
.PHONY: test\#%
|
||||
test\#%:
|
||||
GO111MODULE=on $(GO) test -mod=vendor -tags='sqlite sqlite_unlock_notify' -run $* $(PACKAGES)
|
||||
|
||||
.PHONY: coverage
|
||||
coverage:
|
||||
@hash gocovmerge > /dev/null 2>&1; if [ $$? -ne 0 ]; then \
|
||||
@@ -177,7 +246,7 @@ coverage:
|
||||
|
||||
.PHONY: unit-test-coverage
|
||||
unit-test-coverage:
|
||||
$(GO) test -tags='sqlite sqlite_unlock_notify' -cover -coverprofile coverage.out $(PACKAGES) && echo "\n==>\033[32m Ok\033[m\n" || exit 1
|
||||
GO111MODULE=on $(GO) test -mod=vendor -tags='sqlite sqlite_unlock_notify' -cover -coverprofile coverage.out $(PACKAGES) && echo "\n==>\033[32m Ok\033[m\n" || exit 1
|
||||
|
||||
.PHONY: vendor
|
||||
vendor:
|
||||
@@ -305,42 +374,42 @@ bench-pgsql: integrations.pgsql.test generate-ini-pgsql
|
||||
integration-test-coverage: integrations.cover.test generate-ini-mysql
|
||||
GITEA_ROOT=${CURDIR} GITEA_CONF=integrations/mysql.ini ./integrations.cover.test -test.coverprofile=integration.coverage.out
|
||||
|
||||
integrations.mysql.test: $(SOURCES)
|
||||
integrations.mysql.test: $(GO_SOURCES)
|
||||
GO111MODULE=on $(GO) test -mod=vendor -c code.gitea.io/gitea/integrations -o integrations.mysql.test
|
||||
|
||||
integrations.mysql8.test: $(SOURCES)
|
||||
integrations.mysql8.test: $(GO_SOURCES)
|
||||
GO111MODULE=on $(GO) test -mod=vendor -c code.gitea.io/gitea/integrations -o integrations.mysql8.test
|
||||
|
||||
integrations.pgsql.test: $(SOURCES)
|
||||
integrations.pgsql.test: $(GO_SOURCES)
|
||||
GO111MODULE=on $(GO) test -mod=vendor -c code.gitea.io/gitea/integrations -o integrations.pgsql.test
|
||||
|
||||
integrations.mssql.test: $(SOURCES)
|
||||
integrations.mssql.test: $(GO_SOURCES)
|
||||
GO111MODULE=on $(GO) test -mod=vendor -c code.gitea.io/gitea/integrations -o integrations.mssql.test
|
||||
|
||||
integrations.sqlite.test: $(SOURCES)
|
||||
integrations.sqlite.test: $(GO_SOURCES)
|
||||
GO111MODULE=on $(GO) test -mod=vendor -c code.gitea.io/gitea/integrations -o integrations.sqlite.test -tags 'sqlite sqlite_unlock_notify'
|
||||
|
||||
integrations.cover.test: $(SOURCES)
|
||||
integrations.cover.test: git-check $(GO_SOURCES)
|
||||
GO111MODULE=on $(GO) test -mod=vendor -c code.gitea.io/gitea/integrations -coverpkg $(shell echo $(PACKAGES) | tr ' ' ',') -o integrations.cover.test
|
||||
|
||||
.PHONY: migrations.mysql.test
|
||||
migrations.mysql.test: $(SOURCES)
|
||||
migrations.mysql.test: $(GO_SOURCES)
|
||||
$(GO) test -c code.gitea.io/gitea/integrations/migration-test -o migrations.mysql.test
|
||||
|
||||
.PHONY: migrations.mysql8.test
|
||||
migrations.mysql8.test: $(SOURCES)
|
||||
migrations.mysql8.test: $(GO_SOURCES)
|
||||
$(GO) test -c code.gitea.io/gitea/integrations/migration-test -o migrations.mysql8.test
|
||||
|
||||
.PHONY: migrations.pgsql.test
|
||||
migrations.pgsql.test: $(SOURCES)
|
||||
migrations.pgsql.test: $(GO_SOURCES)
|
||||
$(GO) test -c code.gitea.io/gitea/integrations/migration-test -o migrations.pgsql.test
|
||||
|
||||
.PHONY: migrations.mssql.test
|
||||
migrations.mssql.test: $(SOURCES)
|
||||
migrations.mssql.test: $(GO_SOURCES)
|
||||
$(GO) test -c code.gitea.io/gitea/integrations/migration-test -o migrations.mssql.test
|
||||
|
||||
.PHONY: migrations.sqlite.test
|
||||
migrations.sqlite.test: $(SOURCES)
|
||||
migrations.sqlite.test: $(GO_SOURCES)
|
||||
$(GO) test -c code.gitea.io/gitea/integrations/migration-test -o migrations.sqlite.test -tags 'sqlite sqlite_unlock_notify'
|
||||
|
||||
.PHONY: check
|
||||
@@ -351,13 +420,23 @@ install: $(wildcard *.go)
|
||||
$(GO) install -v -tags '$(TAGS)' -ldflags '-s -w $(LDFLAGS)'
|
||||
|
||||
.PHONY: build
|
||||
build: $(EXECUTABLE)
|
||||
build: frontend backend
|
||||
|
||||
$(EXECUTABLE): $(SOURCES)
|
||||
.PHONY: frontend
|
||||
frontend: node-check js css
|
||||
|
||||
.PHONY: backend
|
||||
backend: go-check generate $(EXECUTABLE)
|
||||
|
||||
.PHONY: generate
|
||||
generate:
|
||||
GO111MODULE=on $(GO) generate -mod=vendor $(PACKAGES)
|
||||
|
||||
$(EXECUTABLE): $(GO_SOURCES)
|
||||
GO111MODULE=on $(GO) build -mod=vendor $(GOFLAGS) $(EXTRA_GOFLAGS) -tags '$(TAGS)' -ldflags '-s -w $(LDFLAGS)' -o $@
|
||||
|
||||
.PHONY: release
|
||||
release: release-dirs release-windows release-linux release-darwin release-copy release-compress release-check
|
||||
release: frontend generate release-dirs release-windows release-linux release-darwin release-copy release-compress release-sources release-check
|
||||
|
||||
.PHONY: release-dirs
|
||||
release-dirs:
|
||||
@@ -368,7 +447,7 @@ release-windows:
|
||||
@hash xgo > /dev/null 2>&1; if [ $$? -ne 0 ]; then \
|
||||
$(GO) get -u src.techknowlogick.com/xgo; \
|
||||
fi
|
||||
xgo -dest $(DIST)/binaries -tags 'netgo osusergo $(TAGS)' -ldflags '-linkmode external -extldflags "-static" $(LDFLAGS)' -targets 'windows/*' -out gitea-$(VERSION) .
|
||||
xgo -go go-1.13 -dest $(DIST)/binaries -tags 'netgo osusergo $(TAGS)' -ldflags '-linkmode external -extldflags "-static" $(LDFLAGS)' -targets 'windows/*' -out gitea-$(VERSION) .
|
||||
ifeq ($(CI),drone)
|
||||
cp /build/* $(DIST)/binaries
|
||||
endif
|
||||
@@ -378,7 +457,7 @@ release-linux:
|
||||
@hash xgo > /dev/null 2>&1; if [ $$? -ne 0 ]; then \
|
||||
$(GO) get -u src.techknowlogick.com/xgo; \
|
||||
fi
|
||||
xgo -dest $(DIST)/binaries -tags 'netgo osusergo $(TAGS)' -ldflags '-linkmode external -extldflags "-static" $(LDFLAGS)' -targets 'linux/amd64,linux/386,linux/arm-5,linux/arm-6,linux/arm64,linux/mips64le,linux/mips,linux/mipsle' -out gitea-$(VERSION) .
|
||||
xgo -go go-1.13 -dest $(DIST)/binaries -tags 'netgo osusergo $(TAGS)' -ldflags '-linkmode external -extldflags "-static" $(LDFLAGS)' -targets 'linux/amd64,linux/386,linux/arm-5,linux/arm-6,linux/arm64,linux/mips64le,linux/mips,linux/mipsle' -out gitea-$(VERSION) .
|
||||
ifeq ($(CI),drone)
|
||||
cp /build/* $(DIST)/binaries
|
||||
endif
|
||||
@@ -388,7 +467,7 @@ release-darwin:
|
||||
@hash xgo > /dev/null 2>&1; if [ $$? -ne 0 ]; then \
|
||||
$(GO) get -u src.techknowlogick.com/xgo; \
|
||||
fi
|
||||
xgo -dest $(DIST)/binaries -tags 'netgo osusergo $(TAGS)' -ldflags '$(LDFLAGS)' -targets 'darwin/*' -out gitea-$(VERSION) .
|
||||
xgo -go go-1.13 -dest $(DIST)/binaries -tags 'netgo osusergo $(TAGS)' -ldflags '$(LDFLAGS)' -targets 'darwin/*' -out gitea-$(VERSION) .
|
||||
ifeq ($(CI),drone)
|
||||
cp /build/* $(DIST)/binaries
|
||||
endif
|
||||
@@ -408,43 +487,36 @@ release-compress:
|
||||
fi
|
||||
cd $(DIST)/release/; for file in `find . -type f -name "*"`; do echo "compressing $${file}" && gxz -k -9 $${file}; done;
|
||||
|
||||
npm-check:
|
||||
@hash npm > /dev/null 2>&1; if [ $$? -ne 0 ]; then \
|
||||
echo "Please install Node.js 8.x or greater with npm"; \
|
||||
exit 1; \
|
||||
fi;
|
||||
@hash npx > /dev/null 2>&1; if [ $$? -ne 0 ]; then \
|
||||
echo "Please install Node.js 8.x or greater with npm"; \
|
||||
exit 1; \
|
||||
fi;
|
||||
.PHONY: release-sources
|
||||
release-sources: | node_modules
|
||||
echo $(VERSION) > $(STORED_VERSION_FILE)
|
||||
tar --exclude=./$(DIST) --exclude=./.git --exclude=./node_modules/.cache -czf $(DIST)/release/gitea-src-$(VERSION).tar.gz .
|
||||
rm -f $(STORED_VERSION_FILE)
|
||||
|
||||
.PHONY: npm
|
||||
npm: npm-check
|
||||
node_modules: package-lock.json
|
||||
npm install --no-save
|
||||
|
||||
.PHONY: npm-update
|
||||
npm-update: npm-check
|
||||
npm-update: node-check node_modules
|
||||
npx updates -cu
|
||||
rm -rf node_modules package-lock.json
|
||||
npm install --package-lock
|
||||
|
||||
.PHONY: js
|
||||
js: npm
|
||||
npx eslint public/js
|
||||
js: node-check $(JS_DEST)
|
||||
|
||||
$(JS_DEST): node_modules $(JS_SOURCES)
|
||||
npx eslint web_src/js webpack.config.js
|
||||
npx webpack
|
||||
|
||||
.PHONY: css
|
||||
css: npm
|
||||
npx stylelint public/less
|
||||
npx lessc --clean-css="--s0 -b" public/less/index.less public/css/index.css
|
||||
$(foreach file, $(filter-out public/less/themes/_base.less, $(wildcard public/less/themes/*)),npx lessc --clean-css="--s0 -b" public/less/themes/$(notdir $(file)) > public/css/theme-$(notdir $(call strip-suffix,$(file))).css;)
|
||||
npx postcss --use autoprefixer --no-map --replace public/css/*
|
||||
css: node-check $(CSS_DEST)
|
||||
|
||||
@diff=$$(git diff public/css/*); \
|
||||
if ([ -n "$$CI" ] && [ -n "$$diff" ]); then \
|
||||
echo "Generated files in public/css have changed, please commit the result:"; \
|
||||
echo "$${diff}"; \
|
||||
exit 1; \
|
||||
fi;
|
||||
$(CSS_DEST): node_modules $(CSS_SOURCES)
|
||||
npx stylelint web_src/less
|
||||
npx lessc web_src/less/index.less public/css/index.css
|
||||
$(foreach file, $(filter-out web_src/less/themes/_base.less, $(wildcard web_src/less/themes/*)),npx lessc web_src/less/themes/$(notdir $(file)) > public/css/theme-$(notdir $(call strip-suffix,$(file))).css;)
|
||||
npx postcss --use autoprefixer --use cssnano --no-map --replace public/css/*
|
||||
|
||||
.PHONY: javascripts
|
||||
javascripts:
|
||||
@@ -517,4 +589,4 @@ golangci-lint:
|
||||
export BINARY="golangci-lint"; \
|
||||
curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(GOPATH)/bin v1.20.0; \
|
||||
fi
|
||||
golangci-lint run
|
||||
golangci-lint run --timeout 5m
|
||||
|
24
README.md
24
README.md
@@ -1,6 +1,6 @@
|
||||
[简体中文](https://github.com/go-gitea/gitea/blob/master/README_ZH.md)
|
||||
[简体中文](README_ZH.md)
|
||||
|
||||
# Gitea - Git with a cup of tea
|
||||
<h1> <img src="https://raw.githubusercontent.com/go-gitea/gitea/master/public/img/gitea-192.png" alt="logo" width="30" height="30"> Gitea - Git with a cup of tea</h1>
|
||||
|
||||
[](https://drone.gitea.io/go-gitea/gitea)
|
||||
[](https://discord.gg/NsatcWJ)
|
||||
@@ -31,7 +31,16 @@ This project has been
|
||||
|
||||
From the root of the source tree, run:
|
||||
|
||||
TAGS="bindata" make generate all
|
||||
TAGS="bindata" make build
|
||||
|
||||
The `build` target is split into two sub-targets:
|
||||
|
||||
- `make backend` which requires [Go 1.11](https://golang.org/dl/) or greater.
|
||||
- `make frontend` which requires [Node.js 10.0.0](https://nodejs.org/en/download/) or greater.
|
||||
|
||||
If pre-built frontend files are present it is possible to only build the backend:
|
||||
|
||||
TAGS="bindata" make backend
|
||||
|
||||
More info: https://docs.gitea.io/en-us/install-from-source/
|
||||
|
||||
@@ -105,9 +114,8 @@ for the full license text.
|
||||
## Screenshots
|
||||
Looking for an overview of the interface? Check it out!
|
||||
|
||||
| | | |
|
||||
||||
|
||||
|:---:|:---:|:---:|
|
||||
||||
|
||||
||||
|
||||
||||
|
||||
||||
|
||||
||||
|
||||
|||
|
||||
|||
|
||||
|
16
README_ZH.md
16
README_ZH.md
@@ -1,14 +1,15 @@
|
||||
[English](https://github.com/go-gitea/gitea/blob/master/README.md)
|
||||
[English](README.md)
|
||||
|
||||
# Gitea - Git with a cup of tea
|
||||
<h1> <img src="https://raw.githubusercontent.com/go-gitea/gitea/master/public/img/gitea-192.png" alt="logo" width="30" height="30"> Gitea - Git with a cup of tea</h1>
|
||||
|
||||
[](https://drone.gitea.io/go-gitea/gitea)
|
||||
[](https://discord.gg/gitea)
|
||||
[](https://discord.gg/NsatcWJ)
|
||||
[](https://microbadger.com/images/gitea/gitea "Get your own image badge on microbadger.com")
|
||||
[](https://codecov.io/gh/go-gitea/gitea)
|
||||
[](https://goreportcard.com/report/code.gitea.io/gitea)
|
||||
[](https://godoc.org/code.gitea.io/gitea)
|
||||
[](https://github.com/go-gitea/gitea/releases/latest)
|
||||
[](https://www.codetriage.com/go-gitea/gitea)
|
||||
[](https://opencollective.com/gitea)
|
||||
[](https://opensource.org/licenses/MIT)
|
||||
[](https://crowdin.com/project/gitea)
|
||||
@@ -45,9 +46,8 @@ Fork -> Patch -> Push -> Pull Request
|
||||
|
||||
## 截图
|
||||
|
||||
| | | |
|
||||
||||
|
||||
|:---:|:---:|:---:|
|
||||
||||
|
||||
||||
|
||||
||||
|
||||
||||
|
||||
||||
|
||||
|||
|
||||
|||
|
||||
|
10
cmd/admin.go
10
cmd/admin.go
@@ -16,6 +16,7 @@ import (
|
||||
"code.gitea.io/gitea/modules/git"
|
||||
"code.gitea.io/gitea/modules/log"
|
||||
pwd "code.gitea.io/gitea/modules/password"
|
||||
"code.gitea.io/gitea/modules/repository"
|
||||
"code.gitea.io/gitea/modules/setting"
|
||||
|
||||
"github.com/urfave/cli"
|
||||
@@ -66,7 +67,7 @@ var (
|
||||
},
|
||||
cli.BoolFlag{
|
||||
Name: "must-change-password",
|
||||
Usage: "Force the user to change his/her password after initial login",
|
||||
Usage: "Set this option to false to prevent forcing the user to change their password after initial login, (Default: true)",
|
||||
},
|
||||
cli.IntFlag{
|
||||
Name: "random-password-length",
|
||||
@@ -154,6 +155,7 @@ var (
|
||||
microcmdAuthDelete = cli.Command{
|
||||
Name: "delete",
|
||||
Usage: "Delete specific auth source",
|
||||
Flags: []cli.Flag{idFlag},
|
||||
Action: runDeleteAuth,
|
||||
}
|
||||
|
||||
@@ -373,7 +375,7 @@ func runRepoSyncReleases(c *cli.Context) error {
|
||||
}
|
||||
log.Trace(" currentNumReleases is %d, running SyncReleasesWithTags", oldnum)
|
||||
|
||||
if err = models.SyncReleasesWithTags(repo, gitRepo); err != nil {
|
||||
if err = repository.SyncReleasesWithTags(repo, gitRepo); err != nil {
|
||||
log.Warn(" SyncReleasesWithTags: %v", err)
|
||||
gitRepo.Close()
|
||||
continue
|
||||
@@ -532,9 +534,9 @@ func runListAuth(c *cli.Context) error {
|
||||
|
||||
// loop through each source and print
|
||||
w := tabwriter.NewWriter(os.Stdout, 0, 0, 1, ' ', tabwriter.AlignRight)
|
||||
fmt.Fprintf(w, "ID\tName\tType\tEnabled")
|
||||
fmt.Fprintf(w, "ID\tName\tType\tEnabled\n")
|
||||
for _, source := range loginSources {
|
||||
fmt.Fprintf(w, "%d\t%s\t%s\t%t", source.ID, source.Name, models.LoginNames[source.Type], source.IsActived)
|
||||
fmt.Fprintf(w, "%d\t%s\t%s\t%t\n", source.ID, source.Name, models.LoginNames[source.Type], source.IsActived)
|
||||
}
|
||||
w.Flush()
|
||||
|
||||
|
@@ -61,6 +61,10 @@ var (
|
||||
Name: "admin-filter",
|
||||
Usage: "An LDAP filter specifying if a user should be given administrator privileges.",
|
||||
},
|
||||
cli.BoolFlag{
|
||||
Name: "allow-deactivate-all",
|
||||
Usage: "Allow empty search results to deactivate all users.",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "username-attribute",
|
||||
Usage: "The attribute of the user’s LDAP record containing the user name.",
|
||||
@@ -231,6 +235,9 @@ func parseLdapConfig(c *cli.Context, config *models.LDAPConfig) error {
|
||||
if c.IsSet("admin-filter") {
|
||||
config.Source.AdminFilter = c.String("admin-filter")
|
||||
}
|
||||
if c.IsSet("allow-deactivate-all") {
|
||||
config.Source.AllowDeactivateAll = c.Bool("allow-deactivate-all")
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
|
62
cmd/dump.go
62
cmd/dump.go
@@ -8,13 +8,13 @@ package cmd
|
||||
import (
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"log"
|
||||
"os"
|
||||
"path"
|
||||
"path/filepath"
|
||||
"time"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
"code.gitea.io/gitea/modules/log"
|
||||
"code.gitea.io/gitea/modules/setting"
|
||||
|
||||
"github.com/unknwon/cae/zip"
|
||||
@@ -55,6 +55,11 @@ It can be used for backup and capture Gitea server image to send to maintainer`,
|
||||
},
|
||||
}
|
||||
|
||||
func fatal(format string, args ...interface{}) {
|
||||
fmt.Fprintf(os.Stderr, format+"\n", args...)
|
||||
log.Fatal(format, args...)
|
||||
}
|
||||
|
||||
func runDump(ctx *cli.Context) error {
|
||||
setting.NewContext()
|
||||
setting.NewServices() // cannot access session settings otherwise
|
||||
@@ -66,13 +71,13 @@ func runDump(ctx *cli.Context) error {
|
||||
|
||||
tmpDir := ctx.String("tempdir")
|
||||
if _, err := os.Stat(tmpDir); os.IsNotExist(err) {
|
||||
log.Fatalf("Path does not exist: %s", tmpDir)
|
||||
fatal("Path does not exist: %s", tmpDir)
|
||||
}
|
||||
tmpWorkDir, err := ioutil.TempDir(tmpDir, "gitea-dump-")
|
||||
if err != nil {
|
||||
log.Fatalf("Failed to create tmp work directory: %v", err)
|
||||
fatal("Failed to create tmp work directory: %v", err)
|
||||
}
|
||||
log.Printf("Creating tmp work dir: %s", tmpWorkDir)
|
||||
log.Info("Creating tmp work dir: %s", tmpWorkDir)
|
||||
|
||||
// work-around #1103
|
||||
if os.Getenv("TMPDIR") == "" {
|
||||
@@ -82,88 +87,91 @@ func runDump(ctx *cli.Context) error {
|
||||
dbDump := path.Join(tmpWorkDir, "gitea-db.sql")
|
||||
|
||||
fileName := ctx.String("file")
|
||||
log.Printf("Packing dump files...")
|
||||
log.Info("Packing dump files...")
|
||||
z, err := zip.Create(fileName)
|
||||
if err != nil {
|
||||
log.Fatalf("Failed to create %s: %v", fileName, err)
|
||||
fatal("Failed to create %s: %v", fileName, err)
|
||||
}
|
||||
|
||||
zip.Verbose = ctx.Bool("verbose")
|
||||
|
||||
if ctx.IsSet("skip-repository") {
|
||||
log.Printf("Skip dumping local repositories")
|
||||
log.Info("Skip dumping local repositories")
|
||||
} else {
|
||||
log.Printf("Dumping local repositories...%s", setting.RepoRootPath)
|
||||
log.Info("Dumping local repositories...%s", setting.RepoRootPath)
|
||||
reposDump := path.Join(tmpWorkDir, "gitea-repo.zip")
|
||||
if err := zip.PackTo(setting.RepoRootPath, reposDump, true); err != nil {
|
||||
log.Fatalf("Failed to dump local repositories: %v", err)
|
||||
fatal("Failed to dump local repositories: %v", err)
|
||||
}
|
||||
if err := z.AddFile("gitea-repo.zip", reposDump); err != nil {
|
||||
log.Fatalf("Failed to include gitea-repo.zip: %v", err)
|
||||
fatal("Failed to include gitea-repo.zip: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
targetDBType := ctx.String("database")
|
||||
if len(targetDBType) > 0 && targetDBType != setting.Database.Type {
|
||||
log.Printf("Dumping database %s => %s...", setting.Database.Type, targetDBType)
|
||||
log.Info("Dumping database %s => %s...", setting.Database.Type, targetDBType)
|
||||
} else {
|
||||
log.Printf("Dumping database...")
|
||||
log.Info("Dumping database...")
|
||||
}
|
||||
|
||||
if err := models.DumpDatabase(dbDump, targetDBType); err != nil {
|
||||
log.Fatalf("Failed to dump database: %v", err)
|
||||
fatal("Failed to dump database: %v", err)
|
||||
}
|
||||
|
||||
if err := z.AddFile("gitea-db.sql", dbDump); err != nil {
|
||||
log.Fatalf("Failed to include gitea-db.sql: %v", err)
|
||||
fatal("Failed to include gitea-db.sql: %v", err)
|
||||
}
|
||||
|
||||
if len(setting.CustomConf) > 0 {
|
||||
log.Printf("Adding custom configuration file from %s", setting.CustomConf)
|
||||
log.Info("Adding custom configuration file from %s", setting.CustomConf)
|
||||
if err := z.AddFile("app.ini", setting.CustomConf); err != nil {
|
||||
log.Fatalf("Failed to include specified app.ini: %v", err)
|
||||
fatal("Failed to include specified app.ini: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
customDir, err := os.Stat(setting.CustomPath)
|
||||
if err == nil && customDir.IsDir() {
|
||||
if err := z.AddDir("custom", setting.CustomPath); err != nil {
|
||||
log.Fatalf("Failed to include custom: %v", err)
|
||||
fatal("Failed to include custom: %v", err)
|
||||
}
|
||||
} else {
|
||||
log.Printf("Custom dir %s doesn't exist, skipped", setting.CustomPath)
|
||||
log.Info("Custom dir %s doesn't exist, skipped", setting.CustomPath)
|
||||
}
|
||||
|
||||
if com.IsExist(setting.AppDataPath) {
|
||||
log.Printf("Packing data directory...%s", setting.AppDataPath)
|
||||
log.Info("Packing data directory...%s", setting.AppDataPath)
|
||||
|
||||
var sessionAbsPath string
|
||||
if setting.SessionConfig.Provider == "file" {
|
||||
sessionAbsPath = setting.SessionConfig.ProviderConfig
|
||||
}
|
||||
if err := zipAddDirectoryExclude(z, "data", setting.AppDataPath, sessionAbsPath); err != nil {
|
||||
log.Fatalf("Failed to include data directory: %v", err)
|
||||
fatal("Failed to include data directory: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
if err := z.AddDir("log", setting.LogRootPath); err != nil {
|
||||
log.Fatalf("Failed to include log: %v", err)
|
||||
if com.IsExist(setting.LogRootPath) {
|
||||
if err := z.AddDir("log", setting.LogRootPath); err != nil {
|
||||
fatal("Failed to include log: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
if err = z.Close(); err != nil {
|
||||
_ = os.Remove(fileName)
|
||||
log.Fatalf("Failed to save %s: %v", fileName, err)
|
||||
fatal("Failed to save %s: %v", fileName, err)
|
||||
}
|
||||
|
||||
if err := os.Chmod(fileName, 0600); err != nil {
|
||||
log.Printf("Can't change file access permissions mask to 0600: %v", err)
|
||||
log.Info("Can't change file access permissions mask to 0600: %v", err)
|
||||
}
|
||||
|
||||
log.Printf("Removing tmp work dir: %s", tmpWorkDir)
|
||||
log.Info("Removing tmp work dir: %s", tmpWorkDir)
|
||||
|
||||
if err := os.RemoveAll(tmpWorkDir); err != nil {
|
||||
log.Fatalf("Failed to remove %s: %v", tmpWorkDir, err)
|
||||
fatal("Failed to remove %s: %v", tmpWorkDir, err)
|
||||
}
|
||||
log.Printf("Finish dumping in file %s", fileName)
|
||||
log.Info("Finish dumping in file %s", fileName)
|
||||
|
||||
return nil
|
||||
}
|
||||
|
353
cmd/hook.go
353
cmd/hook.go
@@ -8,18 +8,25 @@ import (
|
||||
"bufio"
|
||||
"bytes"
|
||||
"fmt"
|
||||
"io"
|
||||
"net/http"
|
||||
"os"
|
||||
"strconv"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
"code.gitea.io/gitea/modules/git"
|
||||
"code.gitea.io/gitea/modules/private"
|
||||
"code.gitea.io/gitea/modules/setting"
|
||||
|
||||
"github.com/urfave/cli"
|
||||
)
|
||||
|
||||
const (
|
||||
hookBatchSize = 30
|
||||
)
|
||||
|
||||
var (
|
||||
// CmdHook represents the available hooks sub-command.
|
||||
CmdHook = cli.Command{
|
||||
@@ -53,12 +60,101 @@ var (
|
||||
}
|
||||
)
|
||||
|
||||
type delayWriter struct {
|
||||
internal io.Writer
|
||||
buf *bytes.Buffer
|
||||
timer *time.Timer
|
||||
}
|
||||
|
||||
func newDelayWriter(internal io.Writer, delay time.Duration) *delayWriter {
|
||||
timer := time.NewTimer(delay)
|
||||
return &delayWriter{
|
||||
internal: internal,
|
||||
buf: &bytes.Buffer{},
|
||||
timer: timer,
|
||||
}
|
||||
}
|
||||
|
||||
func (d *delayWriter) Write(p []byte) (n int, err error) {
|
||||
if d.buf != nil {
|
||||
select {
|
||||
case <-d.timer.C:
|
||||
_, err := d.internal.Write(d.buf.Bytes())
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
d.buf = nil
|
||||
return d.internal.Write(p)
|
||||
default:
|
||||
return d.buf.Write(p)
|
||||
}
|
||||
}
|
||||
return d.internal.Write(p)
|
||||
}
|
||||
|
||||
func (d *delayWriter) WriteString(s string) (n int, err error) {
|
||||
if d.buf != nil {
|
||||
select {
|
||||
case <-d.timer.C:
|
||||
_, err := d.internal.Write(d.buf.Bytes())
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
d.buf = nil
|
||||
return d.internal.Write([]byte(s))
|
||||
default:
|
||||
return d.buf.WriteString(s)
|
||||
}
|
||||
}
|
||||
return d.internal.Write([]byte(s))
|
||||
}
|
||||
|
||||
func (d *delayWriter) Close() error {
|
||||
if d == nil {
|
||||
return nil
|
||||
}
|
||||
stopped := d.timer.Stop()
|
||||
if stopped {
|
||||
return nil
|
||||
}
|
||||
select {
|
||||
case <-d.timer.C:
|
||||
default:
|
||||
}
|
||||
if d.buf == nil {
|
||||
return nil
|
||||
}
|
||||
_, err := d.internal.Write(d.buf.Bytes())
|
||||
d.buf = nil
|
||||
return err
|
||||
}
|
||||
|
||||
type nilWriter struct{}
|
||||
|
||||
func (n *nilWriter) Write(p []byte) (int, error) {
|
||||
return len(p), nil
|
||||
}
|
||||
|
||||
func (n *nilWriter) WriteString(s string) (int, error) {
|
||||
return len(s), nil
|
||||
}
|
||||
|
||||
func runHookPreReceive(c *cli.Context) error {
|
||||
if len(os.Getenv("SSH_ORIGINAL_COMMAND")) == 0 {
|
||||
if os.Getenv(models.EnvIsInternal) == "true" {
|
||||
return nil
|
||||
}
|
||||
|
||||
setup("hooks/pre-receive.log")
|
||||
setup("hooks/pre-receive.log", false)
|
||||
|
||||
if len(os.Getenv("SSH_ORIGINAL_COMMAND")) == 0 {
|
||||
if setting.OnlyAllowPushIfGiteaEnvironmentSet {
|
||||
fail(`Rejecting changes as Gitea environment not set.
|
||||
If you are pushing over SSH you must push with a key managed by
|
||||
Gitea or set your environment appropriately.`, "")
|
||||
} else {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
|
||||
// the environment setted on serv command
|
||||
isWiki := (os.Getenv(models.EnvRepoIsWiki) == "true")
|
||||
@@ -66,13 +162,39 @@ func runHookPreReceive(c *cli.Context) error {
|
||||
reponame := os.Getenv(models.EnvRepoName)
|
||||
userID, _ := strconv.ParseInt(os.Getenv(models.EnvPusherID), 10, 64)
|
||||
prID, _ := strconv.ParseInt(os.Getenv(models.ProtectedBranchPRID), 10, 64)
|
||||
isDeployKey, _ := strconv.ParseBool(os.Getenv(models.EnvIsDeployKey))
|
||||
|
||||
hookOptions := private.HookOptions{
|
||||
UserID: userID,
|
||||
GitAlternativeObjectDirectories: os.Getenv(private.GitAlternativeObjectDirectories),
|
||||
GitObjectDirectory: os.Getenv(private.GitObjectDirectory),
|
||||
GitQuarantinePath: os.Getenv(private.GitQuarantinePath),
|
||||
ProtectedBranchID: prID,
|
||||
IsDeployKey: isDeployKey,
|
||||
}
|
||||
|
||||
buf := bytes.NewBuffer(nil)
|
||||
scanner := bufio.NewScanner(os.Stdin)
|
||||
for scanner.Scan() {
|
||||
buf.Write(scanner.Bytes())
|
||||
buf.WriteByte('\n')
|
||||
|
||||
oldCommitIDs := make([]string, hookBatchSize)
|
||||
newCommitIDs := make([]string, hookBatchSize)
|
||||
refFullNames := make([]string, hookBatchSize)
|
||||
count := 0
|
||||
total := 0
|
||||
lastline := 0
|
||||
|
||||
var out io.Writer
|
||||
out = &nilWriter{}
|
||||
if setting.Git.VerbosePush {
|
||||
if setting.Git.VerbosePushDelay > 0 {
|
||||
dWriter := newDelayWriter(os.Stdout, setting.Git.VerbosePushDelay)
|
||||
defer dWriter.Close()
|
||||
out = dWriter
|
||||
} else {
|
||||
out = os.Stdout
|
||||
}
|
||||
}
|
||||
|
||||
for scanner.Scan() {
|
||||
// TODO: support news feeds for wiki
|
||||
if isWiki {
|
||||
continue
|
||||
@@ -86,47 +208,101 @@ func runHookPreReceive(c *cli.Context) error {
|
||||
oldCommitID := string(fields[0])
|
||||
newCommitID := string(fields[1])
|
||||
refFullName := string(fields[2])
|
||||
total++
|
||||
lastline++
|
||||
|
||||
// If the ref is a branch, check if it's protected
|
||||
if strings.HasPrefix(refFullName, git.BranchPrefix) {
|
||||
statusCode, msg := private.HookPreReceive(username, reponame, private.HookOptions{
|
||||
OldCommitID: oldCommitID,
|
||||
NewCommitID: newCommitID,
|
||||
RefFullName: refFullName,
|
||||
UserID: userID,
|
||||
GitAlternativeObjectDirectories: os.Getenv(private.GitAlternativeObjectDirectories),
|
||||
GitObjectDirectory: os.Getenv(private.GitObjectDirectory),
|
||||
GitQuarantinePath: os.Getenv(private.GitQuarantinePath),
|
||||
ProtectedBranchID: prID,
|
||||
})
|
||||
switch statusCode {
|
||||
case http.StatusInternalServerError:
|
||||
fail("Internal Server Error", msg)
|
||||
case http.StatusForbidden:
|
||||
fail(msg, "")
|
||||
oldCommitIDs[count] = oldCommitID
|
||||
newCommitIDs[count] = newCommitID
|
||||
refFullNames[count] = refFullName
|
||||
count++
|
||||
fmt.Fprintf(out, "*")
|
||||
|
||||
if count >= hookBatchSize {
|
||||
fmt.Fprintf(out, " Checking %d branches\n", count)
|
||||
|
||||
hookOptions.OldCommitIDs = oldCommitIDs
|
||||
hookOptions.NewCommitIDs = newCommitIDs
|
||||
hookOptions.RefFullNames = refFullNames
|
||||
statusCode, msg := private.HookPreReceive(username, reponame, hookOptions)
|
||||
switch statusCode {
|
||||
case http.StatusOK:
|
||||
// no-op
|
||||
case http.StatusInternalServerError:
|
||||
fail("Internal Server Error", msg)
|
||||
default:
|
||||
fail(msg, "")
|
||||
}
|
||||
count = 0
|
||||
lastline = 0
|
||||
}
|
||||
} else {
|
||||
fmt.Fprintf(out, ".")
|
||||
}
|
||||
if lastline >= hookBatchSize {
|
||||
fmt.Fprintf(out, "\n")
|
||||
lastline = 0
|
||||
}
|
||||
}
|
||||
|
||||
if count > 0 {
|
||||
hookOptions.OldCommitIDs = oldCommitIDs[:count]
|
||||
hookOptions.NewCommitIDs = newCommitIDs[:count]
|
||||
hookOptions.RefFullNames = refFullNames[:count]
|
||||
|
||||
fmt.Fprintf(out, " Checking %d branches\n", count)
|
||||
|
||||
statusCode, msg := private.HookPreReceive(username, reponame, hookOptions)
|
||||
switch statusCode {
|
||||
case http.StatusInternalServerError:
|
||||
fail("Internal Server Error", msg)
|
||||
case http.StatusForbidden:
|
||||
fail(msg, "")
|
||||
}
|
||||
} else if lastline > 0 {
|
||||
fmt.Fprintf(out, "\n")
|
||||
lastline = 0
|
||||
}
|
||||
|
||||
fmt.Fprintf(out, "Checked %d references in total\n", total)
|
||||
return nil
|
||||
}
|
||||
|
||||
func runHookUpdate(c *cli.Context) error {
|
||||
if len(os.Getenv("SSH_ORIGINAL_COMMAND")) == 0 {
|
||||
return nil
|
||||
}
|
||||
|
||||
setup("hooks/update.log")
|
||||
|
||||
// Update is empty and is kept only for backwards compatibility
|
||||
return nil
|
||||
}
|
||||
|
||||
func runHookPostReceive(c *cli.Context) error {
|
||||
if len(os.Getenv("SSH_ORIGINAL_COMMAND")) == 0 {
|
||||
if os.Getenv(models.EnvIsInternal) == "true" {
|
||||
return nil
|
||||
}
|
||||
|
||||
setup("hooks/post-receive.log")
|
||||
setup("hooks/post-receive.log", false)
|
||||
|
||||
if len(os.Getenv("SSH_ORIGINAL_COMMAND")) == 0 {
|
||||
if setting.OnlyAllowPushIfGiteaEnvironmentSet {
|
||||
fail(`Rejecting changes as Gitea environment not set.
|
||||
If you are pushing over SSH you must push with a key managed by
|
||||
Gitea or set your environment appropriately.`, "")
|
||||
} else {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
|
||||
var out io.Writer
|
||||
var dWriter *delayWriter
|
||||
out = &nilWriter{}
|
||||
if setting.Git.VerbosePush {
|
||||
if setting.Git.VerbosePushDelay > 0 {
|
||||
dWriter = newDelayWriter(os.Stdout, setting.Git.VerbosePushDelay)
|
||||
defer dWriter.Close()
|
||||
out = dWriter
|
||||
} else {
|
||||
out = os.Stdout
|
||||
}
|
||||
}
|
||||
|
||||
// the environment setted on serv command
|
||||
repoUser := os.Getenv(models.EnvRepoUsername)
|
||||
@@ -135,12 +311,24 @@ func runHookPostReceive(c *cli.Context) error {
|
||||
pusherID, _ := strconv.ParseInt(os.Getenv(models.EnvPusherID), 10, 64)
|
||||
pusherName := os.Getenv(models.EnvPusherName)
|
||||
|
||||
buf := bytes.NewBuffer(nil)
|
||||
hookOptions := private.HookOptions{
|
||||
UserName: pusherName,
|
||||
UserID: pusherID,
|
||||
GitAlternativeObjectDirectories: os.Getenv(private.GitAlternativeObjectDirectories),
|
||||
GitObjectDirectory: os.Getenv(private.GitObjectDirectory),
|
||||
GitQuarantinePath: os.Getenv(private.GitQuarantinePath),
|
||||
}
|
||||
oldCommitIDs := make([]string, hookBatchSize)
|
||||
newCommitIDs := make([]string, hookBatchSize)
|
||||
refFullNames := make([]string, hookBatchSize)
|
||||
count := 0
|
||||
total := 0
|
||||
wasEmpty := false
|
||||
masterPushed := false
|
||||
results := make([]private.HookPostReceiveBranchResult, 0)
|
||||
|
||||
scanner := bufio.NewScanner(os.Stdin)
|
||||
for scanner.Scan() {
|
||||
buf.Write(scanner.Bytes())
|
||||
buf.WriteByte('\n')
|
||||
|
||||
// TODO: support news feeds for wiki
|
||||
if isWiki {
|
||||
continue
|
||||
@@ -151,36 +339,93 @@ func runHookPostReceive(c *cli.Context) error {
|
||||
continue
|
||||
}
|
||||
|
||||
oldCommitID := string(fields[0])
|
||||
newCommitID := string(fields[1])
|
||||
refFullName := string(fields[2])
|
||||
|
||||
res, err := private.HookPostReceive(repoUser, repoName, private.HookOptions{
|
||||
OldCommitID: oldCommitID,
|
||||
NewCommitID: newCommitID,
|
||||
RefFullName: refFullName,
|
||||
UserID: pusherID,
|
||||
UserName: pusherName,
|
||||
})
|
||||
|
||||
if res == nil {
|
||||
fail("Internal Server Error", err)
|
||||
fmt.Fprintf(out, ".")
|
||||
oldCommitIDs[count] = string(fields[0])
|
||||
newCommitIDs[count] = string(fields[1])
|
||||
refFullNames[count] = string(fields[2])
|
||||
if refFullNames[count] == git.BranchPrefix+"master" && newCommitIDs[count] != git.EmptySHA && count == total {
|
||||
masterPushed = true
|
||||
}
|
||||
count++
|
||||
total++
|
||||
|
||||
if res["message"] == false {
|
||||
if count >= hookBatchSize {
|
||||
fmt.Fprintf(out, " Processing %d references\n", count)
|
||||
hookOptions.OldCommitIDs = oldCommitIDs
|
||||
hookOptions.NewCommitIDs = newCommitIDs
|
||||
hookOptions.RefFullNames = refFullNames
|
||||
resp, err := private.HookPostReceive(repoUser, repoName, hookOptions)
|
||||
if resp == nil {
|
||||
_ = dWriter.Close()
|
||||
hookPrintResults(results)
|
||||
fail("Internal Server Error", err)
|
||||
}
|
||||
wasEmpty = wasEmpty || resp.RepoWasEmpty
|
||||
results = append(results, resp.Results...)
|
||||
count = 0
|
||||
}
|
||||
}
|
||||
|
||||
if count == 0 {
|
||||
if wasEmpty && masterPushed {
|
||||
// We need to tell the repo to reset the default branch to master
|
||||
err := private.SetDefaultBranch(repoUser, repoName, "master")
|
||||
if err != nil {
|
||||
fail("Internal Server Error", "SetDefaultBranch failed with Error: %v", err)
|
||||
}
|
||||
}
|
||||
fmt.Fprintf(out, "Processed %d references in total\n", total)
|
||||
|
||||
_ = dWriter.Close()
|
||||
hookPrintResults(results)
|
||||
return nil
|
||||
}
|
||||
|
||||
hookOptions.OldCommitIDs = oldCommitIDs[:count]
|
||||
hookOptions.NewCommitIDs = newCommitIDs[:count]
|
||||
hookOptions.RefFullNames = refFullNames[:count]
|
||||
|
||||
fmt.Fprintf(out, " Processing %d references\n", count)
|
||||
|
||||
resp, err := private.HookPostReceive(repoUser, repoName, hookOptions)
|
||||
if resp == nil {
|
||||
_ = dWriter.Close()
|
||||
hookPrintResults(results)
|
||||
fail("Internal Server Error", err)
|
||||
}
|
||||
wasEmpty = wasEmpty || resp.RepoWasEmpty
|
||||
results = append(results, resp.Results...)
|
||||
|
||||
fmt.Fprintf(out, "Processed %d references in total\n", total)
|
||||
|
||||
if wasEmpty && masterPushed {
|
||||
// We need to tell the repo to reset the default branch to master
|
||||
err := private.SetDefaultBranch(repoUser, repoName, "master")
|
||||
if err != nil {
|
||||
fail("Internal Server Error", "SetDefaultBranch failed with Error: %v", err)
|
||||
}
|
||||
}
|
||||
_ = dWriter.Close()
|
||||
hookPrintResults(results)
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func hookPrintResults(results []private.HookPostReceiveBranchResult) {
|
||||
for _, res := range results {
|
||||
if !res.Message {
|
||||
continue
|
||||
}
|
||||
|
||||
fmt.Fprintln(os.Stderr, "")
|
||||
if res["create"] == true {
|
||||
fmt.Fprintf(os.Stderr, "Create a new pull request for '%s':\n", res["branch"])
|
||||
fmt.Fprintf(os.Stderr, " %s\n", res["url"])
|
||||
if res.Create {
|
||||
fmt.Fprintf(os.Stderr, "Create a new pull request for '%s':\n", res.Branch)
|
||||
fmt.Fprintf(os.Stderr, " %s\n", res.URL)
|
||||
} else {
|
||||
fmt.Fprint(os.Stderr, "Visit the existing pull request:\n")
|
||||
fmt.Fprintf(os.Stderr, " %s\n", res["url"])
|
||||
fmt.Fprintf(os.Stderr, " %s\n", res.URL)
|
||||
}
|
||||
fmt.Fprintln(os.Stderr, "")
|
||||
os.Stderr.Sync()
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
10
cmd/keys.go
10
cmd/keys.go
@@ -9,7 +9,7 @@ import (
|
||||
"fmt"
|
||||
"strings"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
"code.gitea.io/gitea/modules/private"
|
||||
|
||||
"github.com/urfave/cli"
|
||||
)
|
||||
@@ -62,14 +62,12 @@ func runKeys(c *cli.Context) error {
|
||||
return errors.New("No key type and content provided")
|
||||
}
|
||||
|
||||
if err := initDBDisableConsole(true); err != nil {
|
||||
return err
|
||||
}
|
||||
setup("keys.log", false)
|
||||
|
||||
publicKey, err := models.SearchPublicKeyByContent(content)
|
||||
authorizedString, err := private.AuthorizedPublicKeyByContent(content)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
fmt.Println(publicKey.AuthorizedString())
|
||||
fmt.Println(strings.TrimSpace(authorizedString))
|
||||
return nil
|
||||
}
|
||||
|
@@ -5,6 +5,8 @@
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
"code.gitea.io/gitea/models/migrations"
|
||||
"code.gitea.io/gitea/modules/log"
|
||||
@@ -32,7 +34,7 @@ func runMigrate(ctx *cli.Context) error {
|
||||
log.Trace("Log path: %s", setting.LogRootPath)
|
||||
setting.InitDBConfig()
|
||||
|
||||
if err := models.NewEngine(migrations.Migrate); err != nil {
|
||||
if err := models.NewEngine(context.Background(), migrations.Migrate); err != nil {
|
||||
log.Fatal("Failed to initialize ORM engine: %v", err)
|
||||
return err
|
||||
}
|
||||
|
22
cmd/serv.go
22
cmd/serv.go
@@ -12,6 +12,7 @@ import (
|
||||
"net/url"
|
||||
"os"
|
||||
"os/exec"
|
||||
"regexp"
|
||||
"strconv"
|
||||
"strings"
|
||||
"time"
|
||||
@@ -41,12 +42,20 @@ var CmdServ = cli.Command{
|
||||
cli.BoolFlag{
|
||||
Name: "enable-pprof",
|
||||
},
|
||||
cli.BoolFlag{
|
||||
Name: "debug",
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
func setup(logPath string) {
|
||||
_ = log.DelLogger("console")
|
||||
func setup(logPath string, debug bool) {
|
||||
if !debug {
|
||||
_ = log.DelLogger("console")
|
||||
}
|
||||
setting.NewContext()
|
||||
if debug {
|
||||
setting.ProdMode = false
|
||||
}
|
||||
}
|
||||
|
||||
func parseCmd(cmd string) (string, string) {
|
||||
@@ -64,6 +73,7 @@ var (
|
||||
"git-receive-pack": models.AccessModeWrite,
|
||||
lfsAuthenticateVerb: models.AccessModeNone,
|
||||
}
|
||||
alphaDashDotPattern = regexp.MustCompile(`[^\w-\.]`)
|
||||
)
|
||||
|
||||
func fail(userMessage, logMessage string, args ...interface{}) {
|
||||
@@ -80,7 +90,7 @@ func fail(userMessage, logMessage string, args ...interface{}) {
|
||||
|
||||
func runServ(c *cli.Context) error {
|
||||
// FIXME: This needs to internationalised
|
||||
setup("serv.log")
|
||||
setup("serv.log", c.Bool("debug"))
|
||||
|
||||
if setting.SSH.Disabled {
|
||||
println("Gitea: SSH has been disabled")
|
||||
@@ -139,6 +149,10 @@ func runServ(c *cli.Context) error {
|
||||
username := strings.ToLower(rr[0])
|
||||
reponame := strings.ToLower(strings.TrimSuffix(rr[1], ".git"))
|
||||
|
||||
if alphaDashDotPattern.MatchString(reponame) {
|
||||
fail("Invalid repo name", "Invalid repo name: %s", reponame)
|
||||
}
|
||||
|
||||
if setting.EnablePprof || c.Bool("enable-pprof") {
|
||||
if err := os.MkdirAll(setting.PprofDataPath, os.ModePerm); err != nil {
|
||||
fail("Error while trying to create PPROF_DATA_PATH", "Error while trying to create PPROF_DATA_PATH: %v", err)
|
||||
@@ -191,6 +205,8 @@ func runServ(c *cli.Context) error {
|
||||
os.Setenv(models.EnvPusherID, strconv.FormatInt(results.UserID, 10))
|
||||
os.Setenv(models.ProtectedBranchRepoID, strconv.FormatInt(results.RepoID, 10))
|
||||
os.Setenv(models.ProtectedBranchPRID, fmt.Sprintf("%d", 0))
|
||||
os.Setenv(models.EnvIsDeployKey, fmt.Sprintf("%t", results.IsDeployKey))
|
||||
os.Setenv(models.EnvKeyID, fmt.Sprintf("%d", results.KeyID))
|
||||
|
||||
//LFS token authentication
|
||||
if verb == lfsAuthenticateVerb {
|
||||
|
81
cmd/web.go
81
cmd/web.go
@@ -5,14 +5,14 @@
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"net"
|
||||
"net/http"
|
||||
"net/http/fcgi"
|
||||
_ "net/http/pprof" // Used for debugging if enabled and a web server is running
|
||||
"os"
|
||||
"strings"
|
||||
|
||||
"code.gitea.io/gitea/modules/graceful"
|
||||
"code.gitea.io/gitea/modules/log"
|
||||
"code.gitea.io/gitea/modules/setting"
|
||||
"code.gitea.io/gitea/routers"
|
||||
@@ -59,7 +59,7 @@ func runHTTPRedirector() {
|
||||
http.Redirect(w, r, target, http.StatusTemporaryRedirect)
|
||||
})
|
||||
|
||||
var err = runHTTP(source, context2.ClearHandler(handler))
|
||||
var err = runHTTP("tcp", source, context2.ClearHandler(handler))
|
||||
|
||||
if err != nil {
|
||||
log.Fatal("Failed to start port redirection: %v", err)
|
||||
@@ -75,17 +75,13 @@ func runLetsEncrypt(listenAddr, domain, directory, email string, m http.Handler)
|
||||
}
|
||||
go func() {
|
||||
log.Info("Running Let's Encrypt handler on %s", setting.HTTPAddr+":"+setting.PortToRedirect)
|
||||
var err = http.ListenAndServe(setting.HTTPAddr+":"+setting.PortToRedirect, certManager.HTTPHandler(http.HandlerFunc(runLetsEncryptFallbackHandler))) // all traffic coming into HTTP will be redirect to HTTPS automatically (LE HTTP-01 validation happens here)
|
||||
// all traffic coming into HTTP will be redirect to HTTPS automatically (LE HTTP-01 validation happens here)
|
||||
var err = runHTTP("tcp", setting.HTTPAddr+":"+setting.PortToRedirect, certManager.HTTPHandler(http.HandlerFunc(runLetsEncryptFallbackHandler)))
|
||||
if err != nil {
|
||||
log.Fatal("Failed to start the Let's Encrypt handler on port %s: %v", setting.PortToRedirect, err)
|
||||
}
|
||||
}()
|
||||
server := &http.Server{
|
||||
Addr: listenAddr,
|
||||
Handler: m,
|
||||
TLSConfig: certManager.TLSConfig(),
|
||||
}
|
||||
return server.ListenAndServeTLS("", "")
|
||||
return runHTTPSWithTLSConfig("tcp", listenAddr, certManager.TLSConfig(), context2.ClearHandler(m))
|
||||
}
|
||||
|
||||
func runLetsEncryptFallbackHandler(w http.ResponseWriter, r *http.Request) {
|
||||
@@ -101,12 +97,25 @@ func runLetsEncryptFallbackHandler(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
|
||||
func runWeb(ctx *cli.Context) error {
|
||||
managerCtx, cancel := context.WithCancel(context.Background())
|
||||
graceful.InitManager(managerCtx)
|
||||
defer cancel()
|
||||
|
||||
if os.Getppid() > 1 && len(os.Getenv("LISTEN_FDS")) > 0 {
|
||||
log.Info("Restarting Gitea on PID: %d from parent PID: %d", os.Getpid(), os.Getppid())
|
||||
} else {
|
||||
log.Info("Starting Gitea on PID: %d", os.Getpid())
|
||||
}
|
||||
|
||||
// Set pid file setting
|
||||
if ctx.IsSet("pid") {
|
||||
setting.CustomPID = ctx.String("pid")
|
||||
}
|
||||
|
||||
routers.GlobalInit()
|
||||
// Perform global initialization
|
||||
routers.GlobalInit(graceful.GetManager().HammerContext())
|
||||
|
||||
// Set up Macaron
|
||||
m := routes.NewMacaron()
|
||||
routes.RegisterRoutes(m)
|
||||
|
||||
@@ -118,6 +127,7 @@ func runWeb(ctx *cli.Context) error {
|
||||
switch setting.Protocol {
|
||||
case setting.UnixSocket:
|
||||
case setting.FCGI:
|
||||
case setting.FCGIUnix:
|
||||
default:
|
||||
// Save LOCAL_ROOT_URL if port changed
|
||||
cfg := ini.Empty()
|
||||
@@ -145,7 +155,7 @@ func runWeb(ctx *cli.Context) error {
|
||||
}
|
||||
|
||||
listenAddr := setting.HTTPAddr
|
||||
if setting.Protocol != setting.UnixSocket {
|
||||
if setting.Protocol != setting.UnixSocket && setting.Protocol != setting.FCGIUnix {
|
||||
listenAddr += ":" + setting.HTTPPort
|
||||
}
|
||||
log.Info("Listen: %v://%s%s", setting.Protocol, listenAddr, setting.AppSubURL)
|
||||
@@ -164,7 +174,8 @@ func runWeb(ctx *cli.Context) error {
|
||||
var err error
|
||||
switch setting.Protocol {
|
||||
case setting.HTTP:
|
||||
err = runHTTP(listenAddr, context2.ClearHandler(m))
|
||||
NoHTTPRedirector()
|
||||
err = runHTTP("tcp", listenAddr, context2.ClearHandler(m))
|
||||
case setting.HTTPS:
|
||||
if setting.EnableLetsEncrypt {
|
||||
err = runLetsEncrypt(listenAddr, setting.Domain, setting.LetsEncryptDirectory, setting.LetsEncryptEmail, context2.ClearHandler(m))
|
||||
@@ -172,43 +183,29 @@ func runWeb(ctx *cli.Context) error {
|
||||
}
|
||||
if setting.RedirectOtherPort {
|
||||
go runHTTPRedirector()
|
||||
} else {
|
||||
NoHTTPRedirector()
|
||||
}
|
||||
err = runHTTPS(listenAddr, setting.CertFile, setting.KeyFile, context2.ClearHandler(m))
|
||||
err = runHTTPS("tcp", listenAddr, setting.CertFile, setting.KeyFile, context2.ClearHandler(m))
|
||||
case setting.FCGI:
|
||||
var listener net.Listener
|
||||
listener, err = net.Listen("tcp", listenAddr)
|
||||
if err != nil {
|
||||
log.Fatal("Failed to bind %s: %v", listenAddr, err)
|
||||
}
|
||||
defer func() {
|
||||
if err := listener.Close(); err != nil {
|
||||
log.Fatal("Failed to stop server: %v", err)
|
||||
}
|
||||
}()
|
||||
err = fcgi.Serve(listener, context2.ClearHandler(m))
|
||||
NoHTTPRedirector()
|
||||
err = runFCGI("tcp", listenAddr, context2.ClearHandler(m))
|
||||
case setting.UnixSocket:
|
||||
if err := os.Remove(listenAddr); err != nil && !os.IsNotExist(err) {
|
||||
log.Fatal("Failed to remove unix socket directory %s: %v", listenAddr, err)
|
||||
}
|
||||
var listener *net.UnixListener
|
||||
listener, err = net.ListenUnix("unix", &net.UnixAddr{Name: listenAddr, Net: "unix"})
|
||||
if err != nil {
|
||||
break // Handle error after switch
|
||||
}
|
||||
|
||||
// FIXME: add proper implementation of signal capture on all protocols
|
||||
// execute this on SIGTERM or SIGINT: listener.Close()
|
||||
if err = os.Chmod(listenAddr, os.FileMode(setting.UnixSocketPermission)); err != nil {
|
||||
log.Fatal("Failed to set permission of unix socket: %v", err)
|
||||
}
|
||||
err = http.Serve(listener, context2.ClearHandler(m))
|
||||
NoHTTPRedirector()
|
||||
err = runHTTP("unix", listenAddr, context2.ClearHandler(m))
|
||||
case setting.FCGIUnix:
|
||||
NoHTTPRedirector()
|
||||
err = runFCGI("unix", listenAddr, context2.ClearHandler(m))
|
||||
default:
|
||||
log.Fatal("Invalid protocol: %s", setting.Protocol)
|
||||
}
|
||||
|
||||
if err != nil {
|
||||
log.Fatal("Failed to start server: %v", err)
|
||||
log.Critical("Failed to start server: %v", err)
|
||||
}
|
||||
|
||||
log.Info("HTTP Listener: %s Closed", listenAddr)
|
||||
<-graceful.GetManager().Done()
|
||||
log.Info("PID: %d Gitea Web Finished", os.Getpid())
|
||||
log.Close()
|
||||
return nil
|
||||
}
|
||||
|
@@ -1,5 +1,3 @@
|
||||
// +build !windows
|
||||
|
||||
// Copyright 2016 The Gitea Authors. All rights reserved.
|
||||
// Use of this source code is governed by a MIT-style
|
||||
// license that can be found in the LICENSE file.
|
||||
@@ -8,38 +6,47 @@ package cmd
|
||||
|
||||
import (
|
||||
"crypto/tls"
|
||||
"net"
|
||||
"net/http"
|
||||
"net/http/fcgi"
|
||||
|
||||
"code.gitea.io/gitea/modules/graceful"
|
||||
"code.gitea.io/gitea/modules/log"
|
||||
|
||||
"github.com/facebookgo/grace/gracehttp"
|
||||
)
|
||||
|
||||
func runHTTP(listenAddr string, m http.Handler) error {
|
||||
return gracehttp.Serve(&http.Server{
|
||||
Addr: listenAddr,
|
||||
Handler: m,
|
||||
})
|
||||
func runHTTP(network, listenAddr string, m http.Handler) error {
|
||||
return graceful.HTTPListenAndServe(network, listenAddr, m)
|
||||
}
|
||||
|
||||
func runHTTPS(listenAddr, certFile, keyFile string, m http.Handler) error {
|
||||
config := &tls.Config{
|
||||
MinVersion: tls.VersionTLS10,
|
||||
}
|
||||
if config.NextProtos == nil {
|
||||
config.NextProtos = []string{"http/1.1"}
|
||||
}
|
||||
func runHTTPS(network, listenAddr, certFile, keyFile string, m http.Handler) error {
|
||||
return graceful.HTTPListenAndServeTLS(network, listenAddr, certFile, keyFile, m)
|
||||
}
|
||||
|
||||
config.Certificates = make([]tls.Certificate, 1)
|
||||
var err error
|
||||
config.Certificates[0], err = tls.LoadX509KeyPair(certFile, keyFile)
|
||||
func runHTTPSWithTLSConfig(network, listenAddr string, tlsConfig *tls.Config, m http.Handler) error {
|
||||
return graceful.HTTPListenAndServeTLSConfig(network, listenAddr, tlsConfig, m)
|
||||
}
|
||||
|
||||
// NoHTTPRedirector tells our cleanup routine that we will not be using a fallback http redirector
|
||||
func NoHTTPRedirector() {
|
||||
graceful.GetManager().InformCleanup()
|
||||
}
|
||||
|
||||
// NoMainListener tells our cleanup routine that we will not be using a possibly provided listener
|
||||
// for our main HTTP/HTTPS service
|
||||
func NoMainListener() {
|
||||
graceful.GetManager().InformCleanup()
|
||||
}
|
||||
|
||||
func runFCGI(network, listenAddr string, m http.Handler) error {
|
||||
// This needs to handle stdin as fcgi point
|
||||
fcgiServer := graceful.NewServer(network, listenAddr)
|
||||
|
||||
err := fcgiServer.ListenAndServe(func(listener net.Listener) error {
|
||||
return fcgi.Serve(listener, m)
|
||||
})
|
||||
if err != nil {
|
||||
log.Fatal("Failed to load https cert file %s: %v", listenAddr, err)
|
||||
log.Fatal("Failed to start FCGI main server: %v", err)
|
||||
}
|
||||
|
||||
return gracehttp.Serve(&http.Server{
|
||||
Addr: listenAddr,
|
||||
Handler: m,
|
||||
TLSConfig: config,
|
||||
})
|
||||
log.Info("FCGI Listener: %s Closed", listenAddr)
|
||||
return err
|
||||
}
|
||||
|
@@ -1,19 +0,0 @@
|
||||
// +build windows
|
||||
|
||||
// Copyright 2016 The Gitea Authors. All rights reserved.
|
||||
// Use of this source code is governed by a MIT-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func runHTTP(listenAddr string, m http.Handler) error {
|
||||
return http.ListenAndServe(listenAddr, m)
|
||||
}
|
||||
|
||||
func runHTTPS(listenAddr, certFile, keyFile string, m http.Handler) error {
|
||||
return http.ListenAndServeTLS(listenAddr, certFile, keyFile, m)
|
||||
}
|
66
contrib/environment-to-ini/README
Normal file
66
contrib/environment-to-ini/README
Normal file
@@ -0,0 +1,66 @@
|
||||
Environment To Ini
|
||||
==================
|
||||
|
||||
Multiple docker users have requested that the Gitea docker is changed
|
||||
to permit arbitrary configuration via environment variables.
|
||||
|
||||
Gitea needs to use an ini file for configuration because the running
|
||||
environment that starts the docker may not be the same as that used
|
||||
by the hooks. An ini file also gives a good default and means that
|
||||
users do not have to completely provide a full environment.
|
||||
|
||||
With those caveats above, this command provides a generic way of
|
||||
converting suitably structured environment variables into any ini
|
||||
value.
|
||||
|
||||
To use the command is very simple just run it and the default gitea
|
||||
app.ini will be rewritten to take account of the variables provided,
|
||||
however there are various options to give slightly different
|
||||
behavior and these can be interrogated with the `-h` option.
|
||||
|
||||
The environment variables should be of the form:
|
||||
|
||||
GITEA__SECTION_NAME__KEY_NAME
|
||||
|
||||
Environment variables are usually restricted to a reduced character
|
||||
set "0-9A-Z_" - in order to allow the setting of sections with
|
||||
characters outside of that set, they should be escaped as following:
|
||||
"_0X2E_" for ".". The entire section and key names can be escaped as
|
||||
a UTF8 byte string if necessary. E.g. to configure:
|
||||
|
||||
"""
|
||||
...
|
||||
[log.console]
|
||||
COLORIZE=false
|
||||
STDERR=true
|
||||
...
|
||||
"""
|
||||
|
||||
You would set the environment variables: "GITEA__LOG_0x2E_CONSOLE__COLORIZE=false"
|
||||
and "GITEA__LOG_0x2E_CONSOLE__STDERR=false". Other examples can be found
|
||||
on the configuration cheat sheet.
|
||||
|
||||
To plug this command in to the docker, you simply compile the provided go file using:
|
||||
|
||||
go build environment-to-ini.go
|
||||
|
||||
And copy the resulting `environment-to-ini` command to /app/gitea in the docker.
|
||||
|
||||
Apply the below patch to /etc/s6/gitea.setup to wire this in.
|
||||
|
||||
If you find this useful please comment on #7287
|
||||
|
||||
|
||||
diff --git a/docker/root/etc/s6/gitea/setup b/docker/root/etc/s6/gitea/setup
|
||||
index f87ce9115..565bfcba9 100755
|
||||
--- a/docker/root/etc/s6/gitea/setup
|
||||
+++ b/docker/root/etc/s6/gitea/setup
|
||||
@@ -44,6 +44,8 @@ if [ ! -f ${GITEA_CUSTOM}/conf/app.ini ]; then
|
||||
SECRET_KEY=${SECRET_KEY:-""} \
|
||||
envsubst < /etc/templates/app.ini > ${GITEA_CUSTOM}/conf/app.ini
|
||||
|
||||
+ /app/gitea/environment-to-ini -c ${GITEA_CUSTOM}/conf/app.ini
|
||||
+
|
||||
chown ${USER}:git ${GITEA_CUSTOM}/conf/app.ini
|
||||
fi
|
||||
|
224
contrib/environment-to-ini/environment-to-ini.go
Normal file
224
contrib/environment-to-ini/environment-to-ini.go
Normal file
@@ -0,0 +1,224 @@
|
||||
// Copyright 2019 The Gitea Authors. All rights reserved.
|
||||
// Use of this source code is governed by a MIT-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package main
|
||||
|
||||
import (
|
||||
"os"
|
||||
"regexp"
|
||||
"strconv"
|
||||
"strings"
|
||||
|
||||
"code.gitea.io/gitea/modules/log"
|
||||
"code.gitea.io/gitea/modules/setting"
|
||||
|
||||
"github.com/unknwon/com"
|
||||
"github.com/urfave/cli"
|
||||
ini "gopkg.in/ini.v1"
|
||||
)
|
||||
|
||||
// EnvironmentPrefix environment variables prefixed with this represent ini values to write
|
||||
const EnvironmentPrefix = "GITEA"
|
||||
|
||||
func main() {
|
||||
app := cli.NewApp()
|
||||
app.Name = "environment-to-ini"
|
||||
app.Usage = "Use provided environment to update configuration ini"
|
||||
app.Description = `As a helper to allow docker users to update the gitea configuration
|
||||
through the environment, this command allows environment variables to
|
||||
be mapped to values in the ini.
|
||||
|
||||
Environment variables of the form "GITEA__SECTION_NAME__KEY_NAME"
|
||||
will be mapped to the ini section "[section_name]" and the key
|
||||
"KEY_NAME" with the value as provided.
|
||||
|
||||
Environment variables are usually restricted to a reduced character
|
||||
set "0-9A-Z_" - in order to allow the setting of sections with
|
||||
characters outside of that set, they should be escaped as following:
|
||||
"_0X2E_" for ".". The entire section and key names can be escaped as
|
||||
a UTF8 byte string if necessary. E.g. to configure:
|
||||
|
||||
"""
|
||||
...
|
||||
[log.console]
|
||||
COLORIZE=false
|
||||
STDERR=true
|
||||
...
|
||||
"""
|
||||
|
||||
You would set the environment variables: "GITEA__LOG_0x2E_CONSOLE__COLORIZE=false"
|
||||
and "GITEA__LOG_0x2E_CONSOLE__STDERR=false". Other examples can be found
|
||||
on the configuration cheat sheet.`
|
||||
app.Flags = []cli.Flag{
|
||||
cli.StringFlag{
|
||||
Name: "custom-path, C",
|
||||
Value: setting.CustomPath,
|
||||
Usage: "Custom path file path",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "config, c",
|
||||
Value: setting.CustomConf,
|
||||
Usage: "Custom configuration file path",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "work-path, w",
|
||||
Value: setting.AppWorkPath,
|
||||
Usage: "Set the gitea working path",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "out, o",
|
||||
Value: "",
|
||||
Usage: "Destination file to write to",
|
||||
},
|
||||
cli.BoolFlag{
|
||||
Name: "clear",
|
||||
Usage: "Clears the matched variables from the environment",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "prefix, p",
|
||||
Value: EnvironmentPrefix,
|
||||
Usage: "Environment prefix to look for - will be suffixed by __ (2 underscores)",
|
||||
},
|
||||
}
|
||||
app.Action = runEnvironmentToIni
|
||||
setting.SetCustomPathAndConf("", "", "")
|
||||
|
||||
err := app.Run(os.Args)
|
||||
if err != nil {
|
||||
log.Fatal("Failed to run app with %s: %v", os.Args, err)
|
||||
}
|
||||
}
|
||||
|
||||
func runEnvironmentToIni(c *cli.Context) error {
|
||||
providedCustom := c.String("custom-path")
|
||||
providedConf := c.String("config")
|
||||
providedWorkPath := c.String("work-path")
|
||||
setting.SetCustomPathAndConf(providedCustom, providedConf, providedWorkPath)
|
||||
|
||||
cfg := ini.Empty()
|
||||
if com.IsFile(setting.CustomConf) {
|
||||
if err := cfg.Append(setting.CustomConf); err != nil {
|
||||
log.Fatal("Failed to load custom conf '%s': %v", setting.CustomConf, err)
|
||||
}
|
||||
} else {
|
||||
log.Warn("Custom config '%s' not found, ignore this if you're running first time", setting.CustomConf)
|
||||
}
|
||||
cfg.NameMapper = ini.SnackCase
|
||||
|
||||
prefix := c.String("prefix") + "__"
|
||||
|
||||
for _, kv := range os.Environ() {
|
||||
idx := strings.IndexByte(kv, '=')
|
||||
if idx < 0 {
|
||||
continue
|
||||
}
|
||||
eKey := kv[:idx]
|
||||
value := kv[idx+1:]
|
||||
if !strings.HasPrefix(eKey, prefix) {
|
||||
continue
|
||||
}
|
||||
eKey = eKey[len(prefix):]
|
||||
sectionName, keyName := DecodeSectionKey(eKey)
|
||||
if len(keyName) == 0 {
|
||||
continue
|
||||
}
|
||||
section, err := cfg.GetSection(sectionName)
|
||||
if err != nil {
|
||||
section, err = cfg.NewSection(sectionName)
|
||||
if err != nil {
|
||||
log.Error("Error creating section: %s : %v", sectionName, err)
|
||||
continue
|
||||
}
|
||||
}
|
||||
key := section.Key(keyName)
|
||||
if key == nil {
|
||||
key, err = section.NewKey(keyName, value)
|
||||
if err != nil {
|
||||
log.Error("Error creating key: %s in section: %s with value: %s : %v", keyName, sectionName, value, err)
|
||||
continue
|
||||
}
|
||||
}
|
||||
key.SetValue(value)
|
||||
}
|
||||
destination := c.String("out")
|
||||
if len(destination) == 0 {
|
||||
destination = setting.CustomConf
|
||||
}
|
||||
err := cfg.SaveTo(destination)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if c.Bool("clear") {
|
||||
for _, kv := range os.Environ() {
|
||||
idx := strings.IndexByte(kv, '=')
|
||||
if idx < 0 {
|
||||
continue
|
||||
}
|
||||
eKey := kv[:idx]
|
||||
if strings.HasPrefix(eKey, prefix) {
|
||||
_ = os.Unsetenv(eKey)
|
||||
}
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
const escapeRegexpString = "_0[xX](([0-9a-fA-F][0-9a-fA-F])+)_"
|
||||
|
||||
var escapeRegex = regexp.MustCompile(escapeRegexpString)
|
||||
|
||||
// DecodeSectionKey will decode a portable string encoded Section__Key pair
|
||||
// Portable strings are considered to be of the form [A-Z0-9_]*
|
||||
// We will encode a disallowed value as the UTF8 byte string preceded by _0X and
|
||||
// followed by _. E.g. _0X2C_ for a '-' and _0X2E_ for '.'
|
||||
// Section and Key are separated by a plain '__'.
|
||||
// The entire section can be encoded as a UTF8 byte string
|
||||
func DecodeSectionKey(encoded string) (string, string) {
|
||||
section := ""
|
||||
key := ""
|
||||
|
||||
inKey := false
|
||||
last := 0
|
||||
escapeStringIndices := escapeRegex.FindAllStringIndex(encoded, -1)
|
||||
for _, unescapeIdx := range escapeStringIndices {
|
||||
preceding := encoded[last:unescapeIdx[0]]
|
||||
if !inKey {
|
||||
if splitter := strings.Index(preceding, "__"); splitter > -1 {
|
||||
section += preceding[:splitter]
|
||||
inKey = true
|
||||
key += preceding[splitter+2:]
|
||||
} else {
|
||||
section += preceding
|
||||
}
|
||||
} else {
|
||||
key += preceding
|
||||
}
|
||||
toDecode := encoded[unescapeIdx[0]+3 : unescapeIdx[1]-1]
|
||||
decodedBytes := make([]byte, len(toDecode)/2)
|
||||
for i := 0; i < len(toDecode)/2; i++ {
|
||||
// Can ignore error here as we know these should be hexadecimal from the regexp
|
||||
byteInt, _ := strconv.ParseInt(toDecode[2*i:2*i+2], 16, 0)
|
||||
decodedBytes[i] = byte(byteInt)
|
||||
}
|
||||
if inKey {
|
||||
key += string(decodedBytes)
|
||||
} else {
|
||||
section += string(decodedBytes)
|
||||
}
|
||||
last = unescapeIdx[1]
|
||||
}
|
||||
remaining := encoded[last:]
|
||||
if !inKey {
|
||||
if splitter := strings.Index(remaining, "__"); splitter > -1 {
|
||||
section += remaining[:splitter]
|
||||
inKey = true
|
||||
key += remaining[splitter+2:]
|
||||
} else {
|
||||
section += remaining
|
||||
}
|
||||
} else {
|
||||
key += remaining
|
||||
}
|
||||
return section, key
|
||||
}
|
@@ -5,6 +5,7 @@ Checkout a PR and load the tests data into sqlite database
|
||||
*/
|
||||
|
||||
import (
|
||||
"context"
|
||||
"flag"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
@@ -27,13 +28,13 @@ import (
|
||||
"code.gitea.io/gitea/routers"
|
||||
"code.gitea.io/gitea/routers/routes"
|
||||
|
||||
"github.com/go-xorm/xorm"
|
||||
context2 "github.com/gorilla/context"
|
||||
"github.com/unknwon/com"
|
||||
"gopkg.in/src-d/go-git.v4"
|
||||
"gopkg.in/src-d/go-git.v4/config"
|
||||
"gopkg.in/src-d/go-git.v4/plumbing"
|
||||
"gopkg.in/testfixtures.v2"
|
||||
"xorm.io/xorm"
|
||||
)
|
||||
|
||||
var codeFilePath = "contrib/pr/checkout.go"
|
||||
@@ -92,7 +93,7 @@ func runPR() {
|
||||
//x, err = xorm.NewEngine("sqlite3", "file::memory:?cache=shared")
|
||||
|
||||
var helper testfixtures.Helper = &testfixtures.SQLite{}
|
||||
models.NewEngine(func(_ *xorm.Engine) error {
|
||||
models.NewEngine(context.Background(), func(_ *xorm.Engine) error {
|
||||
return nil
|
||||
})
|
||||
models.HasEngine = true
|
||||
|
@@ -2,11 +2,42 @@
|
||||
Description=Gitea (Git with a cup of tea)
|
||||
After=syslog.target
|
||||
After=network.target
|
||||
###
|
||||
# Don't forget to add the database service requirements
|
||||
###
|
||||
#
|
||||
#Requires=mysql.service
|
||||
#Requires=mariadb.service
|
||||
#Requires=postgresql.service
|
||||
#Requires=memcached.service
|
||||
#Requires=redis.service
|
||||
#
|
||||
###
|
||||
# If using socket activation for main http/s
|
||||
###
|
||||
#
|
||||
#After=gitea.main.socket
|
||||
#Requires=gitea.main.socket
|
||||
#
|
||||
###
|
||||
# (You can also provide gitea an http fallback and/or ssh socket too)
|
||||
#
|
||||
# An example of /etc/systemd/system/gitea.main.socket
|
||||
###
|
||||
##
|
||||
## [Unit]
|
||||
## Description=Gitea Web Socket
|
||||
## PartOf=gitea.service
|
||||
##
|
||||
## [Socket]
|
||||
## Service=gitea.service
|
||||
## ListenStream=<some_port>
|
||||
## NoDelay=true
|
||||
##
|
||||
## [Install]
|
||||
## WantedBy=sockets.target
|
||||
##
|
||||
###
|
||||
|
||||
[Service]
|
||||
# Modify these two values and uncomment them if you have
|
||||
@@ -20,17 +51,18 @@ Type=simple
|
||||
User=git
|
||||
Group=git
|
||||
WorkingDirectory=/var/lib/gitea/
|
||||
# If using unix socket: Tells Systemd to create /run/gitea folder to home gitea.sock
|
||||
# Manual cration would vanish after reboot.
|
||||
# If using Unix socket: tells systemd to create the /run/gitea folder, which will contain the gitea.sock file
|
||||
# (manually creating /run/gitea doesn't work, because it would not persist across reboots)
|
||||
#RuntimeDirectory=gitea
|
||||
ExecStart=/usr/local/bin/gitea web -c /etc/gitea/app.ini
|
||||
ExecStart=/usr/local/bin/gitea web --config /etc/gitea/app.ini
|
||||
Restart=always
|
||||
Environment=USER=git HOME=/home/git GITEA_WORK_DIR=/var/lib/gitea
|
||||
# If you want to bind Gitea to a port below 1024 uncomment
|
||||
# the two values below
|
||||
# If you want to bind Gitea to a port below 1024, uncomment
|
||||
# the two values below, or use socket activation to pass Gitea its ports as above
|
||||
###
|
||||
#CapabilityBoundingSet=CAP_NET_BIND_SERVICE
|
||||
#AmbientCapabilities=CAP_NET_BIND_SERVICE
|
||||
###
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
@@ -39,6 +39,9 @@ ACCESS_CONTROL_ALLOW_ORIGIN =
|
||||
USE_COMPAT_SSH_URI = false
|
||||
; Close issues as long as a commit on any branch marks it as fixed
|
||||
DEFAULT_CLOSE_ISSUES_VIA_COMMITS_IN_ANY_BRANCH = false
|
||||
; Allow users to push local repositories to Gitea and have them automatically created for a user or an org
|
||||
ENABLE_PUSH_CREATE_USER = false
|
||||
ENABLE_PUSH_CREATE_ORG = false
|
||||
|
||||
[repository.editor]
|
||||
; List of file extensions for which lines should be wrapped in the CodeMirror editor
|
||||
@@ -69,11 +72,57 @@ MAX_FILES = 5
|
||||
[repository.pull-request]
|
||||
; List of prefixes used in Pull Request title to mark them as Work In Progress
|
||||
WORK_IN_PROGRESS_PREFIXES=WIP:,[WIP]
|
||||
; List of keywords used in Pull Request comments to automatically close a related issue
|
||||
CLOSE_KEYWORDS=close,closes,closed,fix,fixes,fixed,resolve,resolves,resolved
|
||||
; List of keywords used in Pull Request comments to automatically reopen a related issue
|
||||
REOPEN_KEYWORDS=reopen,reopens,reopened
|
||||
; In the default merge message for squash commits include at most this many commits
|
||||
DEFAULT_MERGE_MESSAGE_COMMITS_LIMIT=50
|
||||
; In the default merge message for squash commits limit the size of the commit messages to this
|
||||
DEFAULT_MERGE_MESSAGE_SIZE=5120
|
||||
; In the default merge message for squash commits walk all commits to include all authors in the Co-authored-by otherwise just use those in the limited list
|
||||
DEFAULT_MERGE_MESSAGE_ALL_AUTHORS=false
|
||||
; In default merge messages limit the number of approvers listed as Reviewed-by: to this many
|
||||
DEFAULT_MERGE_MESSAGE_MAX_APPROVERS=10
|
||||
; In default merge messages only include approvers who are official
|
||||
DEFAULT_MERGE_MESSAGE_OFFICIAL_APPROVERS_ONLY=true
|
||||
|
||||
[repository.issue]
|
||||
; List of reasons why a Pull Request or Issue can be locked
|
||||
LOCK_REASONS=Too heated,Off-topic,Resolved,Spam
|
||||
|
||||
[repository.signing]
|
||||
; GPG key to use to sign commits, Defaults to the default - that is the value of git config --get user.signingkey
|
||||
; run in the context of the RUN_USER
|
||||
; Switch to none to stop signing completely
|
||||
SIGNING_KEY = default
|
||||
; If a SIGNING_KEY ID is provided and is not set to default, use the provided Name and Email address as the signer.
|
||||
; These should match a publicized name and email address for the key. (When SIGNING_KEY is default these are set to
|
||||
; the results of git config --get user.name and git config --get user.email respectively and can only be overrided
|
||||
; by setting the SIGNING_KEY ID to the correct ID.)
|
||||
SIGNING_NAME =
|
||||
SIGNING_EMAIL =
|
||||
; Determines when gitea should sign the initial commit when creating a repository
|
||||
; Either:
|
||||
; - never
|
||||
; - pubkey: only sign if the user has a pubkey
|
||||
; - twofa: only sign if the user has logged in with twofa
|
||||
; - always
|
||||
; options other than none and always can be combined as comma separated list
|
||||
INITIAL_COMMIT = always
|
||||
; Determines when to sign for CRUD actions
|
||||
; - as above
|
||||
; - parentsigned: requires that the parent commit is signed.
|
||||
CRUD_ACTIONS = pubkey, twofa, parentsigned
|
||||
; Determines when to sign Wiki commits
|
||||
; - as above
|
||||
WIKI = never
|
||||
; Determines when to sign on merges
|
||||
; - basesigned: require that the parent of commit on the base repo is signed.
|
||||
; - commitssigned: require that all the commits in the head branch are signed.
|
||||
; - approved: only sign when merging an approved pr to a protected branch
|
||||
MERGES = pubkey, twofa, basesigned, commitssigned
|
||||
|
||||
[cors]
|
||||
; More information about CORS can be found here: https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS#The_HTTP_response_headers
|
||||
; enable cors headers (disabled by default)
|
||||
@@ -114,10 +163,15 @@ SHOW_USER_EMAIL = true
|
||||
DEFAULT_THEME = gitea
|
||||
; All available themes. Allow users select personalized themes regardless of the value of `DEFAULT_THEME`.
|
||||
THEMES = gitea,arc-green
|
||||
; All available reactions. Allow users react with different emoji's
|
||||
; For the whole list look at https://gitea.com/gitea/gitea.com/issues/8
|
||||
REACTIONS = +1, -1, laugh, hooray, confused, heart, rocket, eyes
|
||||
; Whether the full name of the users should be shown where possible. If the full name isn't set, the username will be used.
|
||||
DEFAULT_SHOW_FULL_NAME = false
|
||||
; Whether to search within description at repository search on explore page.
|
||||
SEARCH_REPO_DESCRIPTION = true
|
||||
; Whether to enable a Service Worker to cache frontend assets
|
||||
USE_SERVICE_WORKER = true
|
||||
|
||||
[ui.admin]
|
||||
; Number of users that are displayed on one page
|
||||
@@ -141,8 +195,9 @@ KEYWORDS = go,git,self-hosted,gitea
|
||||
[markdown]
|
||||
; Enable hard line break extension
|
||||
ENABLE_HARD_LINE_BREAK = false
|
||||
; List of custom URL-Schemes that are allowed as links when rendering Markdown
|
||||
; for example git,magnet
|
||||
; Comma separated list of custom URL-Schemes that are allowed as links when rendering Markdown
|
||||
; for example git,magnet,ftp (more at https://en.wikipedia.org/wiki/List_of_URI_schemes)
|
||||
; URLs starting with http and https are always displayed, whatever is put in this entry.
|
||||
CUSTOM_URL_SCHEMES =
|
||||
; List of file extensions that should be rendered/edited as Markdown
|
||||
; Separate the extensions with a comma. To render files without any extension as markdown, just put a comma
|
||||
@@ -153,6 +208,8 @@ FILE_EXTENSIONS = .md,.markdown,.mdown,.mkd
|
||||
PROTOCOL = http
|
||||
DOMAIN = localhost
|
||||
ROOT_URL = %(PROTOCOL)s://%(DOMAIN)s:%(HTTP_PORT)s/
|
||||
; when STATIC_URL_PREFIX is empty it will follow APP_URL
|
||||
STATIC_URL_PREFIX =
|
||||
; The address to listen on. Either a IPv4/IPv6 address or the path to a unix socket.
|
||||
HTTP_ADDR = 0.0.0.0
|
||||
HTTP_PORT = 3000
|
||||
@@ -218,8 +275,9 @@ DISABLE_ROUTER_LOG = false
|
||||
; not forget to export the private key):
|
||||
; $ openssl pkcs12 -in cert.pfx -out cert.pem -nokeys
|
||||
; $ openssl pkcs12 -in cert.pfx -out key.pem -nocerts -nodes
|
||||
CERT_FILE = custom/https/cert.pem
|
||||
KEY_FILE = custom/https/key.pem
|
||||
; Paths are relative to CUSTOM_PATH
|
||||
CERT_FILE = https/cert.pem
|
||||
KEY_FILE = https/key.pem
|
||||
; Root directory containing templates and static files.
|
||||
; default is the path where Gitea is executed
|
||||
STATIC_ROOT_PATH =
|
||||
@@ -233,7 +291,8 @@ ENABLE_GZIP = false
|
||||
ENABLE_PPROF = false
|
||||
; PPROF_DATA_PATH, use an absolute path when you start gitea as service
|
||||
PPROF_DATA_PATH = data/tmp/pprof
|
||||
; Landing page, can be "home", "explore", or "organizations"
|
||||
; Landing page, can be "home", "explore", "organizations" or "login"
|
||||
; The "login" choice is not a security measure but just a UI flow change, use REQUIRE_SIGNIN_VIEW to force users to log in.
|
||||
LANDING_PAGE = home
|
||||
; Enables git-lfs support. true or false, default is false.
|
||||
LFS_START_SERVER = false
|
||||
@@ -243,6 +302,17 @@ LFS_CONTENT_PATH = data/lfs
|
||||
LFS_JWT_SECRET =
|
||||
; LFS authentication validity period (in time.Duration), pushes taking longer than this may fail.
|
||||
LFS_HTTP_AUTH_EXPIRY = 20m
|
||||
; Allow graceful restarts using SIGHUP to fork
|
||||
ALLOW_GRACEFUL_RESTARTS = true
|
||||
; After a restart the parent will finish ongoing requests before
|
||||
; shutting down. Force shutdown if this process takes longer than this delay.
|
||||
; set to a negative value to disable
|
||||
GRACEFUL_HAMMER_TIME = 60s
|
||||
; Allows the setting of a startup timeout and waithint for Windows as SVC service
|
||||
; 0 disables this.
|
||||
STARTUP_TIMEOUT = 0
|
||||
; Static resources, includes resources on custom/, public/ and all uploaded avatars web browser cache time, default is 6h
|
||||
STATIC_CACHE_TIME = 6h
|
||||
|
||||
; Define allowed algorithms and their minimum key length (use -1 to disable a type)
|
||||
[ssh.minimum_key_sizes]
|
||||
@@ -298,6 +368,9 @@ ISSUE_INDEXER_QUEUE_DIR = indexers/issues.queue
|
||||
ISSUE_INDEXER_QUEUE_CONN_STR = "addrs=127.0.0.1:6379 db=0"
|
||||
; Batch queue number, default is 20
|
||||
ISSUE_INDEXER_QUEUE_BATCH_NUMBER = 20
|
||||
; Timeout the indexer if it takes longer than this to start.
|
||||
; Set to zero to disable timeout.
|
||||
STARTUP_TIMEOUT=30s
|
||||
|
||||
; repo indexer by default disabled, since it uses a lot of disk space
|
||||
REPO_INDEXER_ENABLED = false
|
||||
@@ -310,6 +383,39 @@ REPO_INDEXER_INCLUDE =
|
||||
; A comma separated list of glob patterns to exclude from the index; ; default is empty
|
||||
REPO_INDEXER_EXCLUDE =
|
||||
|
||||
[queue]
|
||||
; Specific queues can be individually configured with [queue.name]. [queue] provides defaults
|
||||
;
|
||||
; General queue queue type, currently support: persistable-channel, channel, level, redis, dummy
|
||||
; default to persistable-channel
|
||||
TYPE = persistable-channel
|
||||
; data-dir for storing persistable queues and level queues, individual queues will be named by their type
|
||||
DATADIR = queues/
|
||||
; Default queue length before a channel queue will block
|
||||
LENGTH = 20
|
||||
; Batch size to send for batched queues
|
||||
BATCH_LENGTH = 20
|
||||
; Connection string for redis queues this will store the redis connection string.
|
||||
CONN_STR = "addrs=127.0.0.1:6379 db=0"
|
||||
; Provide the suffix of the default redis queue name - specific queues can be overriden within in their [queue.name] sections.
|
||||
QUEUE_NAME = "_queue"
|
||||
; If the queue cannot be created at startup - level queues may need a timeout at startup - wrap the queue:
|
||||
WRAP_IF_NECESSARY = true
|
||||
; Attempt to create the wrapped queue at max
|
||||
MAX_ATTEMPTS = 10
|
||||
; Timeout queue creation
|
||||
TIMEOUT = 15m30s
|
||||
; Create a pool with this many workers
|
||||
WORKERS = 1
|
||||
; Dynamically scale the worker pool to at this many workers
|
||||
MAX_WORKERS = 10
|
||||
; Add boost workers when the queue blocks for BLOCK_TIMEOUT
|
||||
BLOCK_TIMEOUT = 1s
|
||||
; Remove the boost workers after BOOST_TIMEOUT
|
||||
BOOST_TIMEOUT = 5m
|
||||
; During a boost add BOOST_WORKERS
|
||||
BOOST_WORKERS = 5
|
||||
|
||||
[admin]
|
||||
; Disallow regular (non-admin) users from creating organizations.
|
||||
DISABLE_REGULAR_ORG_CREATION = false
|
||||
@@ -334,6 +440,8 @@ MIN_PASSWORD_LENGTH = 6
|
||||
IMPORT_LOCAL_PATHS = false
|
||||
; Set to true to prevent all users (including admin) from creating custom git hooks
|
||||
DISABLE_GIT_HOOKS = false
|
||||
; Set to false to allow pushes to gitea repositories despite having an incomplete environment - NOT RECOMMENDED
|
||||
ONLY_ALLOW_PUSH_IF_GITEA_ENVIRONMENT_SET = true
|
||||
;Comma separated list of character classes required to pass minimum complexity.
|
||||
;If left empty or no valid values are specified, the default values ("lower,upper,digit,spec") will be used.
|
||||
;Use "off" to disable checking.
|
||||
@@ -395,6 +503,10 @@ ALLOW_ONLY_EXTERNAL_REGISTRATION = false
|
||||
REQUIRE_SIGNIN_VIEW = false
|
||||
; Mail notification
|
||||
ENABLE_NOTIFY_MAIL = false
|
||||
; This setting enables gitea to be signed in with HTTP BASIC Authentication using the user's password
|
||||
; If you set this to false you will not be able to access the tokens endpoints on the API with your password
|
||||
; Please note that setting this to false will not disable OAuth Basic or Basic authentication using a token
|
||||
ENABLE_BASIC_AUTHENTICATION = true
|
||||
; More detail: https://github.com/gogits/gogs/issues/165
|
||||
ENABLE_REVERSE_PROXY_AUTHENTICATION = false
|
||||
ENABLE_REVERSE_PROXY_AUTO_REGISTRATION = false
|
||||
@@ -426,6 +538,8 @@ DEFAULT_ORG_MEMBER_VISIBLE = false
|
||||
; Default value for EnableDependencies
|
||||
; Repositories will use dependencies by default depending on this setting
|
||||
DEFAULT_ENABLE_DEPENDENCIES = true
|
||||
; Dependencies can be added from any repository where the user is granted access or only from the current repository depending on this setting.
|
||||
ALLOW_CROSS_REPOSITORY_DEPENDENCIES = true
|
||||
; Enable heatmap on users profiles.
|
||||
ENABLE_USER_HEATMAP = true
|
||||
; Enable Timetracking
|
||||
@@ -439,13 +553,18 @@ DEFAULT_ALLOW_ONLY_CONTRIBUTORS_TO_TRACK_TIME = true
|
||||
; Default value for the domain part of the user's email address in the git log
|
||||
; if he has set KeepEmailPrivate to true. The user's email will be replaced with a
|
||||
; concatenation of the user name in lower case, "@" and NO_REPLY_ADDRESS.
|
||||
NO_REPLY_ADDRESS = noreply.example.org
|
||||
NO_REPLY_ADDRESS = noreply.%(DOMAIN)s
|
||||
; Show Registration button
|
||||
SHOW_REGISTRATION_BUTTON = true
|
||||
; Show milestones dashboard page - a view of all the user's milestones
|
||||
SHOW_MILESTONES_DASHBOARD_PAGE = true
|
||||
; Default value for AutoWatchNewRepos
|
||||
; When adding a repo to a team or creating a new repo all team members will watch the
|
||||
; repo automatically if enabled
|
||||
AUTO_WATCH_NEW_REPOS = true
|
||||
; Default value for AutoWatchOnChanges
|
||||
; Make the user watch a repository When they commit for the first time
|
||||
AUTO_WATCH_ON_CHANGES = false
|
||||
|
||||
[webhook]
|
||||
; Hook task queue length, increase if webhook shooting starts hanging
|
||||
@@ -456,6 +575,10 @@ DELIVER_TIMEOUT = 5
|
||||
SKIP_TLS_VERIFY = false
|
||||
; Number of history information in each page
|
||||
PAGING_NUM = 10
|
||||
; Proxy server URL, support http://, https//, socks://, blank will follow environment http_proxy/https_proxy
|
||||
PROXY_URL =
|
||||
; Comma separated list of host names requiring proxy. Glob patterns (*) are accepted; use ** to match all hosts.
|
||||
PROXY_HOSTS =
|
||||
|
||||
[mailer]
|
||||
ENABLED = false
|
||||
@@ -805,6 +928,12 @@ SHOW_FOOTER_VERSION = true
|
||||
; Show template execution time in the footer
|
||||
SHOW_FOOTER_TEMPLATE_LOAD_TIME = true
|
||||
|
||||
[markup.sanitizer]
|
||||
; The following keys can be used multiple times to define sanitation policy rules.
|
||||
;ELEMENT = span
|
||||
;ALLOW_ATTR = class
|
||||
;REGEXP = ^(info|warning|error)$
|
||||
|
||||
[markup.asciidoc]
|
||||
ENABLED = false
|
||||
; List of file extensions that should be rendered by an external command
|
||||
@@ -828,3 +957,9 @@ QUEUE_LENGTH = 1000
|
||||
; Task queue connection string, available only when `QUEUE_TYPE` is `redis`.
|
||||
; If there is a password of redis, use `addrs=127.0.0.1:6379 password=123 db=0`.
|
||||
QUEUE_CONN_STR = "addrs=127.0.0.1:6379 db=0"
|
||||
|
||||
[migrations]
|
||||
; Max attempts per http/https request on migrations.
|
||||
MAX_ATTEMPTS = 3
|
||||
; Backoff time per http/https request retry (seconds)
|
||||
RETRY_BACKOFF = 3
|
||||
|
2
docker/Makefile
vendored
2
docker/Makefile
vendored
@@ -11,4 +11,4 @@ docker:
|
||||
|
||||
.PHONY: docker-build
|
||||
docker-build:
|
||||
docker run -ti --rm -v $(CURDIR):/srv/app/src/code.gitea.io/gitea -w /srv/app/src/code.gitea.io/gitea -e TAGS="bindata $(TAGS)" LDFLAGS="$(LDFLAGS)" webhippie/golang:edge make clean generate build
|
||||
docker run -ti --rm -v $(CURDIR):/srv/app/src/code.gitea.io/gitea -w /srv/app/src/code.gitea.io/gitea -e TAGS="bindata $(TAGS)" LDFLAGS="$(LDFLAGS)" webhippie/golang:edge make clean build
|
||||
|
@@ -1,2 +1,2 @@
|
||||
#!/bin/bash
|
||||
exit 0
|
||||
s6-svscanctl -t /etc/s6/
|
||||
|
1
docs/.gitignore
vendored
1
docs/.gitignore
vendored
@@ -1,3 +1,4 @@
|
||||
public/
|
||||
templates/swagger/v1_json.tmpl
|
||||
themes/
|
||||
resources/
|
||||
|
176
docs/assets/js/search.js
Normal file
176
docs/assets/js/search.js
Normal file
@@ -0,0 +1,176 @@
|
||||
function ready(fn) {
|
||||
if (document.readyState != 'loading') {
|
||||
fn();
|
||||
} else {
|
||||
document.addEventListener('DOMContentLoaded', fn);
|
||||
}
|
||||
}
|
||||
|
||||
ready(doSearch);
|
||||
|
||||
const summaryInclude = 60;
|
||||
const fuseOptions = {
|
||||
shouldSort: true,
|
||||
includeMatches: true,
|
||||
matchAllTokens: true,
|
||||
threshold: 0.0, // for parsing diacritics
|
||||
tokenize: true,
|
||||
location: 0,
|
||||
distance: 100,
|
||||
maxPatternLength: 32,
|
||||
minMatchCharLength: 1,
|
||||
keys: [{
|
||||
name: "title",
|
||||
weight: 0.8
|
||||
},
|
||||
{
|
||||
name: "contents",
|
||||
weight: 0.5
|
||||
},
|
||||
{
|
||||
name: "tags",
|
||||
weight: 0.3
|
||||
},
|
||||
{
|
||||
name: "categories",
|
||||
weight: 0.3
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
function param(name) {
|
||||
return decodeURIComponent((location.search.split(name + '=')[1] || '').split('&')[0]).replace(/\+/g, ' ');
|
||||
}
|
||||
|
||||
let searchQuery = param("s");
|
||||
|
||||
function doSearch() {
|
||||
if (searchQuery) {
|
||||
document.getElementById("search-query").value = searchQuery;
|
||||
executeSearch(searchQuery);
|
||||
} else {
|
||||
const para = document.createElement("P");
|
||||
para.innerText = "Please enter a word or phrase above";
|
||||
document.getElementById("search-results").appendChild(para);
|
||||
}
|
||||
}
|
||||
|
||||
function getJSON(url, fn) {
|
||||
const request = new XMLHttpRequest();
|
||||
request.open('GET', url, true);
|
||||
request.onload = function () {
|
||||
if (request.status >= 200 && request.status < 400) {
|
||||
const data = JSON.parse(request.responseText);
|
||||
fn(data);
|
||||
} else {
|
||||
console.log("Target reached on " + url + " with error " + request.status);
|
||||
}
|
||||
};
|
||||
request.onerror = function () {
|
||||
console.log("Connection error " + request.status);
|
||||
};
|
||||
request.send();
|
||||
}
|
||||
|
||||
function executeSearch(searchQuery) {
|
||||
getJSON("/" + document.LANG + "/index.json", function (data) {
|
||||
const pages = data;
|
||||
const fuse = new Fuse(pages, fuseOptions);
|
||||
const result = fuse.search(searchQuery);
|
||||
console.log({
|
||||
"matches": result
|
||||
});
|
||||
document.getElementById("search-results").innerHTML = "";
|
||||
if (result.length > 0) {
|
||||
populateResults(result);
|
||||
} else {
|
||||
const para = document.createElement("P");
|
||||
para.innerText = "No matches found";
|
||||
document.getElementById("search-results").appendChild(para);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function populateResults(result) {
|
||||
result.forEach(function (value, key) {
|
||||
const content = value.item.contents;
|
||||
let snippet = "";
|
||||
const snippetHighlights = [];
|
||||
if (fuseOptions.tokenize) {
|
||||
snippetHighlights.push(searchQuery);
|
||||
value.matches.forEach(function (mvalue) {
|
||||
if (mvalue.key === "tags" || mvalue.key === "categories") {
|
||||
snippetHighlights.push(mvalue.value);
|
||||
} else if (mvalue.key === "contents") {
|
||||
const ind = content.toLowerCase().indexOf(searchQuery.toLowerCase());
|
||||
const start = ind - summaryInclude > 0 ? ind - summaryInclude : 0;
|
||||
const end = ind + searchQuery.length + summaryInclude < content.length ? ind + searchQuery.length + summaryInclude : content.length;
|
||||
snippet += content.substring(start, end);
|
||||
if (ind > -1) {
|
||||
snippetHighlights.push(content.substring(ind, ind + searchQuery.length))
|
||||
} else {
|
||||
snippetHighlights.push(mvalue.value.substring(mvalue.indices[0][0], mvalue.indices[0][1] - mvalue.indices[0][0] + 1));
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if (snippet.length < 1) {
|
||||
snippet += content.substring(0, summaryInclude * 2);
|
||||
}
|
||||
//pull template from hugo templarte definition
|
||||
const templateDefinition = document.getElementById("search-result-template").innerHTML;
|
||||
//replace values
|
||||
const output = render(templateDefinition, {
|
||||
key: key,
|
||||
title: value.item.title,
|
||||
link: value.item.permalink,
|
||||
tags: value.item.tags,
|
||||
categories: value.item.categories,
|
||||
snippet: snippet
|
||||
});
|
||||
document.getElementById("search-results").appendChild(htmlToElement(output));
|
||||
|
||||
snippetHighlights.forEach(function (snipvalue) {
|
||||
new Mark(document.getElementById("summary-" + key)).mark(snipvalue);
|
||||
});
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
function render(templateString, data) {
|
||||
let conditionalMatches, copy;
|
||||
const conditionalPattern = /\$\{\s*isset ([a-zA-Z]*) \s*\}(.*)\$\{\s*end\s*}/g;
|
||||
//since loop below depends on re.lastInxdex, we use a copy to capture any manipulations whilst inside the loop
|
||||
copy = templateString;
|
||||
while ((conditionalMatches = conditionalPattern.exec(templateString)) !== null) {
|
||||
if (data[conditionalMatches[1]]) {
|
||||
//valid key, remove conditionals, leave content.
|
||||
copy = copy.replace(conditionalMatches[0], conditionalMatches[2]);
|
||||
} else {
|
||||
//not valid, remove entire section
|
||||
copy = copy.replace(conditionalMatches[0], '');
|
||||
}
|
||||
}
|
||||
templateString = copy;
|
||||
//now any conditionals removed we can do simple substitution
|
||||
let key, find, re;
|
||||
for (key in data) {
|
||||
find = '\\$\\{\\s*' + key + '\\s*\\}';
|
||||
re = new RegExp(find, 'g');
|
||||
templateString = templateString.replace(re, data[key]);
|
||||
}
|
||||
return templateString;
|
||||
}
|
||||
|
||||
/**
|
||||
* By Mark Amery: https://stackoverflow.com/a/35385518
|
||||
* @param {String} HTML representing a single element
|
||||
* @return {Element}
|
||||
*/
|
||||
function htmlToElement(html) {
|
||||
const template = document.createElement('template');
|
||||
html = html.trim(); // Never return a text node of whitespace as the result
|
||||
template.innerHTML = html;
|
||||
return template.content.firstChild;
|
||||
}
|
@@ -18,7 +18,13 @@ params:
|
||||
description: Git with a cup of tea
|
||||
author: The Gitea Authors
|
||||
website: https://docs.gitea.io
|
||||
version: 1.9.3
|
||||
version: 1.11.2
|
||||
|
||||
outputs:
|
||||
home:
|
||||
- HTML
|
||||
- RSS
|
||||
- JSON
|
||||
|
||||
menu:
|
||||
page:
|
||||
|
@@ -66,16 +66,47 @@ Values containing `#` or `;` must be quoted using `` ` `` or `"""`.
|
||||
default is not to present. **WARNING**: This maybe harmful to you website if you do not
|
||||
give it a right value.
|
||||
- `DEFAULT_CLOSE_ISSUES_VIA_COMMITS_IN_ANY_BRANCH`: **false**: Close an issue if a commit on a non default branch marks it as closed.
|
||||
- `ENABLE_PUSH_CREATE_USER`: **false**: Allow users to push local repositories to Gitea and have them automatically created for a user.
|
||||
- `ENABLE_PUSH_CREATE_ORG`: **false**: Allow users to push local repositories to Gitea and have them automatically created for an org.
|
||||
|
||||
### Repository - Pull Request (`repository.pull-request`)
|
||||
|
||||
- `WORK_IN_PROGRESS_PREFIXES`: **WIP:,\[WIP\]**: List of prefixes used in Pull Request
|
||||
title to mark them as Work In Progress
|
||||
- `CLOSE_KEYWORDS`: **close**, **closes**, **closed**, **fix**, **fixes**, **fixed**, **resolve**, **resolves**, **resolved**: List of
|
||||
keywords used in Pull Request comments to automatically close a related issue
|
||||
- `REOPEN_KEYWORDS`: **reopen**, **reopens**, **reopened**: List of keywords used in Pull Request comments to automatically reopen
|
||||
a related issue
|
||||
- `DEFAULT_MERGE_MESSAGE_COMMITS_LIMIT`: **50**: In the default merge message for squash commits include at most this many commits. Set to `-1` to include all commits
|
||||
- `DEFAULT_MERGE_MESSAGE_SIZE`: **5120**: In the default merge message for squash commits limit the size of the commit messages. Set to `-1` to have no limit.
|
||||
- `DEFAULT_MERGE_MESSAGE_ALL_AUTHORS`: **false**: In the default merge message for squash commits walk all commits to include all authors in the Co-authored-by otherwise just use those in the limited list
|
||||
- `DEFAULT_MERGE_MESSAGE_MAX_APPROVERS`: **10**: In default merge messages limit the number of approvers listed as `Reviewed-by:`. Set to `-1` to include all.
|
||||
- `DEFAULT_MERGE_MESSAGE_OFFICIAL_APPROVERS_ONLY`: **true**: In default merge messages only include approvers who are officially allowed to review.
|
||||
|
||||
### Repository - Issue (`repository.issue`)
|
||||
|
||||
- `LOCK_REASONS`: **Too heated,Off-topic,Resolved,Spam**: A list of reasons why a Pull Request or Issue can be locked
|
||||
|
||||
### Repository - Signing (`repository.signing`)
|
||||
|
||||
- `SIGNING_KEY`: **default**: \[none, KEYID, default \]: Key to sign with.
|
||||
- `SIGNING_NAME` & `SIGNING_EMAIL`: if a KEYID is provided as the `SIGNING_KEY`, use these as the Name and Email address of the signer. These should match publicized name and email address for the key.
|
||||
- `INITIAL_COMMIT`: **always**: \[never, pubkey, twofa, always\]: Sign initial commit.
|
||||
- `never`: Never sign
|
||||
- `pubkey`: Only sign if the user has a public key
|
||||
- `twofa`: Only sign if the user is logged in with twofa
|
||||
- `always`: Always sign
|
||||
- Options other than `never` and `always` can be combined as a comma separated list.
|
||||
- `WIKI`: **never**: \[never, pubkey, twofa, always, parentsigned\]: Sign commits to wiki.
|
||||
- `CRUD_ACTIONS`: **pubkey, twofa, parentsigned**: \[never, pubkey, twofa, parentsigned, always\]: Sign CRUD actions.
|
||||
- Options as above, with the addition of:
|
||||
- `parentsigned`: Only sign if the parent commit is signed.
|
||||
- `MERGES`: **pubkey, twofa, basesigned, commitssigned**: \[never, pubkey, twofa, approved, basesigned, commitssigned, always\]: Sign merges.
|
||||
- `approved`: Only sign approved merges to a protected branch.
|
||||
- `basesigned`: Only sign if the parent commit in the base repo is signed.
|
||||
- `headsigned`: Only sign if the head commit in the head branch is signed.
|
||||
- `commitssigned`: Only sign if all the commits in the head branch to the merge point are signed.
|
||||
|
||||
## CORS (`cors`)
|
||||
|
||||
- `ENABLED`: **false**: enable cors headers (disabled by default)
|
||||
@@ -90,13 +121,16 @@ Values containing `#` or `;` must be quoted using `` ` `` or `"""`.
|
||||
|
||||
- `EXPLORE_PAGING_NUM`: **20**: Number of repositories that are shown in one explore page.
|
||||
- `ISSUE_PAGING_NUM`: **10**: Number of issues that are shown in one page (for all pages that list issues).
|
||||
- `MEMBERS_PAGING_NUM`: **20**: Number of members that are shown in organization members.
|
||||
- `FEED_MAX_COMMIT_NUM`: **5**: Number of maximum commits shown in one activity feed.
|
||||
- `GRAPH_MAX_COMMIT_NUM`: **100**: Number of maximum commits shown in the commit graph.
|
||||
- `DEFAULT_THEME`: **gitea**: \[gitea, arc-green\]: Set the default theme for the Gitea install.
|
||||
- `THEMES`: **gitea,arc-green**: All available themes. Allow users select personalized themes
|
||||
regardless of the value of `DEFAULT_THEME`.
|
||||
- `DEFAULT_SHOW_FULL_NAME`: false: Whether the full name of the users should be shown where possible. If the full name isn't set, the username will be used.
|
||||
- `SEARCH_REPO_DESCRIPTION`: true: Whether to search within description at repository search on explore page.
|
||||
- `REACTIONS`: All available reactions. Allow users react with different emoji's.
|
||||
- `DEFAULT_SHOW_FULL_NAME`: **false**: Whether the full name of the users should be shown where possible. If the full name isn't set, the username will be used.
|
||||
- `SEARCH_REPO_DESCRIPTION`: **true**: Whether to search within description at repository search on explore page.
|
||||
- `USE_SERVICE_WORKER`: **true**: Whether to enable a Service Worker to cache frontend assets.
|
||||
|
||||
### UI - Admin (`ui.admin`)
|
||||
|
||||
@@ -108,18 +142,28 @@ Values containing `#` or `;` must be quoted using `` ` `` or `"""`.
|
||||
## Markdown (`markdown`)
|
||||
|
||||
- `ENABLE_HARD_LINE_BREAK`: **false**: Enable Markdown's hard line break extension.
|
||||
- `CUSTOM_URL_SCHEMES`: Use a comma separated list (ftp,git,svn) to indicate additional
|
||||
URL hyperlinks to be rendered in Markdown. URLs beginning in http and https are
|
||||
always displayed
|
||||
|
||||
## Server (`server`)
|
||||
|
||||
- `PROTOCOL`: **http**: \[http, https, fcgi, unix\]
|
||||
- `PROTOCOL`: **http**: \[http, https, fcgi, unix, fcgi+unix\]
|
||||
- `DOMAIN`: **localhost**: Domain name of this server.
|
||||
- `ROOT_URL`: **%(PROTOCOL)s://%(DOMAIN)s:%(HTTP\_PORT)s/**:
|
||||
Overwrite the automatically generated public URL.
|
||||
This is useful if the internal and the external URL don't match (e.g. in Docker).
|
||||
- `STATIC_URL_PREFIX`: **\<empty\>**:
|
||||
Overwrite this option to request static resources from a different URL.
|
||||
This includes CSS files, images, JS files and web fonts.
|
||||
Avatar images are dynamic resources and still served by gitea.
|
||||
The option can be just a different path, as in `/static`, or another domain, as in `https://cdn.example.com`.
|
||||
Requests are then made as `%(ROOT_URL)s/static/css/index.css` and `https://cdn.example.com/css/index.css` respective.
|
||||
The static files are located in the `public/` directory of the gitea source repository.
|
||||
- `HTTP_ADDR`: **0.0.0.0**: HTTP listen address.
|
||||
- If `PROTOCOL` is set to `fcgi`, Gitea will listen for FastCGI requests on TCP socket
|
||||
defined by `HTTP_ADDR` and `HTTP_PORT` configuration settings.
|
||||
- If `PROTOCOL` is set to `unix`, this should be the name of the Unix socket file to use.
|
||||
- If `PROTOCOL` is set to `unix` or `fcgi+unix`, this should be the name of the Unix socket file to use.
|
||||
- `HTTP_PORT`: **3000**: HTTP listen port.
|
||||
- If `PROTOCOL` is set to `fcgi`, Gitea will listen for FastCGI requests on TCP socket
|
||||
defined by `HTTP_ADDR` and `HTTP_PORT` configuration settings.
|
||||
@@ -137,11 +181,12 @@ Values containing `#` or `;` must be quoted using `` ` `` or `"""`.
|
||||
- `SSH_LISTEN_PORT`: **%(SSH\_PORT)s**: Port for the built-in SSH server.
|
||||
- `OFFLINE_MODE`: **false**: Disables use of CDN for static files and Gravatar for profile pictures.
|
||||
- `DISABLE_ROUTER_LOG`: **false**: Mute printing of the router log.
|
||||
- `CERT_FILE`: **custom/https/cert.pem**: Cert file path used for HTTPS.
|
||||
- `KEY_FILE`: **custom/https/key.pem**: Key file path used for HTTPS.
|
||||
- `CERT_FILE`: **https/cert.pem**: Cert file path used for HTTPS. From 1.11 paths are relative to `CUSTOM_PATH`.
|
||||
- `KEY_FILE`: **https/key.pem**: Key file path used for HTTPS. From 1.11 paths are relative to `CUSTOM_PATH`.
|
||||
- `STATIC_ROOT_PATH`: **./**: Upper level of template and static files path.
|
||||
- `STATIC_CACHE_TIME`: **6h**: Web browser cache time for static resources on `custom/`, `public/` and all uploaded avatars.
|
||||
- `ENABLE_GZIP`: **false**: Enables application-level GZIP support.
|
||||
- `LANDING_PAGE`: **home**: Landing page for unauthenticated users \[home, explore\].
|
||||
- `LANDING_PAGE`: **home**: Landing page for unauthenticated users \[home, explore, organizations, login\].
|
||||
- `LFS_START_SERVER`: **false**: Enables git-lfs support.
|
||||
- `LFS_CONTENT_PATH`: **./data/lfs**: Where to store LFS files.
|
||||
- `LFS_JWT_SECRET`: **\<empty\>**: LFS authentication secret, change this a unique string.
|
||||
@@ -153,6 +198,9 @@ Values containing `#` or `;` must be quoted using `` ` `` or `"""`.
|
||||
- `LETSENCRYPT_ACCEPTTOS`: **false**: This is an explicit check that you accept the terms of service for Let's Encrypt.
|
||||
- `LETSENCRYPT_DIRECTORY`: **https**: Directory that Letsencrypt will use to cache information such as certs and private keys.
|
||||
- `LETSENCRYPT_EMAIL`: **email@example.com**: Email used by Letsencrypt to notify about problems with issued certificates. (No default)
|
||||
- `ALLOW_GRACEFUL_RESTARTS`: **true**: Perform a graceful restart on SIGHUP
|
||||
- `GRACEFUL_HAMMER_TIME`: **60s**: After a restart the parent process will stop accepting new connections and will allow requests to finish before stopping. Shutdown will be forced if it takes longer than this time.
|
||||
- `STARTUP_TIMEOUT`: **0**: Shutsdown the server if startup takes longer than the provided time. On Windows setting this sends a waithint to the SVC host to tell the SVC host startup may take some time. Please note startup is determined by the opening of the listeners - HTTP/HTTPS/SSH. Indexers may take longer to startup and can have their own timeouts.
|
||||
|
||||
## Database (`database`)
|
||||
|
||||
@@ -178,6 +226,7 @@ relation to port exhaustion.
|
||||
|
||||
- `ISSUE_INDEXER_TYPE`: **bleve**: Issue indexer type, currently support: bleve or db, if it's db, below issue indexer item will be invalid.
|
||||
- `ISSUE_INDEXER_PATH`: **indexers/issues.bleve**: Index file used for issue search.
|
||||
- The next 4 configuration values are deprecated and should be set in `queue.issue_indexer` however are kept for backwards compatibility:
|
||||
- `ISSUE_INDEXER_QUEUE_TYPE`: **levelqueue**: Issue indexer queue, currently supports:`channel`, `levelqueue`, `redis`.
|
||||
- `ISSUE_INDEXER_QUEUE_DIR`: **indexers/issues.queue**: When `ISSUE_INDEXER_QUEUE_TYPE` is `levelqueue`, this will be the queue will be saved path.
|
||||
- `ISSUE_INDEXER_QUEUE_CONN_STR`: **addrs=127.0.0.1:6379 db=0**: When `ISSUE_INDEXER_QUEUE_TYPE` is `redis`, this will store the redis connection string.
|
||||
@@ -189,6 +238,25 @@ relation to port exhaustion.
|
||||
- `REPO_INDEXER_EXCLUDE`: **empty**: A comma separated list of glob patterns (see https://github.com/gobwas/glob) to **exclude** from the index. Files that match this list will not be indexed, even if they match in `REPO_INDEXER_INCLUDE`.
|
||||
- `UPDATE_BUFFER_LEN`: **20**: Buffer length of index request.
|
||||
- `MAX_FILE_SIZE`: **1048576**: Maximum size in bytes of files to be indexed.
|
||||
- `STARTUP_TIMEOUT`: **30s**: If the indexer takes longer than this timeout to start - fail. (This timeout will be added to the hammer time above for child processes - as bleve will not start until the previous parent is shutdown.) Set to zero to never timeout.
|
||||
|
||||
## Queue (`queue` and `queue.*`)
|
||||
|
||||
- `TYPE`: **persistable-channel**: General queue type, currently support: `persistable-channel`, `channel`, `level`, `redis`, `dummy`
|
||||
- `DATADIR`: **queues/**: Base DataDir for storing persistent and level queues. `DATADIR` for inidividual queues can be set in `queue.name` sections but will default to `DATADIR/`**`name`**.
|
||||
- `LENGTH`: **20**: Maximal queue size before channel queues block
|
||||
- `BATCH_LENGTH`: **20**: Batch data before passing to the handler
|
||||
- `CONN_STR`: **addrs=127.0.0.1:6379 db=0**: Connection string for the redis queue type.
|
||||
- `QUEUE_NAME`: **_queue**: The suffix for default redis queue name. Individual queues will default to **`name`**`QUEUE_NAME` but can be overriden in the specific `queue.name` section.
|
||||
- `WRAP_IF_NECESSARY`: **true**: Will wrap queues with a timeoutable queue if the selected queue is not ready to be created - (Only relevant for the level queue.)
|
||||
- `MAX_ATTEMPTS`: **10**: Maximum number of attempts to create the wrapped queue
|
||||
- `TIMEOUT`: **GRACEFUL_HAMMER_TIME + 30s**: Timeout the creation of the wrapped queue if it takes longer than this to create.
|
||||
- Queues by default come with a dynamically scaling worker pool. The following settings configure this:
|
||||
- `WORKERS`: **1**: Number of initial workers for the queue.
|
||||
- `MAX_WORKERS`: **10**: Maximum number of worker go-routines for the queue.
|
||||
- `BLOCK_TIMEOUT`: **1s**: If the queue blocks for this time, boost the number of workers - the `BLOCK_TIMEOUT` will then be doubled before boosting again whilst the boost is ongoing.
|
||||
- `BOOST_TIMEOUT`: **5m**: Boost workers will timeout after this long.
|
||||
- `BOOST_WORKERS`: **5**: This many workers will be added to the worker pool if there is a boost.
|
||||
|
||||
## Admin (`admin`)
|
||||
- `DEFAULT_EMAIL_NOTIFICATIONS`: **enabled**: Default configuration for email notifications for users (user configurable). Options: enabled, onmention, disabled
|
||||
@@ -207,6 +275,7 @@ relation to port exhaustion.
|
||||
authentication provided email.
|
||||
- `DISABLE_GIT_HOOKS`: **false**: Set to `true` to prevent all users (including admin) from creating custom
|
||||
git hooks.
|
||||
- `ONLY_ALLOW_PUSH_IF_GITEA_ENVIRONMENT_SET`: **true**: Set to `false` to allow local users to push to gitea-repositories without setting up the Gitea environment. This is not recommended and if you want local users to push to gitea repositories you should set the environment appropriately.
|
||||
- `IMPORT_LOCAL_PATHS`: **false**: Set to `false` to prevent all users (including admin) from importing local path on server.
|
||||
- `INTERNAL_TOKEN`: **\<random at every install if no uri set\>**: Secret used to validate communication within Gitea binary.
|
||||
- `INTERNAL_TOKEN_URI`: **<empty>**: Instead of defining internal token in the configuration, this configuration option can be used to give Gitea a path to a file that contains the internal token (example value: `file:/etc/gitea/internal_token`)
|
||||
@@ -243,6 +312,10 @@ relation to port exhaustion.
|
||||
- `REQUIRE_SIGNIN_VIEW`: **false**: Enable this to force users to log in to view any page.
|
||||
- `ENABLE_NOTIFY_MAIL`: **false**: Enable this to send e-mail to watchers of a repository when
|
||||
something happens, like creating issues. Requires `Mailer` to be enabled.
|
||||
- `ENABLE_BASIC_AUTHENTICATION`: **true**: Disable this to disallow authenticaton using HTTP
|
||||
BASIC and the user's password. Please note if you disable this you will not be able to access the
|
||||
tokens API endpoints using a password. Further, this only disables BASIC authentication using the
|
||||
password - not tokens or OAuth Basic.
|
||||
- `ENABLE_REVERSE_PROXY_AUTHENTICATION`: **false**: Enable this to allow reverse proxy authentication.
|
||||
- `ENABLE_REVERSE_PROXY_AUTO_REGISTRATION`: **false**: Enable this to allow auto-registration
|
||||
for reverse authentication.
|
||||
@@ -256,13 +329,19 @@ relation to port exhaustion.
|
||||
- `RECAPTCHA_SITEKEY`: **""**: Go to https://www.google.com/recaptcha/admin to get a sitekey for recaptcha.
|
||||
- `RECAPTCHA_URL`: **https://www.google.com/recaptcha/**: Set the recaptcha url - allows the use of recaptcha net.
|
||||
- `DEFAULT_ENABLE_DEPENDENCIES`: **true**: Enable this to have dependencies enabled by default.
|
||||
- `ALLOW_CROSS_REPOSITORY_DEPENDENCIES` : **true** Enable this to allow dependencies on issues from any repository where the user is granted access.
|
||||
- `ENABLE_USER_HEATMAP`: **true**: Enable this to display the heatmap on users profiles.
|
||||
- `EMAIL_DOMAIN_WHITELIST`: **\<empty\>**: If non-empty, list of domain names that can only be used to register
|
||||
on this instance.
|
||||
- `SHOW_REGISTRATION_BUTTON`: **! DISABLE\_REGISTRATION**: Show Registration Button
|
||||
- `SHOW_MILESTONES_DASHBOARD_PAGE`: **true** Enable this to show the milestones dashboard page - a view of all the user's milestones
|
||||
- `AUTO_WATCH_NEW_REPOS`: **true**: Enable this to let all organisation users watch new repos when they are created
|
||||
- `AUTO_WATCH_ON_CHANGES`: **false**: Enable this to make users watch a repository after their first commit to it
|
||||
- `DEFAULT_ORG_VISIBILITY`: **public**: Set default visibility mode for organisations, either "public", "limited" or "private".
|
||||
- `DEFAULT_ORG_MEMBER_VISIBLE`: **false** True will make the membership of the users visible when added to the organisation.
|
||||
- `ALLOW_ONLY_EXTERNAL_REGISTRATION`: **false** Set to true to force registration only using third-party services.
|
||||
- `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.
|
||||
The user's email will be replaced with a concatenation of the user name in lower case, "@" and NO_REPLY_ADDRESS.
|
||||
|
||||
## Webhook (`webhook`)
|
||||
|
||||
@@ -270,6 +349,8 @@ relation to port exhaustion.
|
||||
- `DELIVER_TIMEOUT`: **5**: Delivery timeout (sec) for shooting webhooks.
|
||||
- `SKIP_TLS_VERIFY`: **false**: Allow insecure certification.
|
||||
- `PAGING_NUM`: **10**: Number of webhook history events that are shown in one page.
|
||||
- `PROXY_URL`: ****: Proxy server URL, support http://, https//, socks://, blank will follow environment http_proxy/https_proxy
|
||||
- `PROXY_HOSTS`: ****: Comma separated list of host names requiring proxy. Glob patterns (*) are accepted; use ** to match all hosts.
|
||||
|
||||
## Mailer (`mailer`)
|
||||
|
||||
@@ -353,7 +434,7 @@ relation to port exhaustion.
|
||||
NB: You must `REDIRECT_MACARON_LOG` and have `DISABLE_ROUTER_LOG` set to `false` for this option to take effect. Configure each mode in per mode log subsections `\[log.modename.router\]`.
|
||||
- `ENABLE_ACCESS_LOG`: **false**: Creates an access.log in NCSA common log format, or as per the following template
|
||||
- `ACCESS`: **file**: Logging mode for the access logger, use a comma to separate values. Configure each mode in per mode log subsections `\[log.modename.access\]`. By default the file mode will log to `$ROOT_PATH/access.log`. (If you set this to `,` it will log to the default gitea logger.)
|
||||
- `ACCESS_LOG_TEMPLATE`: **`{{.Ctx.RemoteAddr}} - {{.Identity}} {{.Start.Format "[02/Jan/2006:15:04:05 -0700]" }} "{{.Ctx.Req.Method}} {{.Ctx.Req.RequestURI}} {{.Ctx.Req.Proto}}" {{.ResponseWriter.Status}} {{.ResponseWriter.Size}} "{{.Ctx.Req.Referer}}\" \"{{.Ctx.Req.UserAgent}}"`**: Sets the template used to create the access log.
|
||||
- `ACCESS_LOG_TEMPLATE`: **`{{.Ctx.RemoteAddr}} - {{.Identity}} {{.Start.Format "[02/Jan/2006:15:04:05 -0700]" }} "{{.Ctx.Req.Method}} {{.Ctx.Req.URL.RequestURI}} {{.Ctx.Req.Proto}}" {{.ResponseWriter.Status}} {{.ResponseWriter.Size}} "{{.Ctx.Req.Referer}}\" \"{{.Ctx.Req.UserAgent}}"`**: Sets the template used to create the access log.
|
||||
- The following variables are available:
|
||||
- `Ctx`: the `macaron.Context` of the request.
|
||||
- `Identity`: the SignedUserName or `"-"` if not logged in.
|
||||
@@ -441,6 +522,8 @@ NB: You must `REDIRECT_MACARON_LOG` and have `DISABLE_ROUTER_LOG` set to `false`
|
||||
- `MAX_GIT_DIFF_FILES`: **100**: Max number of files shown in diff view.
|
||||
- `GC_ARGS`: **\<empty\>**: Arguments for command `git gc`, e.g. `--aggressive --auto`. See more on http://git-scm.com/docs/git-gc/
|
||||
- `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
|
||||
- `VERBOSE_PUSH`: **true**: Print status information about pushes as they are being processed.
|
||||
- `VERBOSE_PUSH_DELAY`: **5s**: Only print verbose information if push takes longer than this delay.
|
||||
|
||||
## Git - Timeout settings (`git.timeout`)
|
||||
- `DEFAUlT`: **360**: Git operations default timeout seconds.
|
||||
@@ -511,13 +594,13 @@ Gitea can support Markup using external tools. The example below will add a mark
|
||||
|
||||
```ini
|
||||
[markup.asciidoc]
|
||||
ENABLED = false
|
||||
ENABLED = true
|
||||
FILE_EXTENSIONS = .adoc,.asciidoc
|
||||
RENDER_COMMAND = "asciidoc --out-file=- -"
|
||||
IS_INPUT_FILE = false
|
||||
```
|
||||
|
||||
- ENABLED: **false** Enable markup support.
|
||||
- ENABLED: **false** Enable markup support; set to **true** to enable this renderer.
|
||||
- FILE\_EXTENSIONS: **\<empty\>** List of file extensions that should be rendered by an external
|
||||
command. Multiple extentions needs a comma as splitter.
|
||||
- RENDER\_COMMAND: External command to render all matching extensions.
|
||||
@@ -527,6 +610,24 @@ Two special environment variables are passed to the render command:
|
||||
- `GITEA_PREFIX_SRC`, which contains the current URL prefix in the `src` path tree. To be used as prefix for links.
|
||||
- `GITEA_PREFIX_RAW`, which contains the current URL prefix in the `raw` path tree. To be used as prefix for image paths.
|
||||
|
||||
|
||||
Gitea supports customizing the sanitization policy for rendered HTML. The example below will support KaTeX output from pandoc.
|
||||
|
||||
```ini
|
||||
[markup.sanitizer]
|
||||
; Pandoc renders TeX segments as <span>s with the "math" class, optionally
|
||||
; with "inline" or "display" classes depending on context.
|
||||
ELEMENT = span
|
||||
ALLOW_ATTR = class
|
||||
REGEXP = ^\s*((math(\s+|$)|inline(\s+|$)|display(\s+|$)))+
|
||||
```
|
||||
|
||||
- `ELEMENT`: The element this policy applies to. Must be non-empty.
|
||||
- `ALLOW_ATTR`: The attribute this policy allows. Must be non-empty.
|
||||
- `REGEXP`: A regex to match the contents of the attribute against. Must be present but may be empty for unconditional whitelisting of this attribute.
|
||||
|
||||
You may redefine `ELEMENT`, `ALLOW_ATTR`, and `REGEXP` multiple times; each time all three are defined is a single policy entry.
|
||||
|
||||
## Time (`time`)
|
||||
|
||||
- `FORMAT`: Time format to diplay on UI. i.e. RFC1123 or 2006-01-02 15:04:05
|
||||
@@ -534,10 +635,16 @@ Two special environment variables are passed to the render command:
|
||||
|
||||
## Task (`task`)
|
||||
|
||||
- Task queue configuration has been moved to `queue.task` however, the below configuration values are kept for backwards compatibilityx:
|
||||
- `QUEUE_TYPE`: **channel**: Task queue type, could be `channel` or `redis`.
|
||||
- `QUEUE_LENGTH`: **1000**: Task queue length, available only when `QUEUE_TYPE` is `channel`.
|
||||
- `QUEUE_CONN_STR`: **addrs=127.0.0.1:6379 db=0**: Task queue connection string, available only when `QUEUE_TYPE` is `redis`. If there redis needs a password, use `addrs=127.0.0.1:6379 password=123 db=0`.
|
||||
|
||||
## Migrations (`migrations`)
|
||||
|
||||
- `MAX_ATTEMPTS`: **3**: Max attempts per http/https request on migrations.
|
||||
- `RETRY_BACKOFF`: **3**: Backoff time per http/https request retry (seconds)
|
||||
|
||||
## Other (`other`)
|
||||
|
||||
- `SHOW_FOOTER_BRANDING`: **false**: Show Gitea branding in the footer.
|
||||
|
@@ -37,7 +37,8 @@ menu:
|
||||
|
||||
- `EXPLORE_PAGING_NUM`: 探索页面每页显示的仓库数量。
|
||||
- `ISSUE_PAGING_NUM`: 工单页面每页显示的工单数量。
|
||||
- `FEED_MAX_COMMIT_NUM`: 活动流页面显示的最大提交树木。
|
||||
- `MEMBERS_PAGING_NUM`: **20**: 组织成员页面每页显示的成员数量。
|
||||
- `FEED_MAX_COMMIT_NUM`: 活动流页面显示的最大提交数量。
|
||||
|
||||
### UI - Admin (`ui.admin`)
|
||||
|
||||
@@ -65,6 +66,7 @@ menu:
|
||||
- `CERT_FILE`: 启用HTTPS的证书文件。
|
||||
- `KEY_FILE`: 启用HTTPS的密钥文件。
|
||||
- `STATIC_ROOT_PATH`: 存放模板和静态文件的根目录,默认是 Gitea 的根目录。
|
||||
- `STATIC_CACHE_TIME`: **6h**: 静态资源文件,包括 `custom/`, `public/` 和所有上传的头像的浏览器缓存时间。
|
||||
- `ENABLE_GZIP`: 启用应用级别的 GZIP 压缩。
|
||||
- `LANDING_PAGE`: 未登录用户的默认页面,可选 `home` 或 `explore`。
|
||||
- `LFS_START_SERVER`: 是否启用 git-lfs 支持. 可以为 `true` 或 `false`, 默认是 `false`。
|
||||
@@ -110,7 +112,7 @@ menu:
|
||||
|
||||
## Service (`service`)
|
||||
|
||||
- `ACTIVE_CODE_LIVE_MINUTES`: 登陆验证码失效时间,单位分钟。
|
||||
- `ACTIVE_CODE_LIVE_MINUTES`: 登录验证码失效时间,单位分钟。
|
||||
- `RESET_PASSWD_CODE_LIVE_MINUTES`: 重置密码失效时间,单位分钟。
|
||||
- `REGISTER_EMAIL_CONFIRM`: 启用注册邮件激活,前提是 `Mailer` 已经启用。
|
||||
- `DISABLE_REGISTRATION`: 禁用注册,启用后只能用管理员添加用户。
|
||||
@@ -128,6 +130,8 @@ menu:
|
||||
- `DELIVER_TIMEOUT`: 请求webhooks的超时时间,单位秒。
|
||||
- `SKIP_TLS_VERIFY`: 是否允许不安全的证书。
|
||||
- `PAGING_NUM`: 每页显示的Webhook 历史数量。
|
||||
- `PROXY_URL`: ****: 代理服务器网址,支持 http://, https//, socks://, 为空将使用环境变量中的 http_proxy/https_proxy 设置。
|
||||
- `PROXY_HOSTS`: ****: 逗号分隔的需要代理的域名或IP地址。支持 * 号匹配符,使用 ** 匹配所有域名和IP地址。
|
||||
|
||||
## Mailer (`mailer`)
|
||||
|
||||
@@ -172,6 +176,20 @@ menu:
|
||||
- `MAX_SIZE`: 附件最大限制,单位 MB,比如: `4`。
|
||||
- `MAX_FILES`: 一次最多上传的附件数量,比如: `5`。
|
||||
|
||||
关于 `ALLOWED_TYPES`, 在 (*)unix 系统中可以使用`file -I <filename>` 来快速获得对应的 `MIME type`。
|
||||
|
||||
```shell
|
||||
$ file -I test00.tar.xz
|
||||
test00.tar.xz: application/x-xz; charset=binary
|
||||
|
||||
$ file --mime test00.xlsx
|
||||
test00.xlsx: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet; charset=binary
|
||||
|
||||
file -I test01.xls
|
||||
test01.xls: application/vnd.ms-excel; charset=binary
|
||||
```
|
||||
|
||||
|
||||
## Log (`log`)
|
||||
|
||||
- `ROOT_PATH`: 日志文件根目录。
|
||||
@@ -255,6 +273,11 @@ IS_INPUT_FILE = false
|
||||
- `QUEUE_LENGTH`: **1000**: 任务队列长度,当 `QUEUE_TYPE` 为 `channel` 时有效。
|
||||
- `QUEUE_CONN_STR`: **addrs=127.0.0.1:6379 db=0**: 任务队列连接字符串,当 `QUEUE_TYPE` 为 `redis` 时有效。如果redis有密码,则可以 `addrs=127.0.0.1:6379 password=123 db=0`。
|
||||
|
||||
## Migrations (`migrations`)
|
||||
|
||||
- `MAX_ATTEMPTS`: **3**: 在迁移过程中的 http/https 请求重试次数。
|
||||
- `RETRY_BACKOFF`: **3**: 等待下一次重试的时间,单位秒。
|
||||
|
||||
## Other (`other`)
|
||||
|
||||
- `SHOW_FOOTER_BRANDING`: 为真则在页面底部显示Gitea的字样。
|
||||
|
@@ -44,12 +44,6 @@ environment variable; this can be used to override the default path to something
|
||||
|
||||
**Note:** Gitea must perform a full restart to see configuration changes.
|
||||
|
||||
## Customizing /robots.txt
|
||||
|
||||
To make Gitea serve a custom `/robots.txt` (default: empty 404), create a file called
|
||||
`robots.txt` in the `custom` folder (or `CustomPath`) with
|
||||
[expected contents](http://www.robotstxt.org/).
|
||||
|
||||
## Serving custom public files
|
||||
|
||||
To make Gitea serve custom public files (like pages and images), use the folder
|
||||
@@ -65,19 +59,25 @@ Place the png image at the following path: `custom/public/img/avatar_default.png
|
||||
## Customizing Gitea pages
|
||||
|
||||
The `custom/templates` folder allows changing every single page of Gitea. Templates
|
||||
to override can be found in the [`templates`](https://github.com/go-gitea/gitea/tree/master/templates) directory of Gitea source. Override by
|
||||
to override can be found in the [`templates`](https://github.com/go-gitea/gitea/tree/master/templates) directory of Gitea source (Note: the example link is from `master` branch. Make sure to copy templates from same release you are using). Override by
|
||||
making a copy of the file under `custom/templates` using a full path structure
|
||||
matching source.
|
||||
|
||||
Any statement contained inside `{{` and `}}` are Gitea's template syntax and
|
||||
shouldn't be touched without fully understanding these components.
|
||||
|
||||
### Customizing startpage / homepage
|
||||
|
||||
Copy [`home.tmpl`](https://github.com/go-gitea/gitea/blob/master/templates/home.tmpl) for your version of Gitea from `templates` to `custom/templates`.
|
||||
Edit as you wish.
|
||||
Dont forget to restart your gitea to apply the changes.
|
||||
|
||||
### Adding links and tabs
|
||||
|
||||
If all you want is to add extra links to the top navigation bar, or extra tabs to the repository view, you can put them in `extra_links.tmpl` and `extra_tabs.tmpl` inside your `custom/templates/custom/` directory.
|
||||
If all you want is to add extra links to the top navigation bar or footer, or extra tabs to the repository view, you can put them in `extra_links.tmpl` (links added to the navbar), `extra_links_footer.tmpl` (links added to the left side of footer), and `extra_tabs.tmpl` inside your `custom/templates/custom/` directory.
|
||||
|
||||
For instance, let's say you are in Germany and must add the famously legally-required "Impressum"/about page, listing who is responsible for the site's content:
|
||||
just place it under your "custom/public/" directory (for instance `custom/public/impressum.html`) and put a link to it in `custom/templates/custom/extra_links.tmpl`.
|
||||
just place it under your "custom/public/" directory (for instance `custom/public/impressum.html`) and put a link to it in either `custom/templates/custom/extra_links.tmpl` or `custom/templates/custom/extra_links_footer.tmpl`.
|
||||
|
||||
To match the current style, the link should have the class name "item", and you can use `{{AppSubUrl}}` to get the base URL:
|
||||
`<a class="item" href="{{AppSubUrl}}/impressum.html">Impressum</a>`
|
||||
@@ -140,7 +140,7 @@ To add a custom license, add a file with the license text to `custom/options/lic
|
||||
Locales are managed via our [crowdin](https://crowdin.com/project/gitea).
|
||||
You can override a locale by placing an altered locale file in `custom/options/locale`.
|
||||
Gitea's default locale files can be found in the [`options/locale`](https://github.com/go-gitea/gitea/tree/master/options/locale) source folder and these should be used as examples for your changes.
|
||||
|
||||
|
||||
To add a completely new locale, as well as placing the file in the above location, you will need to add the new lang and name to the `[i18n]` section in your `app.ini`. Keep in mind that Gitea will use those settings as **overrides**, so if you want to keep the other languages as well you will need to copy/paste the default values and add your own to them.
|
||||
|
||||
```
|
||||
@@ -155,6 +155,15 @@ Locales may change between versions, so keeping track of your customized locales
|
||||
|
||||
To add a custom Readme, add a markdown formatted file (without an `.md` extension) to `custom/options/readme`
|
||||
|
||||
### Reactions
|
||||
|
||||
To change reaction emoji's you can set allowed reactions at app.ini
|
||||
```
|
||||
[ui]
|
||||
REACTIONS = +1, -1, laugh, confused, heart, hooray, eyes
|
||||
```
|
||||
A full list of supported emoji's is at [emoji list](https://gitea.com/gitea/gitea.com/issues/8)
|
||||
|
||||
## Customizing the look of Gitea
|
||||
|
||||
As of version 1.6.0 Gitea has built-in themes. The two built-in themes are, the default theme `gitea`, and a dark theme `arc-green`. To change the look of your Gitea install change the value of `DEFAULT_THEME` in the [ui](https://docs.gitea.io/en-us/config-cheat-sheet/#ui-ui) section of `app.ini` to another one of the available options.
|
||||
|
@@ -51,7 +51,7 @@ add one `[markup.XXXXX]` section per external renderer on your custom `app.ini`:
|
||||
[markup.asciidoc]
|
||||
ENABLED = true
|
||||
FILE_EXTENSIONS = .adoc,.asciidoc
|
||||
RENDER_COMMAND = "asciidoctor --out-file=- -"
|
||||
RENDER_COMMAND = "asciidoctor -e -a leveloffset=-1 --out-file=- -"
|
||||
; Input is not a standard input but a file
|
||||
IS_INPUT_FILE = false
|
||||
|
||||
@@ -68,4 +68,22 @@ RENDER_COMMAND = rst2html.py
|
||||
IS_INPUT_FILE = false
|
||||
```
|
||||
|
||||
If your external markup relies on additional classes and attributes on the generated HTML elements, you might need to enable custom sanitizer policies. Gitea uses the [`bluemonday`](https://godoc.org/github.com/microcosm-cc/bluemonday) package as our HTML sanitizier. The example below will support [KaTeX](https://katex.org/) output from [`pandoc`](https://pandoc.org/).
|
||||
|
||||
```ini
|
||||
[markup.sanitizer]
|
||||
; Pandoc renders TeX segments as <span>s with the "math" class, optionally
|
||||
; with "inline" or "display" classes depending on context.
|
||||
ELEMENT = span
|
||||
ALLOW_ATTR = class
|
||||
REGEXP = ^\s*((math(\s+|$)|inline(\s+|$)|display(\s+|$)))+
|
||||
|
||||
[markup.markdown]
|
||||
ENABLED = true
|
||||
FILE_EXTENSIONS = .md,.markdown
|
||||
RENDER_COMMAND = pandoc -f markdown -t html --katex
|
||||
```
|
||||
|
||||
You may redefine `ELEMENT`, `ALLOW_ATTR`, and `REGEXP` multiple times; each time all three are defined is a single policy entry. All three must be defined, but `REGEXP` may be blank to allow unconditional whitelisting of that attribute.
|
||||
|
||||
Once your configuration changes have been made, restart Gitea to have changes take effect.
|
||||
|
@@ -23,6 +23,10 @@ environment variable and to add the go bin directory or directories
|
||||
`${GOPATH//://bin:}/bin` to the `$PATH`. See the Go wiki entry for
|
||||
[GOPATH](https://github.com/golang/go/wiki/GOPATH).
|
||||
|
||||
Next, [install Node.js with npm](https://nodejs.org/en/download/) which is
|
||||
required to build the JavaScript and CSS files. The minimum supported Node.js
|
||||
version is 10 and the latest LTS version is recommended.
|
||||
|
||||
You will also need make.
|
||||
<a href='{{< relref "doc/advanced/make.en-us.md" >}}'>(See here how to get Make)</a>
|
||||
|
||||
@@ -98,7 +102,7 @@ from source</a>.
|
||||
The simplest recommended way to build from source is:
|
||||
|
||||
```bash
|
||||
TAGS="bindata sqlite sqlite_unlock_notify" make generate build
|
||||
TAGS="bindata sqlite sqlite_unlock_notify" make build
|
||||
```
|
||||
|
||||
However, there are a number of additional make tasks you should be aware of.
|
||||
@@ -136,24 +140,24 @@ You should run revive, vet and spell-check on the code with:
|
||||
make revive vet misspell-check
|
||||
```
|
||||
|
||||
### Updating CSS
|
||||
### Working on CSS
|
||||
|
||||
To generate the CSS, you will need [Node.js](https://nodejs.org/) 8.0 or greater with npm. At present we use [less](http://lesscss.org/) and [postcss](https://postcss.org) to generate our CSS. Do **not** edit the files in `public/css` directly, as they are generated from `lessc` from the files in `public/less`.
|
||||
|
||||
Edit files in `public/less`, run the linter, regenerate the CSS and commit all changed files:
|
||||
Edit files in `web_src/less` and run the linter and build the CSS files via:
|
||||
|
||||
```bash
|
||||
make css
|
||||
```
|
||||
|
||||
### Updating JS
|
||||
### Working on JS
|
||||
|
||||
To run the JavaScript linter you will need [Node.js](https://nodejs.org/) 8.0 or greater with npm. Edit files in `public/js` and run the linter:
|
||||
Edit files in `web_src/js`, run the linter and build the JS files via:
|
||||
|
||||
```bash
|
||||
make js
|
||||
```
|
||||
|
||||
Note: When working on frontend code, it is advisable to set `USE_SERVICE_WORKER` to `false` in `app.ini` which will prevent undesirable caching of frontend assets.
|
||||
|
||||
### Updating the API
|
||||
|
||||
When creating new API routes or modifying existing API routes, you **MUST**
|
||||
@@ -233,7 +237,7 @@ Unit tests will not and cannot completely test Gitea alone. Therefore, we
|
||||
have written integration tests; however, these are database dependent.
|
||||
|
||||
```bash
|
||||
TAGS="bindata sqlite sqlite_unlock_notify" make generate build test-sqlite
|
||||
TAGS="bindata sqlite sqlite_unlock_notify" make build test-sqlite
|
||||
```
|
||||
|
||||
will run the integration tests in an sqlite environment. Other database tests
|
||||
|
@@ -143,7 +143,7 @@ log using the value: `ACCESS = ,`
|
||||
|
||||
This value represent a go template. It's default value is:
|
||||
|
||||
`{{.Ctx.RemoteAddr}} - {{.Identity}} {{.Start.Format "[02/Jan/2006:15:04:05 -0700]" }} "{{.Ctx.Req.Method}} {{.Ctx.Req.RequestURI}} {{.Ctx.Req.Proto}}" {{.ResponseWriter.Status}} {{.ResponseWriter.Size}} "{{.Ctx.Req.Referer}}\" \"{{.Ctx.Req.UserAgent}}"`
|
||||
`{{.Ctx.RemoteAddr}} - {{.Identity}} {{.Start.Format "[02/Jan/2006:15:04:05 -0700]" }} "{{.Ctx.Req.Method}} {{.Ctx.Req.URL.RequestURI}} {{.Ctx.Req.Proto}}" {{.ResponseWriter.Status}} {{.ResponseWriter.Size}} "{{.Ctx.Req.Referer}}\" \"{{.Ctx.Req.UserAgent}}"`
|
||||
|
||||
The template is passed following options:
|
||||
|
||||
|
276
docs/content/doc/advanced/mail-templates-us.md
Normal file
276
docs/content/doc/advanced/mail-templates-us.md
Normal file
@@ -0,0 +1,276 @@
|
||||
---
|
||||
date: "2019-10-23T17:00:00-03:00"
|
||||
title: "Mail templates"
|
||||
slug: "mail-templates"
|
||||
weight: 45
|
||||
toc: true
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
parent: "advanced"
|
||||
name: "Mail templates"
|
||||
weight: 45
|
||||
identifier: "mail-templates"
|
||||
---
|
||||
|
||||
# Mail templates
|
||||
|
||||
To craft the e-mail subject and contents for certain operations, Gitea can be customized by using templates. The templates
|
||||
for these functions are located under the [`custom` directory](https://docs.gitea.io/en-us/customizing-gitea/).
|
||||
Gitea has an internal template that serves as default in case there's no custom alternative.
|
||||
|
||||
Custom templates are loaded when Gitea starts. Changes made to them are not recognized until Gitea is restarted again.
|
||||
|
||||
## Mail notifications supporting templates
|
||||
|
||||
Currently, the following notification events make use of templates:
|
||||
|
||||
| Action name | Usage |
|
||||
|---------------|--------------------------------------------------------------------------------------------------------------|
|
||||
| `new` | A new issue or pull request was created. |
|
||||
| `comment` | A new comment was created in an existing issue or pull request. |
|
||||
| `close` | An issue or pull request was closed. |
|
||||
| `reopen` | An issue or pull request was reopened. |
|
||||
| `review` | The head comment of a review in a pull request. |
|
||||
| `approve` | The head comment of a approving review for a pull request. |
|
||||
| `reject` | The head comment of a review requesting changes for a pull request. |
|
||||
| `code` | A single comment on the code of a pull request. |
|
||||
| `assigned` | Used was assigned to an issue or pull request. |
|
||||
| `default` | Any action not included in the above categories, or when the corresponding category template is not present. |
|
||||
|
||||
The path for the template of a particular message type is:
|
||||
|
||||
```
|
||||
custom/templates/mail/{action type}/{action name}.tmpl
|
||||
```
|
||||
|
||||
Where `{action type}` is one of `issue` or `pull` (for pull requests), and `{action name}` is one of the names listed above.
|
||||
|
||||
For example, the specific template for a mail regarding a comment in a pull request is:
|
||||
```
|
||||
custom/templates/mail/pull/comment.tmpl
|
||||
```
|
||||
|
||||
However, creating templates for each and every action type/name combination is not required.
|
||||
A fallback system is used to choose the appropriate template for an event. The _first existing_
|
||||
template on this list is used:
|
||||
|
||||
* The specific template for the desired **action type** and **action name**.
|
||||
* The template for action type `issue` and the desired **action name**.
|
||||
* The template for the desired **action type**, action name `default`.
|
||||
* The template for action type `issue`, action name `default`.
|
||||
|
||||
The only mandatory template is action type `issue`, action name `default`, which is already embedded in Gitea
|
||||
unless it's overridden by the user in the `custom` directory.
|
||||
|
||||
## Template syntax
|
||||
|
||||
Mail templates are UTF-8 encoded text files that need to follow one of the following formats:
|
||||
|
||||
```
|
||||
Text and macros for the subject line
|
||||
------------
|
||||
Text and macros for the mail body
|
||||
```
|
||||
|
||||
or
|
||||
|
||||
```
|
||||
Text and macros for the mail body
|
||||
```
|
||||
|
||||
Specifying a _subject_ section is optional (and therefore also the dash line separator). When used, the separator between
|
||||
_subject_ and _mail body_ templates requires at least three dashes; no other characters are allowed in the separator line.
|
||||
|
||||
|
||||
_Subject_ and _mail body_ are parsed by [Golang's template engine](https://golang.org/pkg/text/template/) and
|
||||
are provided with a _metadata context_ assembled for each notification. The context contains the following elements:
|
||||
|
||||
| Name | Type | Available | Usage |
|
||||
|--------------------|------------------|---------------|------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||
| `.FallbackSubject` | string | Always | A default subject line. See Below. |
|
||||
| `.Subject` | string | Only in body | The _subject_, once resolved. |
|
||||
| `.Body` | string | Always | The message of the issue, pull request or comment, parsed from Markdown into HTML and sanitized. Do not confuse with the _mail body_. |
|
||||
| `.Link` | string | Always | The address of the originating issue, pull request or comment. |
|
||||
| `.Issue` | models.Issue | Always | The issue (or pull request) originating the notification. To get data specific to a pull request (e.g. `HasMerged`), `.Issue.PullRequest` can be used, but care should be taken as this field will be `nil` if the issue is *not* a pull request. |
|
||||
| `.Comment` | models.Comment | If applicable | If the notification is from a comment added to an issue or pull request, this will contain the information about the comment. |
|
||||
| `.IsPull` | bool | Always | `true` if the mail notification is associated with a pull request (i.e. `.Issue.PullRequest` is not `nil`). |
|
||||
| `.Repo` | string | Always | Name of the repository, including owner name (e.g. `mike/stuff`) |
|
||||
| `.User` | models.User | Always | Owner of the repository from which the event originated. To get the user name (e.g. `mike`),`.User.Name` can be used. |
|
||||
| `.Doer` | models.User | Always | User that executed the action triggering the notification event. To get the user name (e.g. `rhonda`), `.Doer.Name` can be used. |
|
||||
| `.IsMention` | bool | Always | `true` if this notification was only generated because the user was mentioned in the comment, while not being subscribed to the source. It will be `false` if the recipient was subscribed to the issue or repository. |
|
||||
| `.SubjectPrefix` | string | Always | `Re: ` if the notification is about other than issue or pull request creation; otherwise an empty string. |
|
||||
| `.ActionType` | string | Always | `"issue"` or `"pull"`. Will correspond to the actual _action type_ independently of which template was selected. |
|
||||
| `.ActionName` | string | Always | It will be one of the action types described above (`new`, `comment`, etc.), and will correspond to the actual _action name_ independently of which template was selected. |
|
||||
| `.ReviewComments` | []models.Comment | Always | List of code comments in a review. The comment text will be in `.RenderedContent` and the referenced code will be in `.Patch`. |
|
||||
|
||||
All names are case sensitive.
|
||||
|
||||
### The _subject_ part of the template
|
||||
|
||||
The template engine used for the mail _subject_ is golang's [`text/template`](https://golang.org/pkg/text/template/).
|
||||
Please refer to the linked documentation for details about its syntax.
|
||||
|
||||
The _subject_ is built using the following steps:
|
||||
|
||||
* A template is selected according to the type of notification and to what templates are present.
|
||||
* The template is parsed and resolved (e.g. `{{.Issue.Index}}` is converted to the number of the issue
|
||||
or pull request).
|
||||
* All space-like characters (e.g. `TAB`, `LF`, etc.) are converted to normal spaces.
|
||||
* All leading, trailing and redundant spaces are removed.
|
||||
* The string is truncated to its first 256 runes (characters).
|
||||
|
||||
If the end result is an empty string, **or** no subject template was available (i.e. the selected template
|
||||
did not include a subject part), Gitea's **internal default** will be used.
|
||||
|
||||
The internal default (fallback) subject is the equivalent of:
|
||||
|
||||
```
|
||||
{{.SubjectPrefix}}[{{.Repo}}] {{.Issue.Title}} (#.Issue.Index)
|
||||
```
|
||||
|
||||
For example: `Re: [mike/stuff] New color palette (#38)`
|
||||
|
||||
Gitea's default subject can also be found in the template _metadata_ as `.FallbackSubject` from any of
|
||||
the two templates, even if a valid subject template is present.
|
||||
|
||||
### The _mail body_ part of the template
|
||||
|
||||
The template engine used for the _mail body_ is golang's [`html/template`](https://golang.org/pkg/html/template/).
|
||||
Please refer to the linked documentation for details about its syntax.
|
||||
|
||||
The _mail body_ is parsed after the mail subject, so there is an additional _metadata_ field which is
|
||||
the actual rendered subject, after all considerations.
|
||||
|
||||
The expected result is HTML (including structural elements like`<html>`, `<body>`, etc.). Styling
|
||||
through `<style>` blocks, `class` and `style` attributes is possible. However, `html/template`
|
||||
does some [automatic escaping](https://golang.org/pkg/html/template/#hdr-Contexts) that should be considered.
|
||||
|
||||
Attachments (such as images or external style sheets) are not supported. However, other templates can
|
||||
be referenced too, for example to provide the contents of a `<style>` element in a centralized fashion.
|
||||
The external template must be placed under `custom/mail` and referenced relative to that directory.
|
||||
For example, `custom/mail/styles/base.tmpl` can be included using `{{template styles/base}}`.
|
||||
|
||||
The mail is sent with `Content-Type: multipart/alternative`, so the body is sent in both HTML
|
||||
and text formats. The latter is obtained by stripping the HTML markup.
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
How a mail is rendered is directly dependent on the capabilities of the mail application. Many mail
|
||||
clients don't even support HTML, so they show the text version included in the generated mail.
|
||||
|
||||
If the template fails to render, it will be noticed only at the moment the mail is sent.
|
||||
A default subject is used if the subject template fails, and whatever was rendered successfully
|
||||
from the the _mail body_ is used, disregarding the rest.
|
||||
|
||||
Please check [Gitea's logs](https://docs.gitea.io/en-us/logging-configuration/) for error messages in case of trouble.
|
||||
|
||||
## Example
|
||||
|
||||
`custom/templates/mail/issue/default.tmpl`:
|
||||
|
||||
```
|
||||
[{{.Repo}}] @{{.Doer.Name}}
|
||||
{{if eq .ActionName "new"}}
|
||||
created
|
||||
{{else if eq .ActionName "comment"}}
|
||||
commented on
|
||||
{{else if eq .ActionName "close"}}
|
||||
closed
|
||||
{{else if eq .ActionName "reopen"}}
|
||||
reopened
|
||||
{{else}}
|
||||
updated
|
||||
{{end}}
|
||||
{{if eq .ActionType "issue"}}
|
||||
issue
|
||||
{{else}}
|
||||
pull request
|
||||
{{end}}
|
||||
#{{.Issue.Index}}: {{.Issue.Title}}
|
||||
------------
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>{{.Subject}}</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
{{if .IsMention}}
|
||||
<p>
|
||||
You are receiving this because @{{.Doer.Name}} mentioned you.
|
||||
</p>
|
||||
{{end}}
|
||||
<p>
|
||||
<p>
|
||||
<a href="{{AppURL}}/{{.Doer.LowerName}}">@{{.Doer.Name}}</a>
|
||||
{{if not (eq .Doer.FullName "")}}
|
||||
({{.Doer.FullName}})
|
||||
{{end}}
|
||||
{{if eq .ActionName "new"}}
|
||||
created
|
||||
{{else if eq .ActionName "close"}}
|
||||
closed
|
||||
{{else if eq .ActionName "reopen"}}
|
||||
reopened
|
||||
{{else}}
|
||||
updated
|
||||
{{end}}
|
||||
<a href="{{.Link}}">{{.Repo}}#{{.Issue.Index}}</a>.
|
||||
</p>
|
||||
{{if not (eq .Body "")}}
|
||||
<h3>Message content:</h3>
|
||||
<hr>
|
||||
{{.Body | Str2html}}
|
||||
{{end}}
|
||||
</p>
|
||||
<hr>
|
||||
<p>
|
||||
<a href="{{.Link}}">View it on Gitea</a>.
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
||||
```
|
||||
|
||||
This template produces something along these lines:
|
||||
|
||||
#### Subject
|
||||
|
||||
> [mike/stuff] @rhonda commented on pull request #38: New color palette
|
||||
|
||||
#### Mail body
|
||||
|
||||
> [@rhonda](#) (Rhonda Myers) updated [mike/stuff#38](#).
|
||||
>
|
||||
> #### Message content:
|
||||
>
|
||||
> \__________________________________________________________________
|
||||
>
|
||||
> Mike, I think we should tone down the blues a little.
|
||||
> \__________________________________________________________________
|
||||
>
|
||||
> [View it on Gitea](#).
|
||||
|
||||
## Advanced
|
||||
|
||||
The template system contains several functions that can be used to further process and format
|
||||
the messages. Here's a list of some of them:
|
||||
|
||||
| Name | Parameters | Available | Usage |
|
||||
|----------------------|-------------|-----------|------------------------------------------------------------------------------|
|
||||
| `AppUrl` | - | Any | Gitea's URL |
|
||||
| `AppName` | - | Any | Set from `app.ini`, usually "Gitea" |
|
||||
| `AppDomain` | - | Any | Gitea's host name |
|
||||
| `EllipsisString` | string, int | Any | Truncates a string to the specified length; adds ellipsis as needed |
|
||||
| `Str2html` | string | Body only | Sanitizes text by removing any HTML tags from it. |
|
||||
| `Safe` | string | Body only | Takes the input as HTML; can be used for `.ReviewComments.RenderedContent`. |
|
||||
|
||||
These are _functions_, not metadata, so they have to be used:
|
||||
|
||||
```
|
||||
Like this: {{Str2html "Escape<my>text"}}
|
||||
Or this: {{"Escape<my>text" | Str2html}}
|
||||
Or this: {{AppUrl}}
|
||||
But not like this: {{.AppUrl}}
|
||||
```
|
39
docs/content/doc/advanced/search-engines-indexation.en-us.md
Normal file
39
docs/content/doc/advanced/search-engines-indexation.en-us.md
Normal file
@@ -0,0 +1,39 @@
|
||||
---
|
||||
date: "2019-12-31T13:55:00+05:00"
|
||||
title: "Advanced: Search Engines Indexation"
|
||||
slug: "search-engines-indexation"
|
||||
weight: 30
|
||||
toc: true
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
parent: "advanced"
|
||||
name: "Search Engines Indexation"
|
||||
weight: 60
|
||||
identifier: "search-engines-indexation"
|
||||
---
|
||||
|
||||
# Search engines indexation of your Gitea installation
|
||||
|
||||
By default your Gitea installation will be indexed by search engines.
|
||||
If you don't want your repository to be visible for search engines read further.
|
||||
|
||||
## Block search engines indexation using robots.txt
|
||||
|
||||
To make Gitea serve a custom `robots.txt` (default: empty 404) for top level installations,
|
||||
create a file called `robots.txt` in the [`custom` folder or `CustomPath`]({{< relref "doc/advanced/customizing-gitea.en-us.md" >}})
|
||||
|
||||
Examples on how to configure the `robots.txt` can be found at [https://moz.com/learn/seo/robotstxt](https://moz.com/learn/seo/robotstxt).
|
||||
|
||||
|
||||
```txt
|
||||
User-agent: *
|
||||
Disallow: /
|
||||
```
|
||||
|
||||
If you installed Gitea in a subdirectory, you will need to create or edit the `robots.txt` in the top level directory.
|
||||
|
||||
```txt
|
||||
User-agent: *
|
||||
Disallow: /gitea/
|
||||
```
|
163
docs/content/doc/advanced/signing.en-us.md
Normal file
163
docs/content/doc/advanced/signing.en-us.md
Normal file
@@ -0,0 +1,163 @@
|
||||
---
|
||||
date: "2019-08-17T10:20:00+01:00"
|
||||
title: "GPG Commit Signatures"
|
||||
slug: "signing"
|
||||
weight: 20
|
||||
toc: false
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
parent: "advanced"
|
||||
name: "GPG Commit Signatures"
|
||||
weight: 20
|
||||
identifier: "signing"
|
||||
---
|
||||
|
||||
# GPG Commit Signatures
|
||||
|
||||
Gitea will verify GPG commit signatures in the provided tree by
|
||||
checking if the commits are signed by a key within the gitea database,
|
||||
or if the commit matches the default key for git.
|
||||
|
||||
Keys are not checked to determine if they have expired or revoked.
|
||||
Keys are also not checked with keyservers.
|
||||
|
||||
A commit will be marked with a grey unlocked icon if no key can be
|
||||
found to verify it. If a commit is marked with a red unlocked icon,
|
||||
it is reported to be signed with a key with an id.
|
||||
|
||||
Please note: The signer of a commit does not have to be an author or
|
||||
committer of a commit.
|
||||
|
||||
This functionality requires git >= 1.7.9 but for full functionality
|
||||
this requires git >= 2.0.0.
|
||||
|
||||
## Automatic Signing
|
||||
|
||||
There are a number of places where Gitea will generate commits itself:
|
||||
|
||||
* Repository Initialisation
|
||||
* Wiki Changes
|
||||
* CRUD actions using the editor or the API
|
||||
* Merges from Pull Requests
|
||||
|
||||
Depending on configuration and server trust you may want Gitea to
|
||||
sign these commits.
|
||||
|
||||
## General Configuration
|
||||
|
||||
Gitea's configuration for signing can be found with the
|
||||
`[repository.signing]` section of `app.ini`:
|
||||
|
||||
```ini
|
||||
...
|
||||
[repository.signing]
|
||||
SIGNING_KEY = default
|
||||
SIGNING_NAME =
|
||||
SIGNING_EMAIL =
|
||||
INITIAL_COMMIT = always
|
||||
CRUD_ACTIONS = pubkey, twofa, parentsigned
|
||||
WIKI = never
|
||||
MERGES = pubkey, twofa, basesigned, commitssigned
|
||||
|
||||
...
|
||||
```
|
||||
|
||||
### `SIGNING_KEY`
|
||||
|
||||
The first option to discuss is the `SIGNING_KEY`. There are three main
|
||||
options:
|
||||
|
||||
* `none` - this prevents Gitea from signing any commits
|
||||
* `default` - Gitea will default to the key configured within
|
||||
`git config`
|
||||
* `KEYID` - Gitea will sign commits with the gpg key with the ID
|
||||
`KEYID`. In this case you should provide a `SIGNING_NAME` and
|
||||
`SIGNING_EMAIL` to be displayed for this key.
|
||||
|
||||
The `default` option will interrogate `git config` for
|
||||
`commit.gpgsign` option - if this is set, then it will use the results
|
||||
of the `user.signingkey`, `user.name` and `user.email` as appropriate.
|
||||
|
||||
Please note: by adjusting git's `config` file within Gitea's
|
||||
repositories, `SIGNING_KEY=default` could be used to provide different
|
||||
signing keys on a per-repository basis. However, this is cleary not an
|
||||
ideal UI and therefore subject to change.
|
||||
|
||||
### `INITIAL_COMMIT`
|
||||
|
||||
This option determines whether Gitea should sign the initial commit
|
||||
when creating a repository. The possible values are:
|
||||
|
||||
* `never`: Never sign
|
||||
* `pubkey`: Only sign if the user has a public key
|
||||
* `twofa`: Only sign if the user logs in with two factor authentication
|
||||
* `always`: Always sign
|
||||
|
||||
Options other than `never` and `always` can be combined as a comma
|
||||
separated list.
|
||||
|
||||
### `WIKI`
|
||||
|
||||
This options determines if Gitea should sign commits to the Wiki.
|
||||
The possible values are:
|
||||
|
||||
* `never`: Never sign
|
||||
* `pubkey`: Only sign if the user has a public key
|
||||
* `twofa`: Only sign if the user logs in with two factor authentication
|
||||
* `parentsigned`: Only sign if the parent commit is signed.
|
||||
* `always`: Always sign
|
||||
|
||||
Options other than `never` and `always` can be combined as a comma
|
||||
separated list.
|
||||
|
||||
### `CRUD_ACTIONS`
|
||||
|
||||
This option determines if Gitea should sign commits from the web
|
||||
editor or API CRUD actions. The possible values are:
|
||||
|
||||
* `never`: Never sign
|
||||
* `pubkey`: Only sign if the user has a public key
|
||||
* `twofa`: Only sign if the user logs in with two factor authentication
|
||||
* `parentsigned`: Only sign if the parent commit is signed.
|
||||
* `always`: Always sign
|
||||
|
||||
Options other than `never` and `always` can be combined as a comma
|
||||
separated list.
|
||||
|
||||
### `MERGES`
|
||||
|
||||
This option determines if Gitea should sign merge commits from PRs.
|
||||
The possible options are:
|
||||
|
||||
* `never`: Never sign
|
||||
* `pubkey`: Only sign if the user has a public key
|
||||
* `twofa`: Only sign if the user logs in with two factor authentication
|
||||
* `basesigned`: Only sign if the parent commit in the base repo is signed.
|
||||
* `headsigned`: Only sign if the head commit in the head branch is signed.
|
||||
* `commitssigned`: Only sign if all the commits in the head branch to the merge point are signed.
|
||||
* `approved`: Only sign approved merges to a protected branch.
|
||||
* `always`: Always sign
|
||||
|
||||
Options other than `never` and `always` can be combined as a comma
|
||||
separated list.
|
||||
|
||||
## Installing and generating a GPG key for Gitea
|
||||
|
||||
It is up to a server administrator to determine how best to install
|
||||
a signing key. Gitea generates all its commits using the server `git`
|
||||
command at present - and therefore the server `gpg` will be used for
|
||||
signing (if configured.) Administrators should review best-practices
|
||||
for gpg - in particular it is probably advisable to only install a
|
||||
signing secret subkey without the master signing and certifying secret
|
||||
key.
|
||||
|
||||
## Obtaining the Public Key of the Signing Key
|
||||
|
||||
The public key used to sign Gitea's commits can be obtained from the API at:
|
||||
|
||||
```/api/v1/signing-key.gpg```
|
||||
|
||||
In cases where there is a repository specific key this can be obtained from:
|
||||
|
||||
```/api/v1/repos/:username/:reponame/signing-key.gpg```
|
@@ -35,3 +35,6 @@ Check our [CI/CD page]({{< relref "doc/advanced/ci-cd.en-us.md" >}})
|
||||
|
||||
### Editor Extensions
|
||||
- [Gitea Extension for Visual Studio](https://github.com/maikebing/Gitea.VisualStudio) Download from [Visual Studio Marketplace](https://marketplace.visualstudio.com/items?itemName=MysticBoy.GiteaExtensionforVisualStudio)
|
||||
|
||||
### Project Management
|
||||
- [YouTrack by JetBrains](https://blog.jetbrains.com/youtrack/2019/12/whats-new-in-youtrack-2019-3/)
|
||||
|
36
docs/content/doc/advanced/third-party-tools.zh-cn.md
Normal file
36
docs/content/doc/advanced/third-party-tools.zh-cn.md
Normal file
@@ -0,0 +1,36 @@
|
||||
---
|
||||
date: "2019-03-11T21:45:00+00:00"
|
||||
title: "高级: 第三方工具"
|
||||
slug: "third-party-tools"
|
||||
weight: 50
|
||||
toc: true
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
parent: "advanced"
|
||||
name: "第三方工具"
|
||||
weight: 50
|
||||
identifier: "third-party-tools"
|
||||
---
|
||||
|
||||
# 第三方工具列表
|
||||
**注意:** 这些工具并没有经过Gitea的检验,在这里列出它们只是为了便捷.
|
||||
|
||||
*此列表并不是完整的列表,可以随时咨询如何添加!*
|
||||
|
||||
### 持续集成
|
||||
[BuildKite 连接器](https://github.com/techknowlogick/gitea-buildkite-connector)
|
||||
[Jenkins 插件](https://github.com/jenkinsci/gitea-plugin)
|
||||
[Gitea搭配Drone](https://docs.drone.io/installation/gitea)
|
||||
|
||||
|
||||
### 迁移
|
||||
[Gitea安装脚本](https://git.coolaj86.com/coolaj86/gitea-installer.sh)
|
||||
[GitHub迁移](https://gitea.com/gitea/migrator)
|
||||
|
||||
|
||||
### 移动端
|
||||
[安卓客户端GitNex](https://gitlab.com/mmarif4u/gitnex)
|
||||
|
||||
### 编辑器扩展
|
||||
- [Gitea的Visual Studio扩展](https://github.com/maikebing/Gitea.VisualStudio) 从 [Visual Studio 扩展市场](https://marketplace.visualstudio.com/items?itemName=MysticBoy.GiteaExtensionforVisualStudio) 下载
|
@@ -216,3 +216,42 @@ configure this, set the fields below:
|
||||
|
||||
- Log in to Gitea as an Administrator and click on "Authentication" under Admin Panel.
|
||||
Then click `Add New Source` and fill in the details, changing all where appropriate.
|
||||
|
||||
## SPNEGO with SSPI (Kerberos/NTLM, for Windows only)
|
||||
|
||||
Gitea supports SPNEGO single sign-on authentication (the scheme defined by RFC4559) for the web part of the server via the Security Support Provider Interface (SSPI) built in Windows. SSPI works only in Windows environments - when both the server and the clients are running Windows.
|
||||
|
||||
Before activating SSPI single sign-on authentication (SSO) you have to prepare your environment:
|
||||
|
||||
- Create a separate user account in active directory, under which the `gitea.exe` process will be running (eg. `user` under domain `domain.local`):
|
||||
|
||||
- Create a service principal name for the host where `gitea.exe` is running with class `HTTP`:
|
||||
- Start `Command Prompt` or `PowerShell` as a priviledged domain user (eg. Domain Administrator)
|
||||
- Run the command below, replacing `host.domain.local` with the fully qualified domain name (FQDN) of the server where the web application will be running, and `domain\user` with the name of the account created in the previous step:
|
||||
```
|
||||
setspn -A HTTP/host.domain.local domain\user
|
||||
```
|
||||
|
||||
- Sign in (*sign out if you were already signed in*) with the user created
|
||||
|
||||
- Make sure that `ROOT_URL` in the `[server]` section of `custom/conf/app.ini` is the fully qualified domain name of the server where the web application will be running - the same you used when creating the service principal name (eg. `host.domain.local`)
|
||||
|
||||
- Start the web server (`gitea.exe web`)
|
||||
|
||||
- Enable SSPI authentication by adding an `SPNEGO with SSPI` authentication source in `Site Administration -> Authentication Sources`
|
||||
|
||||
- Sign in to a client computer in the same domain with any domain user (client computer, different from the server running `gitea.exe`)
|
||||
|
||||
- If you are using Chrome, Edge or Internet Explorer, add the URL of the web app to the Local intranet sites (`Internet Options -> Security -> Local intranet -> Sites`)
|
||||
|
||||
- Start Chrome, Edge or Internet Explorer and navigate to the FQDN URL of gitea (eg. `http://host.domain.local:3000`)
|
||||
|
||||
- Click the `Sign In` button on the dashboard and choose SSPI to be automatically logged in with the same user that is currently logged on to the computer
|
||||
|
||||
- If it does not work, make sure that:
|
||||
- You are not running the web browser on the same server where gitea is running. You should be running the web browser on a domain joined computer (client) that is different from the server. If both the client and server are runnning on the same computer NTLM will be prefered over Kerberos.
|
||||
- There is only one `HTTP/...` SPN for the host
|
||||
- The SPN contains only the hostname, without the port
|
||||
- You have added the URL of the web app to the `Local intranet zone`
|
||||
- The clocks of the server and client should not differ with more than 5 minutes (depends on group policy)
|
||||
- `Integrated Windows Authentication` should be enabled in Internet Explorer (under `Advanced settings`)
|
||||
|
@@ -60,7 +60,7 @@ _Symbols used in table:_
|
||||
| Git LFS 2.0 | ✓ | ✘ | ✓ | ✓ | ✓ | ⁄ | ✓ |
|
||||
| Group Milestones | ✘ | ✘ | ✘ | ✓ | ✓ | ✘ | ✘ |
|
||||
| Granular user roles (Code, Issues, Wiki etc) | ✓ | ✘ | ✘ | ✓ | ✓ | ✘ | ✘ |
|
||||
| Verified Committer | ✘ | ✘ | ? | ✓ | ✓ | ✓ | ✘ |
|
||||
| Verified Committer | ⁄ | ✘ | ? | ✓ | ✓ | ✓ | ✘ |
|
||||
| GPG Signed Commits | ✓ | ✘ | ✓ | ✓ | ✓ | ✓ | ✓ |
|
||||
| Reject unsigned commits | [✘](https://github.com/go-gitea/gitea/issues/2770) | ✘ | ✓ | ✓ | ✓ | ✘ | ✓ |
|
||||
| Repository Activity page | ✓ | ✘ | ✓ | ✓ | ✓ | ✓ | ✓ |
|
||||
@@ -68,6 +68,7 @@ _Symbols used in table:_
|
||||
| Create new branches | ✓ | ✘ | ✓ | ✓ | ✓ | ✘ | ✘ |
|
||||
| Web code editor | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
|
||||
| Commit graph | ✓ | ✘ | ✓ | ✓ | ✓ | ✓ | ✓ |
|
||||
| Template Repositories | [✓](https://github.com/go-gitea/gitea/pull/8768) | ✘ | ✓ | ✘ | ✓ | ✓ | ✘ |
|
||||
|
||||
#### Issue Tracker
|
||||
|
||||
@@ -105,6 +106,7 @@ _Symbols used in table:_
|
||||
| Revert specific commits or a merge request | [✘](https://github.com/go-gitea/gitea/issues/5158) | ✘ | ✓ | ✓ | ✓ | ✓ | ✘ |
|
||||
| Pull/Merge requests templates | ✓ | ✓ | ✓ | ✓ | ✓ | ✘ | ✘ |
|
||||
| Cherry-picking changes | [✘](https://github.com/go-gitea/gitea/issues/5158) | ✘ | ✘ | ✓ | ✓ | ✘ | ✘ |
|
||||
| Download Patch | ✓ | ✘ | ✓ | ✓ | ✓ | [/](https://jira.atlassian.com/plugins/servlet/mobile#issue/BCLOUD-8323) | ✘ |
|
||||
|
||||
|
||||
#### 3rd-party integrations
|
||||
|
56
docs/content/doc/features/gitea-directory.md
Normal file
56
docs/content/doc/features/gitea-directory.md
Normal file
@@ -0,0 +1,56 @@
|
||||
---
|
||||
date: "2019-11-28:00:00+02:00"
|
||||
title: "The .gitea Directory"
|
||||
slug: "gitea-directory"
|
||||
weight: 40
|
||||
toc: true
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
parent: "features"
|
||||
name: "The .gitea Directory"
|
||||
weight: 50
|
||||
identifier: "gitea-directory"
|
||||
---
|
||||
|
||||
# The .gitea directory
|
||||
Gitea repositories can include a `.gitea` directory at their base which will store settings/configurations for certain features.
|
||||
|
||||
## Templates
|
||||
Gitea includes template repositories, and one feature implemented with them is auto-expansion of specific variables within your template files.
|
||||
To tell Gitea which files to expand, you must include a `template` file inside the `.gitea` directory of the template repository.
|
||||
Gitea uses [gobwas/glob](https://github.com/gobwas/glob) for its glob syntax. It closely resembles a traditional `.gitignore`, however there may be slight differences.
|
||||
|
||||
### Example `.gitea/template` file
|
||||
All paths are relative to the base of the repository
|
||||
```gitignore
|
||||
# All .go files, anywhere in the repository
|
||||
**.go
|
||||
|
||||
# All text files in the text directory
|
||||
text/*.txt
|
||||
|
||||
# A specific file
|
||||
a/b/c/d.json
|
||||
|
||||
# Batch files in both upper or lower case can be matched
|
||||
**.[bB][aA][tT]
|
||||
```
|
||||
**NOTE:** The `template` file will be removed from the `.gitea` directory when a repository is generated from the template.
|
||||
|
||||
### Variable Expansion
|
||||
In any file matched by the above globs, certain variables will be expanded.
|
||||
All variables must be of the form `$VAR` or `${VAR}`. To escape an expansion, use a double `$$`, such as `$$VAR` or `$${VAR}`
|
||||
|
||||
| Variable | Expands To |
|
||||
|----------------------|-----------------------------------------------------|
|
||||
| REPO_NAME | The name of the generated repository |
|
||||
| TEMPLATE_NAME | The name of the template repository |
|
||||
| REPO_DESCRIPTION | The description of the generated repository |
|
||||
| TEMPLATE_DESCRIPTION | The description of the template repository |
|
||||
| REPO_LINK | The URL to the generated repository |
|
||||
| TEMPLATE_LINK | The URL to the template repository |
|
||||
| REPO_HTTPS_URL | The HTTP(S) clone link for the generated repository |
|
||||
| TEMPLATE_HTTPS_URL | The HTTP(S) clone link for the template repository |
|
||||
| REPO_SSH_URL | The SSH clone link for the generated repository |
|
||||
| TEMPLATE_SSH_URL | The SSH clone link for the template repository |
|
@@ -2,12 +2,12 @@
|
||||
date: "2017-01-20T15:00:00+08:00"
|
||||
title: "Help"
|
||||
slug: "help"
|
||||
weight: 50
|
||||
weight: 5
|
||||
toc: false
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
name: "Help"
|
||||
weight: 50
|
||||
weight: 5
|
||||
identifier: "help"
|
||||
---
|
||||
|
13
docs/content/doc/help.fr-fr.md
Normal file
13
docs/content/doc/help.fr-fr.md
Normal file
@@ -0,0 +1,13 @@
|
||||
---
|
||||
date: "2017-01-20T15:00:00+08:00"
|
||||
title: "Aide"
|
||||
slug: "help"
|
||||
weight: 5
|
||||
toc: false
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
name: "Aide"
|
||||
weight: 5
|
||||
identifier: "help"
|
||||
---
|
@@ -2,12 +2,12 @@
|
||||
date: "2017-01-20T15:00:00+08:00"
|
||||
title: "帮助"
|
||||
slug: "help"
|
||||
weight: 50
|
||||
weight: 5
|
||||
toc: false
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
name: "帮助"
|
||||
weight: 50
|
||||
weight: 5
|
||||
identifier: "help"
|
||||
---
|
||||
|
13
docs/content/doc/help.zh-tw.md
Normal file
13
docs/content/doc/help.zh-tw.md
Normal file
@@ -0,0 +1,13 @@
|
||||
---
|
||||
date: "2017-01-20T15:00:00+08:00"
|
||||
title: "救命"
|
||||
slug: "help"
|
||||
weight: 5
|
||||
toc: false
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
name: "救命"
|
||||
weight: 5
|
||||
identifier: "help"
|
||||
---
|
@@ -42,6 +42,9 @@ Also see [Support Options]({{< relref "doc/help/seek-help.en-us.md" >}})
|
||||
* [SSH Common Errors](#ssh-common-errors)
|
||||
* [Missing releases after migration repository with tags](#missing-releases-after-migrating-repository-with-tags)
|
||||
* [LFS Issues](#lfs-issues)
|
||||
* [How can I create users before starting Gitea](#how-can-i-create-users-before-starting-gitea)
|
||||
* [How can I enable password reset](#how-can-i-enable-password-reset)
|
||||
* [How can a user's password be changed](#how-can-a-user-s-password-be-changed)
|
||||
|
||||
|
||||
## Difference between 1.x and 1.x.x downloads
|
||||
@@ -272,3 +275,19 @@ Check the value of `LFS_HTTP_AUTH_EXPIRY` in your `app.ini` file.
|
||||
By default, your LFS token will expire after 20 minutes. If you have a slow connection or a large file (or both), it may not finish uploading within the time limit.
|
||||
|
||||
You may want to set this value to `60m` or `120m`.
|
||||
|
||||
## How can I create users before starting Gitea
|
||||
Gitea provides a sub-command `gitea migrate` to initialize the database, after which you can use the [admin CLI commands]({{< relref "doc/usage/command-line.en-us.md#admin" >}}) to add users like normal.
|
||||
|
||||
## How can I enable password reset
|
||||
There is no setting for password resets. It is enabled when a [mail service]({{< relref "doc/usage/email-setup.en-us.md" >}}) is configured, and disabled otherwise.
|
||||
|
||||
## How can a user's password be changed
|
||||
- As an **admin**, you can change any user's password (and optionally force them to change it on next login)...
|
||||
- By navigating to your `Site Administration -> User Accounts` page and editing a user.
|
||||
- By using the [admin CLI commands]({{< relref "doc/usage/command-line.en-us.md#admin" >}}).
|
||||
Keep in mind most commands will also need a [global flag]({{< relref "doc/usage/command-line.en-us.md#global-options" >}}) to point the CLI at the correct configuration.
|
||||
- As a **user** you can change it...
|
||||
- In your account `Settings -> Account` page (this method **requires** you to know your current password).
|
||||
- By using the `Forgot Password` link.
|
||||
If the `Forgot Password/Account Recovery` page is disabled, please contact your administrator to configure a [mail service]({{< relref "doc/usage/email-setup.en-us.md" >}}).
|
||||
|
25
docs/content/doc/help/search.en-us.md
Normal file
25
docs/content/doc/help/search.en-us.md
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
date: "2019-11-12T16:00:00+02:00"
|
||||
title: "Search"
|
||||
slug: "search"
|
||||
weight: 4
|
||||
toc: true
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
parent: "help"
|
||||
name: "Search"
|
||||
weight: 4
|
||||
identifier: "search"
|
||||
sitemap:
|
||||
priority : 0.1
|
||||
layout: "search"
|
||||
---
|
||||
|
||||
|
||||
This file exists solely to respond to /search URL with the related `search` layout template.
|
||||
|
||||
No content shown here is rendered, all content is based in the template layouts/doc/search.html
|
||||
|
||||
Setting a very low sitemap priority will tell search engines this is not important content.
|
||||
|
25
docs/content/doc/help/search.fr-fr.md
Normal file
25
docs/content/doc/help/search.fr-fr.md
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
date: "2019-11-12T16:00:00+02:00"
|
||||
title: "Chercher"
|
||||
slug: "search"
|
||||
weight: 4
|
||||
toc: true
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
parent: "help"
|
||||
name: "Chercher"
|
||||
weight: 4
|
||||
identifier: "search"
|
||||
sitemap:
|
||||
priority : 0.1
|
||||
layout: "search"
|
||||
---
|
||||
|
||||
|
||||
This file exists solely to respond to /search URL with the related `search` layout template.
|
||||
|
||||
No content shown here is rendered, all content is based in the template layouts/doc/search.html
|
||||
|
||||
Setting a very low sitemap priority will tell search engines this is not important content.
|
||||
|
25
docs/content/doc/help/search.zh-cn.md
Normal file
25
docs/content/doc/help/search.zh-cn.md
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
date: "2019-11-12T16:00:00+02:00"
|
||||
title: "搜索"
|
||||
slug: "search"
|
||||
weight: 4
|
||||
toc: true
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
parent: "help"
|
||||
name: "搜索"
|
||||
weight: 4
|
||||
identifier: "search"
|
||||
sitemap:
|
||||
priority : 0.1
|
||||
layout: "search"
|
||||
---
|
||||
|
||||
|
||||
This file exists solely to respond to /search URL with the related `search` layout template.
|
||||
|
||||
No content shown here is rendered, all content is based in the template layouts/doc/search.html
|
||||
|
||||
Setting a very low sitemap priority will tell search engines this is not important content.
|
||||
|
25
docs/content/doc/help/search.zh-tw.md
Normal file
25
docs/content/doc/help/search.zh-tw.md
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
date: "2019-11-12T16:00:00+02:00"
|
||||
title: "搜索"
|
||||
slug: "search"
|
||||
weight: 4
|
||||
toc: true
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
parent: "help"
|
||||
name: "搜索"
|
||||
weight: 4
|
||||
identifier: "search"
|
||||
sitemap:
|
||||
priority : 0.1
|
||||
layout: "search"
|
||||
---
|
||||
|
||||
|
||||
This file exists solely to respond to /search URL with the related `search` layout template.
|
||||
|
||||
No content shown here is rendered, all content is based in the template layouts/doc/search.html
|
||||
|
||||
Setting a very low sitemap priority will tell search engines this is not important content.
|
||||
|
@@ -21,6 +21,10 @@ environment variable and to add the go bin directory or directories
|
||||
`${GOPATH//://bin:}/bin` to the `$PATH`. See the Go wiki entry for
|
||||
[GOPATH](https://github.com/golang/go/wiki/GOPATH).
|
||||
|
||||
Next, [install Node.js with npm](https://nodejs.org/en/download/) which is
|
||||
required to build the JavaScript and CSS files. The minimum supported Node.js
|
||||
version is 10 and the latest LTS version is recommended.
|
||||
|
||||
**Note**: When executing make tasks that require external tools, like
|
||||
`make misspell-check`, Gitea will automatically download and build these as
|
||||
necessary. To be able to use these, you must have the `"$GOPATH/bin"` directory
|
||||
@@ -75,9 +79,12 @@ git checkout v{{< version >}} # or git checkout pr-xyz
|
||||
|
||||
## Build
|
||||
|
||||
Since all required libraries are already bundled in the Gitea source, it's
|
||||
possible to build Gitea with no additional downloads apart from Make
|
||||
<a href='{{< relref "doc/advanced/make.en-us.md" >}}'>(See here how to get Make)</a>.
|
||||
To build from source, the following programs must be present on the system:
|
||||
|
||||
- `go` 1.11.0 or higher, see [here](https://golang.org/dl/)
|
||||
- `node` 10.0.0 or higher with `npm`, see [here](https://nodejs.org/en/download/)
|
||||
- `make`, see <a href='{{< relref "doc/advanced/make.en-us.md" >}}'>here</a>
|
||||
|
||||
Various [make tasks](https://github.com/go-gitea/gitea/blob/master/Makefile)
|
||||
are provided to keep the build process as simple as possible.
|
||||
|
||||
@@ -93,11 +100,10 @@ Depending on requirements, the following build tags can be included.
|
||||
|
||||
Bundling assets into the binary using the `bindata` build tag can make
|
||||
development and testing easier, but is not ideal for a production deployment.
|
||||
To include assets, they must be built separately using the `generate` make
|
||||
task e.g.:
|
||||
To include assets, add the `bindata` tag:
|
||||
|
||||
```bash
|
||||
TAGS="bindata" make generate build
|
||||
TAGS="bindata" make build
|
||||
```
|
||||
|
||||
In the default release build of our continuous integration system, the build
|
||||
@@ -105,9 +111,20 @@ tags are: `TAGS="bindata sqlite sqlite_unlock_notify"`. The simplest
|
||||
recommended way to build from source is therefore:
|
||||
|
||||
```bash
|
||||
TAGS="bindata sqlite sqlite_unlock_notify" make generate build
|
||||
TAGS="bindata sqlite sqlite_unlock_notify" make build
|
||||
```
|
||||
|
||||
The `build` target is split into two sub-targets:
|
||||
|
||||
- `make backend` which requires [Go 1.11](https://golang.org/dl/) or greater.
|
||||
- `make frontend` which requires [Node.js 10.0.0](https://nodejs.org/en/download/) or greater.
|
||||
|
||||
If pre-built frontend files are present it is possible to only build the backend:
|
||||
|
||||
```bash
|
||||
TAGS="bindata" make backend
|
||||
``
|
||||
|
||||
## Test
|
||||
|
||||
After following the steps above, a `gitea` binary will be available in the working directory.
|
||||
@@ -118,12 +135,12 @@ launched manually from command line, it can be killed by pressing `Ctrl + C`.
|
||||
./gitea web
|
||||
```
|
||||
|
||||
## Changing the default CustomPath, CustomConf and AppWorkDir
|
||||
## Changing the default CustomPath, CustomConf and AppWorkPath
|
||||
|
||||
Gitea will search for a number of things from the `CustomPath`. By default this is
|
||||
the `custom/` directory in the current working directory when running Gitea. It will also
|
||||
look for its configuration file `CustomConf` in `$CustomPath/conf/app.ini`, and will use the
|
||||
current working directory as the relative base path `AppWorkDir` for a number configurable
|
||||
current working directory as the relative base path `AppWorkPath` for a number configurable
|
||||
values.
|
||||
|
||||
These values, although useful when developing, may conflict with downstream users preferences.
|
||||
@@ -134,7 +151,7 @@ using the `LDFLAGS` environment variable for `make`. The appropriate settings ar
|
||||
|
||||
* To set the `CustomPath` use `LDFLAGS="-X \"code.gitea.io/gitea/modules/setting.CustomPath=custom-path\""`
|
||||
* For `CustomConf` you should use `-X \"code.gitea.io/gitea/modules/setting.CustomConf=conf.ini\"`
|
||||
* For `AppWorkDir` you should use `-X \"code.gitea.io/gitea/modules/setting.AppWorkDir=working-directory\"`
|
||||
* For `AppWorkPath` you should use `-X \"code.gitea.io/gitea/modules/setting.AppWorkPath=working-path\"`
|
||||
|
||||
Add as many of the strings with their preceding `-X` to the `LDFLAGS` variable and run `make build`
|
||||
with the appropriate `TAGS` as above.
|
||||
|
@@ -60,10 +60,10 @@ Comme nous regroupons déjà toutes les bibliothèques requises pour compiler Gi
|
||||
* `sqlite sqlite_unlock_notify`: Active la prise en charge d'une base de données [SQLite3](https://sqlite.org/), ceci n'est recommandé que pour les petites installations de Gitea.
|
||||
* `pam`: Active la prise en charge de PAM (mLinux Pluggable Authentication Modules), très utile si vos utilisateurs doivent être authentifiés avec les comptes du système.
|
||||
|
||||
Il est temps de compiler le binaire, nous suggérons d'intégrer les ressources avec l'option de compilation `bindata`. Pour inclure les ressources, vous devrez également exécuter la tâche Make `generate`. Dans le cas échéant, les ressources ne pourront pas être intégrées:
|
||||
Il est temps de compiler le binaire, nous suggérons d'intégrer les ressources avec l'option de compilation `bindata`:
|
||||
|
||||
```
|
||||
TAGS="bindata" make generate build
|
||||
TAGS="bindata" make build
|
||||
```
|
||||
|
||||
## Test
|
||||
|
@@ -44,30 +44,32 @@ git checkout v{{< version >}}
|
||||
|
||||
## 编译
|
||||
|
||||
我们已经将所有的依赖项拷贝到本工程,我们提供了一些 [编译选项](https://github.com/go-gitea/gitea/blob/master/Makefile) 来让编译更简单。你可以按照你的需求来设置编译开关,可用编译选项如下:
|
||||
要从源代码进行编译,以下依赖程序必须事先安装好:
|
||||
|
||||
- `go` 1.11.0 或以上版本, 详见 [here](https://golang.org/dl/)
|
||||
- `node` 10.0.0 或以上版本,并且安装 `npm`, 详见 [here](https://nodejs.org/en/download/)
|
||||
- `make`, 详见 <a href='{{< relref "make.zh-cn.md" >}}'>这里</a>
|
||||
|
||||
各种可用的 [make 任务](https://github.com/go-gitea/gitea/blob/master/Makefile)
|
||||
可以用来使编译过程更方便。
|
||||
|
||||
按照您的编译需求,以下 tags 可以使用:
|
||||
|
||||
* `bindata`: 这个编译选项将会把运行Gitea所需的所有外部资源都打包到可执行文件中,这样部署将非常简单因为除了可执行程序将不再需要任何其他文件。
|
||||
* `sqlite sqlite_unlock_notify`: 这个编译选项将启用SQLite3数据库的支持,建议只在少数人使用时使用这个模式。
|
||||
* `pam`: 这个编译选项将会启用 PAM (Linux Pluggable Authentication Modules) 认证,如果你使用这一认证模式的话需要开启这个选项。
|
||||
|
||||
我们支持两种方式进行编译,Make 工具 和 Go 工具。不过我们推荐使用 Make工具,因为他将会给出更多的编译选项。
|
||||
使用 bindata 可以打包资源文件到二进制可以使开发和测试更容易,你可以根据自己的需求决定是否打包资源文件。
|
||||
要包含资源文件,请使用 `bindata` tag:
|
||||
|
||||
**Note**: We recommend the Go version 1.6 or higher because we are using vendoring and we don't set the required env variable for 1.5 anywhere.
|
||||
|
||||
* Make 工具
|
||||
|
||||
这个编译方式要求你先安装Make工具,关于Make工具的安装你可以参考Make相关资料。同样如果要使用bindata选项,你可能需要先执行make generate:
|
||||
|
||||
```
|
||||
TAGS="bindata" make generate build
|
||||
```bash
|
||||
TAGS="bindata" make build
|
||||
```
|
||||
|
||||
* Go 工具
|
||||
默认的发布版本中的编译选项是: `TAGS="bindata sqlite sqlite_unlock_notify"`。以下为推荐的编译方式:
|
||||
|
||||
使用 Go 工具编译需要你至少安装了Go 1.5以上版本并且将 govendor 的支持打开。执行命令如下:
|
||||
|
||||
```
|
||||
go build
|
||||
```bash
|
||||
TAGS="bindata sqlite sqlite_unlock_notify" make build
|
||||
```
|
||||
|
||||
## 测试
|
||||
|
@@ -50,10 +50,10 @@ git checkout v{{< version >}}
|
||||
* `sqlite sqlite_unlock_notify`: 使用此標籤來啟用 [SQLite3](https://sqlite.org/) 資料庫,建議只有少數人時才使用此模式。
|
||||
* `pam`: 使用此標籤來啟用 PAM (Linux Pluggable Authentication Modules) 認證,對於系統使用者來說,此方式最方便了。
|
||||
|
||||
現在您可以開始編譯執行檔了,我們建議使用 `bindata` 編譯選項,使用 `bindata` 選項前,您必須執行 `generate` 任務將所有資源都一起編譯進去,否則相關資源都不會被編譯進執行檔:
|
||||
現在您可以開始編譯執行檔了,我們建議使用 `bindata` 編譯選項:
|
||||
|
||||
```
|
||||
TAGS="bindata" make generate build
|
||||
TAGS="bindata" make build
|
||||
```
|
||||
|
||||
**注意**: 因為使用了套件管理工具,我們建議 Go 環境版本為 1.6 或者是更高,這樣不用在 Go 1.5 版本設定全域變數 `GO15VENDOREXPERIMENT`。
|
||||
|
@@ -40,7 +40,7 @@ To register Gitea as a Windows service, open a command prompt (cmd) as an Admini
|
||||
then run the following command:
|
||||
|
||||
```
|
||||
sc create gitea start= auto binPath= ""C:\gitea\gitea.exe" web --config "C:\gitea\custom\conf\app.ini""
|
||||
sc.exe create gitea start= auto binPath= "\"C:\gitea\gitea.exe\" web --config \"C:\gitea\custom\conf\app.ini\""
|
||||
```
|
||||
|
||||
Do not forget to replace `C:\gitea` with the correct Gitea directory.
|
||||
@@ -54,5 +54,5 @@ that was configured).
|
||||
To unregister Gitea as a service, open a command prompt (cmd) as an Administrator and run:
|
||||
|
||||
```
|
||||
sc delete gitea
|
||||
sc.exe delete gitea
|
||||
```
|
||||
|
@@ -18,7 +18,7 @@ menu:
|
||||
Pour activer le service Windows Gitea, ouvrez une `cmd` en tant qu'Administrateur puis utilisez la commande suivante :
|
||||
|
||||
```
|
||||
sc create gitea start= auto binPath= ""C:\gitea\gitea.exe" web --config "C:\gitea\custom\conf\app.ini""
|
||||
sc create gitea start= auto binPath= "\"C:\gitea\gitea.exe\" web --config \"C:\gitea\custom\conf\app.ini\""
|
||||
```
|
||||
|
||||
N'oubliez pas de remplacer `C:\gitea` par le chemin que vous avez utilisez pour votre installation.
|
||||
|
@@ -18,7 +18,7 @@ menu:
|
||||
要注册为Windows服务,首先以Administrator身份运行 `cmd`,然后执行以下命令:
|
||||
|
||||
```
|
||||
sc create gitea start= auto binPath= ""C:\gitea\gitea.exe" web --config "C:\gitea\custom\conf\app.ini""
|
||||
sc create gitea start= auto binPath= "\"C:\gitea\gitea.exe\" web --config \"C:\gitea\custom\conf\app.ini\""
|
||||
```
|
||||
|
||||
别忘了将 `C:\gitea` 替换成你的 Gitea 安装目录。
|
||||
|
@@ -18,7 +18,7 @@ menu:
|
||||
要註冊為 Windows 服務,首先要以管理者身份執行 `cmd`,跳出命令列視窗後執行底下指令:
|
||||
|
||||
```
|
||||
sc create gitea start= auto binPath= ""C:\gitea\gitea.exe" web --config "C:\gitea\custom\conf\app.ini""
|
||||
sc create gitea start= auto binPath= "\"C:\gitea\gitea.exe\" web --config \"C:\gitea\custom\conf\app.ini\""
|
||||
```
|
||||
|
||||
別忘記將 `C:\gitea` 取代為您的 Gitea 安裝路徑。
|
||||
|
@@ -51,6 +51,8 @@ services:
|
||||
- gitea
|
||||
volumes:
|
||||
- ./gitea:/data
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
ports:
|
||||
- "3000:3000"
|
||||
- "222:22"
|
||||
@@ -80,6 +82,8 @@ services:
|
||||
- gitea
|
||||
volumes:
|
||||
- ./gitea:/data
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
ports:
|
||||
- - "3000:3000"
|
||||
- - "222:22"
|
||||
@@ -115,6 +119,8 @@ services:
|
||||
- gitea
|
||||
volumes:
|
||||
- ./gitea:/data
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
ports:
|
||||
- "3000:3000"
|
||||
- "222:22"
|
||||
@@ -163,6 +169,8 @@ services:
|
||||
- gitea
|
||||
volumes:
|
||||
- ./gitea:/data
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
ports:
|
||||
- "3000:3000"
|
||||
- "222:22"
|
||||
@@ -209,6 +217,8 @@ services:
|
||||
volumes:
|
||||
- - ./gitea:/data
|
||||
+ - gitea:/data
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
ports:
|
||||
- "3000:3000"
|
||||
- "222:22"
|
||||
@@ -306,6 +316,8 @@ UID/GID as the container values `USER_UID`/`USER_GID`. You should also create th
|
||||
- gitea
|
||||
volumes:
|
||||
- /var/lib/gitea:/data
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
ports:
|
||||
- "3000:3000"
|
||||
- "127.0.0.1:2222:22"
|
||||
|
@@ -74,6 +74,11 @@ After successful migration from `gogs` to `gitea 1.0.x`, it is possible to upgra
|
||||
Simply download the file matching the destination platform from the [downloads page](https://dl.gitea.io/gitea)
|
||||
and replace the binary.
|
||||
|
||||
## Upgrading from a more recent version of Gogs
|
||||
|
||||
Upgrading from a more recent version of Gogs is also possible, but requires a bit more work.
|
||||
See [#4286](https://github.com/go-gitea/gitea/issues/4286).
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
* If errors are encountered relating to custom templates in the `gitea/custom/templates`
|
||||
|
@@ -23,4 +23,4 @@ menu:
|
||||
* 如果你还有更多的自定义内容,比如templates和localization文件,你需要手工合并你的修改到 Gitea 的 Options 下对应目录。
|
||||
* 拷贝 Gogs 的数据目录 `data/` 到 Gitea 相应位置。这个目录包含附件和头像文件。
|
||||
* 运行 Gitea
|
||||
* 登陆 Gitea 并进入 管理面板, 运行 `重新生成 '.ssh/authorized_keys' 文件(警告:不是 Gitea 的密钥也会被删除)` 和 `重新生成所有仓库的 Update 钩子(用于自定义配置文件被修改)`。
|
||||
* 登录 Gitea 并进入 管理面板, 运行 `重新生成 '.ssh/authorized_keys' 文件(警告:不是 Gitea 的密钥也会被删除)` 和 `重新生成所有仓库的 Update 钩子(用于自定义配置文件被修改)`。
|
||||
|
@@ -46,7 +46,7 @@ Starts the server:
|
||||
- `gitea web --port 80`
|
||||
- `gitea web --config /etc/gitea.ini --pid /var/run/gitea.pid`
|
||||
- Notes:
|
||||
- Gitea should not be run as root. To bind to a port below 1000, you can use setcap on
|
||||
- Gitea should not be run as root. To bind to a port below 1024, you can use setcap on
|
||||
Linux: `sudo setcap 'cap_net_bind_service=+ep' /path/to/gitea`. This will need to be
|
||||
redone every time you update Gitea.
|
||||
|
||||
@@ -281,3 +281,11 @@ provided key. You should also set the value
|
||||
NB: opensshd requires the gitea program to be owned by root and not
|
||||
writable by group or others. The program must be specified by an absolute
|
||||
path.
|
||||
NB: Gitea must be running for this command to succeed.
|
||||
|
||||
#### migrate
|
||||
Migrates the database. This command can be used to run other commands before starting the server for the first time.
|
||||
This command is idempotent.
|
||||
|
||||
#### convert
|
||||
Converts an existing MySQL database from utf8 to utf8mb4.
|
||||
|
33
docs/content/doc/usage/email-setup.en-us.md
Normal file
33
docs/content/doc/usage/email-setup.en-us.md
Normal file
@@ -0,0 +1,33 @@
|
||||
---
|
||||
date: "2019-10-15T10:10:00+05:00"
|
||||
title: "Usage: Email setup"
|
||||
slug: "email-setup"
|
||||
weight: 12
|
||||
toc: true
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
parent: "usage"
|
||||
name: "Email setup"
|
||||
weight: 12
|
||||
identifier: "email-setup"
|
||||
---
|
||||
|
||||
# Email setup
|
||||
|
||||
- To use Gitea's built-in Email support, update the `app.ini` config file [mailer] section:
|
||||
|
||||
```ini
|
||||
[mailer]
|
||||
ENABLED = true
|
||||
HOST = mail.mydomain.com:587
|
||||
FROM = gitea@mydomain.com
|
||||
USER = gitea@mydomain.com
|
||||
PASSWD = `password`
|
||||
```
|
||||
|
||||
- Restart Gitea for the configuration changes to take effect.
|
||||
|
||||
- To send a test email to validate the settings, go to Gitea > Site Administration > Configuration > SMTP Mailer Configuration.
|
||||
|
||||
For the full list of options check the [Config Cheat Sheet]({{< relref "doc/advanced/config-cheat-sheet.en-us.md" >}})
|
@@ -13,7 +13,7 @@ menu:
|
||||
identifier: "fail2ban-setup"
|
||||
---
|
||||
|
||||
# Fail2ban setup to block users after failed login attemts
|
||||
# Fail2ban setup to block users after failed login attempts
|
||||
|
||||
**Remember that fail2ban is powerful and can cause lots of issues if you do it incorrectly, so make
|
||||
sure to test this before relying on it so you don't lock yourself out.**
|
||||
@@ -26,7 +26,7 @@ on a bad authentication:
|
||||
2018/04/26 18:15:54 [I] Failed authentication attempt for user from xxx.xxx.xxx.xxx
|
||||
```
|
||||
|
||||
So we set our filter in `/etc/fail2ban/filter.d/gitea.conf`:
|
||||
Add our filter in `/etc/fail2ban/filter.d/gitea.conf`:
|
||||
|
||||
```ini
|
||||
# gitea.conf
|
||||
@@ -35,12 +35,11 @@ failregex = .*Failed authentication attempt for .* from <HOST>
|
||||
ignoreregex =
|
||||
```
|
||||
|
||||
And configure it in `/etc/fail2ban/jail.d/jail.local`:
|
||||
Add our jail in `/etc/fail2ban/jail.d/gitea.conf`:
|
||||
|
||||
```ini
|
||||
[gitea]
|
||||
enabled = true
|
||||
port = http,https
|
||||
filter = gitea
|
||||
logpath = /home/git/gitea/log/gitea.log
|
||||
maxretry = 10
|
||||
@@ -49,6 +48,23 @@ bantime = 900
|
||||
action = iptables-allports
|
||||
```
|
||||
|
||||
If you're using Docker, you'll also need to add an additional jail to handle the **FORWARD**
|
||||
chain in **iptables**. Configure it in `/etc/fail2ban/jail.d/gitea-docker.conf`:
|
||||
|
||||
```ini
|
||||
[gitea-docker]
|
||||
enabled = true
|
||||
filter = gitea
|
||||
logpath = /home/git/gitea/log/gitea.log
|
||||
maxretry = 10
|
||||
findtime = 3600
|
||||
bantime = 900
|
||||
action = iptables-allports[chain="FORWARD"]
|
||||
```
|
||||
|
||||
Then simply run `service fail2ban restart` to apply your changes. You can check to see if
|
||||
fail2ban has accepted your configuration using `service fail2ban status`.
|
||||
|
||||
Make sure and read up on fail2ban and configure it to your needs, this bans someone
|
||||
for **15 minutes** (from all ports) when they fail authentication 10 times in an hour.
|
||||
|
||||
|
@@ -76,5 +76,4 @@ After that, enable HTTPS by following one of these guides:
|
||||
* [apache2/httpd](https://httpd.apache.org/docs/2.4/ssl/ssl_howto.html)
|
||||
* [caddy](https://caddyserver.com/docs/tls)
|
||||
|
||||
Note: Your connection between your reverse proxy and Gitea might be unencrypted. To encrypt it too, follow the [built-in server guide](#using-built-in-server) and change
|
||||
the proxy url to `https://[URL]`.
|
||||
Note: Enabling HTTPS only at the proxy level is referred as [TLS Termination Proxy](https://en.wikipedia.org/wiki/TLS_termination_proxy). The proxy server accepted incoming TLS connections, decrypts the contents, and pass the now unencrypted contents to Gitea. This is normally fine as long as both the proxy and Gitea instances are either on the same machine, or on different machines within private network (with the proxy is exposed to outside network. If your Gitea instance is separated from your proxy over a public network, or if you want full end-to-end encryption, you can also [enable HTTPS support directly in Gitea using built-in server](#using-the-built-in-server) and forward the connections over HTTPS instead.
|
||||
|
174
docs/content/doc/usage/linked-references.en-us.md
Normal file
174
docs/content/doc/usage/linked-references.en-us.md
Normal file
@@ -0,0 +1,174 @@
|
||||
---
|
||||
date: "2019-11-21T17:00:00-03:00"
|
||||
title: "Usage: Automatically Linked References"
|
||||
slug: "automatically-linked-references"
|
||||
weight: 15
|
||||
toc: true
|
||||
draft: false
|
||||
menu:
|
||||
sidebar:
|
||||
parent: "usage"
|
||||
name: "Automatically Linked References"
|
||||
weight: 15
|
||||
identifier: "automatically-linked-references"
|
||||
---
|
||||
|
||||
# Automatically Linked References in Issues, Pull Requests and Commit Messages
|
||||
|
||||
When an issue, pull request or comment is posted, the text description is parsed
|
||||
in search for references. These references will be shown as links in the Issue View
|
||||
and, in some cases, produce certain _actions_.
|
||||
|
||||
Likewise, commit messages are parsed when they are listed, and _actions_
|
||||
are can be triggered when they are pushed to the main branch.
|
||||
|
||||
To prevent the creation of unintended references, there are certain rules
|
||||
for them to be recognized. For example, they should not be included inside code
|
||||
text. They should also be reasonably cleared from their surrounding text
|
||||
(for example, using spaces).
|
||||
|
||||
## User, Team and Organization Mentions
|
||||
|
||||
When a text in the form `@username` is found and `username` matches the name
|
||||
of an existing user, a _mention_ reference is created. This will be shown
|
||||
by changing the text into a link to said user's profile, and possibly create
|
||||
a notification for the mentioned user depending on whether they have
|
||||
the necessary permission to access the contents.
|
||||
|
||||
Example:
|
||||
|
||||
> [@John](#), can you give this a look?
|
||||
|
||||
This is also valid for teams and organizations:
|
||||
|
||||
> [@Documenters](#), we need to plan for this.
|
||||
|
||||
> [@CoolCompanyInc](#), this issue concerns us all!
|
||||
|
||||
Teams will receive mail notifications when appropriate, but whole organizations won't.
|
||||
|
||||
Commit messages do not produce user notifications.
|
||||
|
||||
## Commits
|
||||
|
||||
Commits can be referenced using their SHA1 hash, or a portion of it of
|
||||
at least seven characters. They will be shown as a link to the corresponding
|
||||
commit.
|
||||
|
||||
Example:
|
||||
|
||||
> This bug was introduced in [e59ff077](#)
|
||||
|
||||
## Issues and Pull Requests
|
||||
|
||||
A reference to another issue or pull request can be created using the simple
|
||||
notation `#1234`, where _1234_ is the number of an issue or pull request
|
||||
in the same repository. These references will be shown as links to the
|
||||
referenced content.
|
||||
|
||||
The effect of creating this type of reference is that a _notice_ will be
|
||||
created in the referenced document, provided the creator of the reference
|
||||
has reading permissions on it.
|
||||
|
||||
Example:
|
||||
|
||||
> This seems related to [#1234](#)
|
||||
|
||||
Issues and pull requests in other repositories can be referred to as well
|
||||
using the form `owner/repository#1234`:
|
||||
|
||||
> This seems related to [mike/compiler#1234](#)
|
||||
|
||||
Alternatively, the `!1234` notation can be used as well. Even when in Gitea
|
||||
a pull request is a form of issue, the `#1234` form will always link to
|
||||
an issue; if the linked entry happens to be a pull request instead, Gitea
|
||||
will redirect as appropriate. With the `!1234` notation, a pull request
|
||||
link will be created, which will be redirected to an issue if required.
|
||||
However, this distinction could be important if an external tracker is
|
||||
used, where links to issues and pull requests are not interchangeable.
|
||||
|
||||
## Actionable References in Pull Requests and Commit Messages
|
||||
|
||||
Sometimes a commit or pull request may fix or bring back a problem documented
|
||||
in a particular issue. Gitea supports closing and reopening the referenced
|
||||
issues by preceding the reference with a particular _keyword_. Common keywords
|
||||
include "closes", "fixes", "reopens", etc. This list can be
|
||||
[customized]({{< ref "/doc/advanced/config-cheat-sheet.en-us.md" >}}) by the
|
||||
site administrator.
|
||||
|
||||
Example:
|
||||
|
||||
> This PR _closes_ [#1234](#)
|
||||
|
||||
If the actionable reference is accepted, this will create a notice on the
|
||||
referenced issue announcing that it will be closed when the referencing PR
|
||||
is merged.
|
||||
|
||||
For an actionable reference to be accepted, _at least one_ of the following
|
||||
conditions must be met:
|
||||
|
||||
* The commenter has permissions to close or reopen the issue at the moment
|
||||
of creating the reference.
|
||||
* The reference is inside a commit message.
|
||||
* The reference is posted as part of the pull request description.
|
||||
|
||||
In the last case, the issue will be closed or reopened only if the merger
|
||||
of the pull request has permissions to do so.
|
||||
|
||||
Additionally, only pull requests and commit messages can create an action,
|
||||
and only issues can be closed or reopened this way.
|
||||
|
||||
The default _keywords_ are:
|
||||
|
||||
* **Closing**: close, closes, closed, fix, fixes, fixed, resolve, resolves, resolved
|
||||
* **Reopening**: reopen, reopens, reopened
|
||||
|
||||
## External Trackers
|
||||
|
||||
Gitea supports the use of external issue trackers, and references to issues
|
||||
hosted externally can be created in pull requests. However, if the external
|
||||
tracker uses numbers to identify issues, they will be indistinguishable from
|
||||
the pull requests hosted in Gitea. To address this, Gitea allows the use of
|
||||
the `!` marker to identify pull requests. For example:
|
||||
|
||||
> This is issue [#1234](#), and links to the external tracker.
|
||||
|
||||
> This is pull request [!1234](#), and links to a pull request in Gitea.
|
||||
|
||||
The `!` and `#` can be used interchangeably for issues and pull request _except_
|
||||
for this case, where a distinction is required. If the repository uses external
|
||||
tracker, commit message for squash merge will use `!` as reference by default.
|
||||
|
||||
## Issues and Pull Requests References Summary
|
||||
|
||||
This table illustrates the different kinds of cross-reference for issues and pull requests.
|
||||
In the examples, `User1/Repo1` refers to the repository where the reference is used, while
|
||||
`UserZ/RepoZ` indicates a different repository.
|
||||
|
||||
| Reference in User1/Repo1 | Repo1 issues are external | RepoZ issues are external | Should render |
|
||||
|---------------------------|:-------------------------:|:-------------------------:|----------------------------------|
|
||||
| `#1234` | no | N/A | A link to issue/pull 1234 in `User1/Repo1` |
|
||||
| `!1234` | no | N/A | A link to issue/pull 1234 in `User1/Repo1` |
|
||||
| `#1234` | yes | N/A | A link to _external issue_ 1234 for `User1/Repo1` |
|
||||
| `!1234` | yes | N/A | A link to _PR_ 1234 for `User1/Repo1` |
|
||||
| `User1/Repo1#1234` | no | N/A | A link to issue/pull 1234 in `User1/Repo1` |
|
||||
| `User1/Repo1!1234` | no | N/A | A link to issue/pull 1234 in `User1/Repo1` |
|
||||
| `User1/Repo1#1234` | yes | N/A | A link to _external issue_ 1234 for `User1/Repo1` |
|
||||
| `User1/Repo1!1234` | yes | N/A | A link to _PR_ 1234 for `User1/Repo1` |
|
||||
| `UserZ/RepoZ#1234` | N/A | no | A link to issue/pull 1234 in `UserZ/RepoZ` |
|
||||
| `UserZ/RepoZ!1234` | N/A | no | A link to issue/pull 1234 in `UserZ/RepoZ` |
|
||||
| `UserZ/RepoZ#1234` | N/A | yes | A link to _external issue_ 1234 for `UserZ/RepoZ` |
|
||||
| `UserZ/RepoZ!1234` | N/A | yes | A link to _PR_ 1234 for `UserZ/RepoZ` |
|
||||
| **Alphanumeric issue IDs:** | - | - | - |
|
||||
| `AAA-1234` | yes | N/A | A link to _external issue_ `AAA-1234` for `User1/Repo1` |
|
||||
| `!1234` | yes | N/A | A link to _PR_ 1234 for `User1/Repo1` |
|
||||
| `User1/Repo1!1234` | yes | N/A | A link to _PR_ 1234 for `User1/Repo1` |
|
||||
| _Not supported_ | N/A | yes | A link to _external issue_ `AAA-1234` for `UserZ/RepoZ` |
|
||||
| `UserZ/RepoZ!1234` | N/A | yes | A link to _PR_ 1234 in `UserZ/RepoZ` |
|
||||
|
||||
_The last section is for repositories with external issue trackers that use alphanumeric format._
|
||||
|
||||
_**N/A**: not applicable._
|
||||
|
||||
Note: automatic references between repositories with different types of issues (external vs. internal) are not fully supported
|
||||
and may render invalid links.
|
@@ -14,7 +14,7 @@ menu:
|
||||
---
|
||||
|
||||
## Using Nginx as a reverse proxy
|
||||
If you want Nginx to serve your Gitea instance, you can the following `server` section inside the `http` section of `nginx.conf`:
|
||||
If you want Nginx to serve your Gitea instance, add the following `server` section to the `http` section of `nginx.conf`:
|
||||
|
||||
```
|
||||
server {
|
||||
@@ -44,6 +44,74 @@ server {
|
||||
|
||||
Then set `[server] ROOT_URL = http://git.example.com/git/` in your configuration.
|
||||
|
||||
## Using Nginx as a reverse proxy and serve static resources directly
|
||||
We can tune the performance in splitting requests into categories static and dynamic.
|
||||
|
||||
CSS files, JavaScript files, images and web fonts are static content.
|
||||
The front page, a repository view or issue list is dynamic content.
|
||||
|
||||
Nginx can serve static resources directly and proxy only the dynamic requests to gitea.
|
||||
Nginx is optimized for serving static content, while the proxying of large responses might be the opposite of that
|
||||
(see https://serverfault.com/q/587386).
|
||||
|
||||
Download a snap shot of the gitea source repository to `/path/to/gitea/`.
|
||||
|
||||
We are only interested in the `public/` directory and you can delete the rest.
|
||||
|
||||
Depending on the scale of your user base, you might want to split the traffic to two distinct servers,
|
||||
or use a cdn for the static files.
|
||||
|
||||
### using a single node and a single domain
|
||||
|
||||
Set `[server] STATIC_URL_PREFIX = /_/static` in your configuration.
|
||||
|
||||
```
|
||||
server {
|
||||
listen 80;
|
||||
server_name git.example.com;
|
||||
|
||||
location /_/static {
|
||||
alias /path/to/gitea/public;
|
||||
}
|
||||
|
||||
location / {
|
||||
proxy_pass http://localhost:3000;
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### using two nodes and two domains
|
||||
|
||||
Set `[server] STATIC_URL_PREFIX = http://cdn.example.com/gitea` in your configuration.
|
||||
|
||||
```
|
||||
# application server running gitea
|
||||
server {
|
||||
listen 80;
|
||||
server_name git.example.com;
|
||||
|
||||
location / {
|
||||
proxy_pass http://localhost:3000;
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
```
|
||||
# static content delivery server
|
||||
server {
|
||||
listen 80;
|
||||
server_name cdn.example.com;
|
||||
|
||||
location /gitea {
|
||||
alias /path/to/gitea/public;
|
||||
}
|
||||
|
||||
location / {
|
||||
return 404;
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## Using Apache HTTPD as a reverse proxy
|
||||
|
||||
If you want Apache HTTPD to serve your Gitea instance, you can add the following to your Apache HTTPD configuration (usually located at `/etc/apache2/httpd.conf` in Ubuntu):
|
||||
@@ -61,6 +129,8 @@ If you want Apache HTTPD to serve your Gitea instance, you can add the following
|
||||
|
||||
Note: The following Apache HTTPD mods must be enabled: `proxy`, `proxy_http`
|
||||
|
||||
If you wish to use Let's Encrypt with webroot validation, add the line `ProxyPass /.well-known !` before `ProxyPass` to disable proxying these requests to Gitea.
|
||||
|
||||
## Using Apache HTTPD with a sub-path as a reverse proxy
|
||||
|
||||
In case you already have a site, and you want Gitea to share the domain name, you can setup Apache HTTPD to serve Gitea under a sub-path by adding the following to you Apache HTTPD configuration (usually located at `/etc/apache2/httpd.conf` in Ubuntu):
|
||||
|
5
docs/layouts/_default/index.json
Normal file
5
docs/layouts/_default/index.json
Normal file
@@ -0,0 +1,5 @@
|
||||
{{- $.Scratch.Add "index" slice -}}
|
||||
{{- range .Site.RegularPages -}}
|
||||
{{- $.Scratch.Add "index" (dict "title" .Title "tags" .Params.tags "categories" .Params.categories "contents" .Plain "permalink" .Permalink) -}}
|
||||
{{- end -}}
|
||||
{{- $.Scratch.Get "index" | jsonify -}}
|
44
docs/layouts/doc/search.html
Normal file
44
docs/layouts/doc/search.html
Normal file
@@ -0,0 +1,44 @@
|
||||
{{ partial "header.html" . }}
|
||||
{{ partial "navbar.html" . }}
|
||||
|
||||
<section class="section">
|
||||
<div class="container is-centered page">
|
||||
<div class="columns">
|
||||
<div class="column is-one-quarter">
|
||||
{{ partial "menu" . }}
|
||||
</div>
|
||||
<div class="column">
|
||||
<div class=" content">
|
||||
<section class="resume-section p-3 p-lg-5 d-flex flex-column">
|
||||
<div class="my-auto" >
|
||||
<form action="{{ "search" | absLangURL }}">
|
||||
<label>Search:
|
||||
<input id="search-query" name="s"/>
|
||||
</label>
|
||||
</form>
|
||||
<br/>
|
||||
<div id="search-results"></div>
|
||||
</div>
|
||||
</section>
|
||||
<!-- this template is sucked in by search.js and appended to the search-results div above. So editing here will adjust style -->
|
||||
<script id="search-result-template" type="text/x-js-template">
|
||||
<div id="summary-${key}">
|
||||
<h4><a href="${link}">${title}</a></h4>
|
||||
<p>${snippet}</p>
|
||||
${ isset tags }<p>Tags: ${tags}</p>${ end }
|
||||
${ isset categories }<p>Categories: ${categories}</p>${ end }
|
||||
<hr/>
|
||||
</div>
|
||||
</script>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/fuse.js/3.4.5/fuse.min.js"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/mark.js/8.11.1/mark.min.js"></script>
|
||||
<script>document.LANG = "{{ .Language.Lang }}";</script>
|
||||
{{ $script := resources.Get "js/search.js" | minify | fingerprint -}}
|
||||
<script src="{{ $script.Permalink }}" {{ printf "integrity=%q" $script.Data.Integrity | safeHTMLAttr }}></script>
|
||||
{{ partial "footer.html" . }}
|
2
docs/static/_headers
vendored
2
docs/static/_headers
vendored
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
Content-Security-Policy: default-src 'self'; script-src 'self' 'unsafe-inline'; style-src 'self' https://fonts.googleapis.com https://cdnjs.cloudflare.com; font-src 'self' data: https://cdnjs.cloudflare.com https://fonts.gstatic.com
|
||||
Content-Security-Policy: default-src 'self'; script-src 'self' 'unsafe-inline' https://cdnjs.cloudflare.com; style-src 'self' 'unsafe-inline' https://fonts.googleapis.com https://cdnjs.cloudflare.com; font-src 'self' data: https://cdnjs.cloudflare.com https://fonts.gstatic.com
|
||||
X-Frame-Options: DENY
|
||||
X-Xss-Protection: 1; mode=block
|
||||
X-Content-Type-Options: nosniff
|
||||
|
72
go.mod
72
go.mod
@@ -4,53 +4,49 @@ go 1.13
|
||||
|
||||
require (
|
||||
cloud.google.com/go v0.45.0 // indirect
|
||||
gitea.com/lunny/levelqueue v0.1.0
|
||||
gitea.com/macaron/binding v0.0.0-20190822013154-a5f53841ed2b
|
||||
gitea.com/macaron/cache v0.0.0-20190822004001-a6e7fee4ee76
|
||||
gitea.com/macaron/captcha v0.0.0-20190822015246-daa973478bae
|
||||
gitea.com/macaron/cors v0.0.0-20190821152825-7dcef4a17175
|
||||
gitea.com/macaron/csrf v0.0.0-20190822024205-3dc5a4474439
|
||||
gitea.com/macaron/gzip v0.0.0-20191118033930-0c4c5566a0e5
|
||||
gitea.com/macaron/i18n v0.0.0-20190822004228-474e714e2223
|
||||
gitea.com/macaron/inject v0.0.0-20190805023432-d4c86e31027a
|
||||
gitea.com/macaron/macaron v1.3.3-0.20190821202302-9646c0587edb
|
||||
gitea.com/macaron/macaron v1.4.0
|
||||
gitea.com/macaron/session v0.0.0-20190821211443-122c47c5f705
|
||||
gitea.com/macaron/toolbox v0.0.0-20190822013122-05ff0fc766b7
|
||||
github.com/PuerkitoBio/goquery v1.5.0
|
||||
github.com/RoaringBitmap/roaring v0.4.7 // indirect
|
||||
github.com/RoaringBitmap/roaring v0.4.21 // indirect
|
||||
github.com/bgentry/speakeasy v0.1.0 // indirect
|
||||
github.com/blevesearch/bleve v0.0.0-20190214220507-05d86ea8f6e3
|
||||
github.com/blevesearch/bleve v0.8.1
|
||||
github.com/blevesearch/blevex v0.0.0-20180227211930-4b158bb555a3 // indirect
|
||||
github.com/blevesearch/go-porterstemmer v0.0.0-20141230013033-23a2c8e5cf1f // indirect
|
||||
github.com/blevesearch/segment v0.0.0-20160105220820-db70c57796cc // indirect
|
||||
github.com/blevesearch/go-porterstemmer v1.0.2 // indirect
|
||||
github.com/blevesearch/segment v0.0.0-20160915185041-762005e7a34f // indirect
|
||||
github.com/boombuler/barcode v0.0.0-20161226211916-fe0f26ff6d26 // indirect
|
||||
github.com/chaseadamsio/goorgeous v0.0.0-20170901132237-098da33fde5f
|
||||
github.com/couchbase/vellum v0.0.0-20190111184608-e91b68ff3efe // indirect
|
||||
github.com/couchbase/gomemcached v0.0.0-20191004160342-7b5da2ec40b2 // indirect
|
||||
github.com/couchbase/goutils v0.0.0-20191018232750-b49639060d85 // indirect
|
||||
github.com/couchbase/vellum v0.0.0-20190829182332-ef2e028c01fd // indirect
|
||||
github.com/cznic/b v0.0.0-20181122101859-a26611c4d92d // indirect
|
||||
github.com/cznic/mathutil v0.0.0-20181122101859-297441e03548 // indirect
|
||||
github.com/cznic/strutil v0.0.0-20181122101858-275e90344537 // indirect
|
||||
github.com/denisenkom/go-mssqldb v0.0.0-20190924004331-208c0a498538
|
||||
github.com/denisenkom/go-mssqldb v0.0.0-20191128021309-1d7a30a10f73
|
||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible
|
||||
github.com/editorconfig/editorconfig-core-go/v2 v2.1.1
|
||||
github.com/emirpasic/gods v1.12.0
|
||||
github.com/etcd-io/bbolt v1.3.2 // indirect
|
||||
github.com/etcd-io/bbolt v1.3.3 // indirect
|
||||
github.com/ethantkoenig/rupture v0.0.0-20180203182544-0a76f03a811a
|
||||
github.com/facebookgo/clock v0.0.0-20150410010913-600d898af40a // indirect
|
||||
github.com/facebookgo/ensure v0.0.0-20160127193407-b4ab57deab51 // indirect
|
||||
github.com/facebookgo/freeport v0.0.0-20150612182905-d4adf43b75b9 // indirect
|
||||
github.com/facebookgo/grace v0.0.0-20160926231715-5729e484473f
|
||||
github.com/facebookgo/httpdown v0.0.0-20160323221027-a3b1354551a2 // indirect
|
||||
github.com/facebookgo/stack v0.0.0-20160209184415-751773369052 // indirect
|
||||
github.com/facebookgo/stats v0.0.0-20151006221625-1b76add642e4 // indirect
|
||||
github.com/facebookgo/subset v0.0.0-20150612182917-8dac2c3c4870 // indirect
|
||||
github.com/gliderlabs/ssh v0.2.2
|
||||
github.com/glycerine/go-unsnap-stream v0.0.0-20180323001048-9f0cb55181dd // indirect
|
||||
github.com/glycerine/goconvey v0.0.0-20190315024820-982ee783a72e // indirect
|
||||
github.com/glycerine/go-unsnap-stream v0.0.0-20190901134440-81cf024a9e0a // indirect
|
||||
github.com/go-openapi/jsonreference v0.19.3 // indirect
|
||||
github.com/go-openapi/runtime v0.19.5 // indirect
|
||||
github.com/go-redis/redis v6.15.2+incompatible
|
||||
github.com/go-sql-driver/mysql v1.4.1
|
||||
github.com/go-swagger/go-swagger v0.20.1
|
||||
github.com/go-xorm/xorm v0.7.9
|
||||
github.com/go-swagger/go-swagger v0.21.0
|
||||
github.com/gobwas/glob v0.2.3
|
||||
github.com/gogits/chardet v0.0.0-20150115103509-2404f7772561
|
||||
github.com/gogs/chardet v0.0.0-20191104214054-4b6791f73a28
|
||||
github.com/gogs/cron v0.0.0-20171120032916-9f6c956d3e14
|
||||
github.com/google/go-github/v24 v24.0.1
|
||||
github.com/gorilla/context v1.1.1
|
||||
@@ -61,67 +57,61 @@ require (
|
||||
github.com/joho/godotenv v1.3.0 // indirect
|
||||
github.com/kballard/go-shellquote v0.0.0-20170619183022-cd60e84ee657
|
||||
github.com/keybase/go-crypto v0.0.0-20170605145657-00ac4db533f6
|
||||
github.com/klauspost/compress v0.0.0-20161025140425-8df558b6cb6f
|
||||
github.com/klauspost/cpuid v0.0.0-20160302075316-09cded8978dc // indirect
|
||||
github.com/klauspost/crc32 v0.0.0-20161016154125-cb6bfca970f6 // indirect
|
||||
github.com/lafriks/xormstore v1.3.1
|
||||
github.com/klauspost/compress v1.9.2
|
||||
github.com/lafriks/xormstore v1.3.2
|
||||
github.com/lib/pq v1.2.0
|
||||
github.com/lunny/dingtalk_webhook v0.0.0-20171025031554-e3534c89ef96
|
||||
github.com/lunny/levelqueue v0.0.0-20190217115915-02b525a4418e
|
||||
github.com/mailru/easyjson v0.7.0 // indirect
|
||||
github.com/markbates/goth v1.56.0
|
||||
github.com/markbates/goth v1.61.2
|
||||
github.com/mattn/go-isatty v0.0.7
|
||||
github.com/mattn/go-oci8 v0.0.0-20190320171441-14ba190cf52d // indirect
|
||||
github.com/mattn/go-sqlite3 v1.11.0
|
||||
github.com/mcuadros/go-version v0.0.0-20190308113854-92cdf37c5b75
|
||||
github.com/microcosm-cc/bluemonday v0.0.0-20161012083705-f77f16ffc87a
|
||||
github.com/mschoch/smat v0.0.0-20160514031455-90eadee771ae // indirect
|
||||
github.com/msteinert/pam v0.0.0-20151204160544-02ccfbfaf0cc
|
||||
github.com/nfnt/resize v0.0.0-20160724205520-891127d8d1b5
|
||||
github.com/niklasfasching/go-org v0.1.8
|
||||
github.com/oliamb/cutter v0.2.2
|
||||
github.com/philhofer/fwd v1.0.0 // indirect
|
||||
github.com/pkg/errors v0.8.1
|
||||
github.com/pquerna/otp v0.0.0-20160912161815-54653902c20e
|
||||
github.com/prometheus/client_golang v1.1.0
|
||||
github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4 // indirect
|
||||
github.com/prometheus/procfs v0.0.4 // indirect
|
||||
github.com/quasoft/websspi v1.0.0
|
||||
github.com/remyoudompheng/bigfft v0.0.0-20190321074620-2f0d2b0e0001 // indirect
|
||||
github.com/russross/blackfriday v0.0.0-20180428102519-11635eb403ff
|
||||
github.com/saintfish/chardet v0.0.0-20120816061221-3af4cd4741ca // indirect
|
||||
github.com/satori/go.uuid v1.2.0
|
||||
github.com/sergi/go-diff v1.0.0
|
||||
github.com/shurcooL/httpfs v0.0.0-20190527155220-6a4d4a70508b // indirect
|
||||
github.com/shurcooL/sanitized_anchor_name v0.0.0-20160918041101-1dba4b3954bc // indirect
|
||||
github.com/shurcooL/vfsgen v0.0.0-20181202132449-6a9ea43bcacd
|
||||
github.com/steveyen/gtreap v0.0.0-20150807155958-0abe01ef9be2 // indirect
|
||||
github.com/stretchr/testify v1.4.0
|
||||
github.com/tecbot/gorocksdb v0.0.0-20181010114359-8752a9433481 // indirect
|
||||
github.com/tinylib/msgp v0.0.0-20180516164116-c8cf64dff200 // indirect
|
||||
github.com/tstranex/u2f v1.0.0
|
||||
github.com/unknwon/cae v0.0.0-20190822084630-55a0b64484a1
|
||||
github.com/unknwon/com v0.0.0-20190804042917-757f69c95f3e
|
||||
github.com/unknwon/com v1.0.1
|
||||
github.com/unknwon/i18n v0.0.0-20190805065654-5c6446a380b6
|
||||
github.com/unknwon/paginater v0.0.0-20151104151617-7748a72e0141
|
||||
github.com/urfave/cli v1.20.0
|
||||
github.com/willf/bitset v0.0.0-20180426185212-8ce1146b8621 // indirect
|
||||
github.com/yohcop/openid-go v0.0.0-20160914080427-2c050d2dae53
|
||||
golang.org/x/crypto v0.0.0-20190927123631-a832865fa7ad
|
||||
golang.org/x/net v0.0.0-20190909003024-a7b16738d86b
|
||||
github.com/yuin/goldmark v1.1.19
|
||||
go.etcd.io/bbolt v1.3.3 // indirect
|
||||
golang.org/x/crypto v0.0.0-20200219234226-1ad67e1f0ef4
|
||||
golang.org/x/net v0.0.0-20191101175033-0deb6923b6d9
|
||||
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45
|
||||
golang.org/x/sys v0.0.0-20190910064555-bbd175535a8b
|
||||
golang.org/x/sys v0.0.0-20200219091948-cb0a6d8edb6c
|
||||
golang.org/x/text v0.3.2
|
||||
golang.org/x/tools v0.0.0-20190910221609-7f5965fd7709 // indirect
|
||||
golang.org/x/tools v0.0.0-20191213221258-04c2e8eff935 // indirect
|
||||
gopkg.in/alexcesaro/quotedprintable.v3 v3.0.0-20150716171945-2caba252f4dc // indirect
|
||||
gopkg.in/asn1-ber.v1 v1.0.0-20150924051756-4e86f4367175 // indirect
|
||||
gopkg.in/editorconfig/editorconfig-core-go.v1 v1.3.0
|
||||
gopkg.in/gomail.v2 v2.0.0-20160411212932-81ebce5c23df
|
||||
gopkg.in/ini.v1 v1.46.0
|
||||
gopkg.in/ini.v1 v1.51.1
|
||||
gopkg.in/ldap.v3 v3.0.2
|
||||
gopkg.in/src-d/go-billy.v4 v4.3.2
|
||||
gopkg.in/src-d/go-git.v4 v4.13.1
|
||||
gopkg.in/stretchr/testify.v1 v1.2.2 // indirect
|
||||
gopkg.in/testfixtures.v2 v2.5.0
|
||||
mvdan.cc/xurls/v2 v2.1.0
|
||||
strk.kbt.io/projects/go/libravatar v0.0.0-20191008002943-06d1c002b251
|
||||
xorm.io/builder v0.3.6
|
||||
xorm.io/core v0.7.2
|
||||
xorm.io/xorm v0.8.1
|
||||
)
|
||||
|
242
go.sum
242
go.sum
@@ -1,17 +1,16 @@
|
||||
cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
|
||||
cloud.google.com/go v0.30.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
|
||||
cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
|
||||
cloud.google.com/go v0.37.4 h1:glPeL3BQJsbF6aIIYfZizMwc5LTYz250bDMjttbBGAU=
|
||||
cloud.google.com/go v0.37.4/go.mod h1:NHPJ89PdicEuT9hdPXMROBD91xc5uRDxsMtSB16k7hw=
|
||||
cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU=
|
||||
cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU=
|
||||
cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY=
|
||||
cloud.google.com/go v0.44.3 h1:0sMegbmn/8uTwpNkB0q9cLEpZ2W5a6kl+wtBQgPWBJQ=
|
||||
cloud.google.com/go v0.44.3/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY=
|
||||
cloud.google.com/go v0.45.0 h1:bALuGBSgE+BD4rxsopAYlqjcwqcQtye6pWG4bC3N/k0=
|
||||
cloud.google.com/go v0.45.0/go.mod h1:452BcPOeI9AZfbvDw0Tbo7D32wA+WX9WME8AZwMEDZU=
|
||||
cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o=
|
||||
cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE=
|
||||
gitea.com/lunny/levelqueue v0.1.0 h1:7wMk0VH6mvKN6vZEZCy9nUDgRmdPLgeNrm1NkW8EHNk=
|
||||
gitea.com/lunny/levelqueue v0.1.0/go.mod h1:G7hVb908t0Bl0uk7zGSg14fyzNtxgtD9Shf04wkMK7s=
|
||||
gitea.com/macaron/binding v0.0.0-20190822013154-a5f53841ed2b h1:vXt85uYV17KURaUlhU7v4GbCShkqRZDSfo0TkC0YCjQ=
|
||||
gitea.com/macaron/binding v0.0.0-20190822013154-a5f53841ed2b/go.mod h1:Cxadig6POWpPYYSfg23E7jo35Yf0yvsdC1lifoKWmPo=
|
||||
gitea.com/macaron/cache v0.0.0-20190822004001-a6e7fee4ee76 h1:mMsMEg90c5KXQgRWsH8D6GHXfZIW1RAe5S9VYIb12lM=
|
||||
@@ -22,6 +21,8 @@ gitea.com/macaron/cors v0.0.0-20190821152825-7dcef4a17175 h1:ikzdAGB6SsUGByW5wKl
|
||||
gitea.com/macaron/cors v0.0.0-20190821152825-7dcef4a17175/go.mod h1:rtOK4J20kpMD9XcNsnO5YA843YSTe/MUMbDj/TJ/Q7A=
|
||||
gitea.com/macaron/csrf v0.0.0-20190822024205-3dc5a4474439 h1:88c34YM29a1GlWLrLBaG/GTT2htDdJz1u3n9+lmPolg=
|
||||
gitea.com/macaron/csrf v0.0.0-20190822024205-3dc5a4474439/go.mod h1:IsQPHx73HnnqFBYiVHjg87q4XBZyGXXu77xANukvZuk=
|
||||
gitea.com/macaron/gzip v0.0.0-20191118033930-0c4c5566a0e5 h1:G/a7r0r2jEelSynBlv1+PAEZQKfsdRHQUMb1PlNvemM=
|
||||
gitea.com/macaron/gzip v0.0.0-20191118033930-0c4c5566a0e5/go.mod h1:jGHtoovArcQj+sw7NJxyPgjuRxOSG9a/oFu3VkLRTKQ=
|
||||
gitea.com/macaron/i18n v0.0.0-20190822004228-474e714e2223 h1:iZWwQif/LHMjBgfY/ua8CFVa4XMDfbbs7EZ0Q1dYguU=
|
||||
gitea.com/macaron/i18n v0.0.0-20190822004228-474e714e2223/go.mod h1:+qsc10s4hBsHKU/9luGGumFh4m5FFVc7uih+8/mM1NY=
|
||||
gitea.com/macaron/inject v0.0.0-20190803172902-8375ba841591/go.mod h1:h6E4kLao1Yko6DOU6QDnQPcuoNzvbZqzj2mtPcEn1aM=
|
||||
@@ -30,6 +31,8 @@ gitea.com/macaron/inject v0.0.0-20190805023432-d4c86e31027a/go.mod h1:h6E4kLao1Y
|
||||
gitea.com/macaron/macaron v1.3.3-0.20190803174002-53e005ff4827/go.mod h1:/rvxMjIkOq4BM8uPUb+VHuU02ZfAO6R4+wD//tiCiRw=
|
||||
gitea.com/macaron/macaron v1.3.3-0.20190821202302-9646c0587edb h1:amL0md6orTj1tXY16ANzVU9FmzQB+W7aJwp8pVDbrmA=
|
||||
gitea.com/macaron/macaron v1.3.3-0.20190821202302-9646c0587edb/go.mod h1:0coI+mSPSwbsyAbOuFllVS38awuk9mevhLD52l50Gjs=
|
||||
gitea.com/macaron/macaron v1.4.0 h1:FY1QDGqyuUzs21K6ChkbYbRUfwL7v2aUrhNEJ0IgsAw=
|
||||
gitea.com/macaron/macaron v1.4.0/go.mod h1:P7hfDbQjcW22lkYkXlxdRIfWOXxH2+K4EogN4Q0UlLY=
|
||||
gitea.com/macaron/session v0.0.0-20190821211443-122c47c5f705 h1:mvkQGAlON1Z6Y8pqa/+FpYIskk54mazuECUfZK5oTg0=
|
||||
gitea.com/macaron/session v0.0.0-20190821211443-122c47c5f705/go.mod h1:1ujH0jD6Ca4iK9NL0Q2a7fG2chvXx5hVa7hBfABwpkA=
|
||||
gitea.com/macaron/toolbox v0.0.0-20190822013122-05ff0fc766b7 h1:N9QFoeNsUXLhl14mefLzGluqV7w2mGU3u+iZU+jCeWk=
|
||||
@@ -38,7 +41,6 @@ github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ
|
||||
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
|
||||
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
|
||||
github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU=
|
||||
github.com/OneOfOne/xxhash v1.2.5/go.mod h1:eZbhyaAYD41SGSSsnmcpxVoRiQ/MPUTjUdIIOT9Um7Q=
|
||||
github.com/PuerkitoBio/goquery v1.5.0 h1:uGvmFXOA73IKluu/F84Xd1tt/z07GYm8X49XKHP7EJk=
|
||||
github.com/PuerkitoBio/goquery v1.5.0/go.mod h1:qD2PgZ9lccMbQlc7eEOjaeRlFQON7xY8kdmcsrnKqMg=
|
||||
github.com/PuerkitoBio/purell v1.1.0/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0=
|
||||
@@ -46,8 +48,8 @@ github.com/PuerkitoBio/purell v1.1.1 h1:WEQqlqaGbrPkxLJWfBwQmfEAE1Z7ONdDLqrN38tN
|
||||
github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0=
|
||||
github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 h1:d+Bc7a5rLufV/sSk/8dngufqelfh6jnri85riMAaF/M=
|
||||
github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE=
|
||||
github.com/RoaringBitmap/roaring v0.4.7 h1:eGUudvFzvF7Kxh7JjYvXfI1f7l22/2duFby7r5+d4oc=
|
||||
github.com/RoaringBitmap/roaring v0.4.7/go.mod h1:8khRDP4HmeXns4xIj9oGrKSz7XTQiJx2zgh7AcNke4w=
|
||||
github.com/RoaringBitmap/roaring v0.4.21 h1:WJ/zIlNX4wQZ9x8Ey33O1UaD9TCTakYsdLFSBcTwH+8=
|
||||
github.com/RoaringBitmap/roaring v0.4.21/go.mod h1:D0gp8kJQgE1A4LQ5wFLggQEyvDi06Mq5mKs52e1TwOo=
|
||||
github.com/Shopify/sarama v1.19.0/go.mod h1:FVkBWblsNy7DGZRfXLU0O9RCGt5g3g3yEuWXgklEdEo=
|
||||
github.com/Shopify/toxiproxy v2.1.4+incompatible/go.mod h1:OXgGpZ6Cli1/URJOF1DMxUHB2q5Ap20/P/eIdh4G0pI=
|
||||
github.com/Unknwon/com v0.0.0-20190321035513-0fed4efef755/go.mod h1:voKvFVpXBJxdIPeqjoJuLK+UVcRlo/JLjeToGxPYu68=
|
||||
@@ -67,50 +69,47 @@ github.com/asaskevich/govalidator v0.0.0-20180720115003-f9ffefc3facf/go.mod h1:l
|
||||
github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a h1:idn718Q4B6AGu/h5Sxe66HYVdqdGu2l9Iebqhi/AEoA=
|
||||
github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY=
|
||||
github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=
|
||||
github.com/beorn7/perks v1.0.0 h1:HWo1m869IqiPhD389kmkxeTalrjNbbJTC8LXupb+sl0=
|
||||
github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8=
|
||||
github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM=
|
||||
github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw=
|
||||
github.com/bgentry/speakeasy v0.1.0 h1:ByYyxL9InA1OWqxJqqp2A5pYHUrCiAL6K3J+LKSsQkY=
|
||||
github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs=
|
||||
github.com/blevesearch/bleve v0.0.0-20190214220507-05d86ea8f6e3 h1:vinCy/rcjbtxWnMiw11CbMKcuyNi+y4L4MbZUpk7m4M=
|
||||
github.com/blevesearch/bleve v0.0.0-20190214220507-05d86ea8f6e3/go.mod h1:Y2lmIkzV6mcNfAnAdOd+ZxHkHchhBfU/xroGIp61wfw=
|
||||
github.com/blevesearch/bleve v0.8.1 h1:20zBREtGe8dvBxCC+717SaxKcUVQOWk3/Fm75vabKpU=
|
||||
github.com/blevesearch/bleve v0.8.1/go.mod h1:Y2lmIkzV6mcNfAnAdOd+ZxHkHchhBfU/xroGIp61wfw=
|
||||
github.com/blevesearch/blevex v0.0.0-20180227211930-4b158bb555a3 h1:U6vnxZrTfItfiUiYx0lf/LgHjRSfaKK5QHSom3lEbnA=
|
||||
github.com/blevesearch/blevex v0.0.0-20180227211930-4b158bb555a3/go.mod h1:WH+MU2F4T0VmSdaPX+Wu5GYoZBrYWdOZWSjzvYcDmqQ=
|
||||
github.com/blevesearch/go-porterstemmer v0.0.0-20141230013033-23a2c8e5cf1f h1:J9ZVHbB2X6JNxbKw/f3Y4E9Xq+Ro+zPiivzgmi3RTvg=
|
||||
github.com/blevesearch/go-porterstemmer v0.0.0-20141230013033-23a2c8e5cf1f/go.mod h1:haWQqFT3RdOGz7PJuM3or/pWNJS1pKkoZJWCkWu0DVA=
|
||||
github.com/blevesearch/segment v0.0.0-20160105220820-db70c57796cc h1:7OfDAkuAGx71ruzOIFqCkHqGIsVZU0C7PMw5u1bIrwU=
|
||||
github.com/blevesearch/segment v0.0.0-20160105220820-db70c57796cc/go.mod h1:IInt5XRvpiGE09KOk9mmCMLjHhydIhNPKPPFLFBB7L8=
|
||||
github.com/blevesearch/go-porterstemmer v1.0.2 h1:qe7n69gBd1OLY5sHKnxQHIbzn0LNJA4hpAf+5XDxV2I=
|
||||
github.com/blevesearch/go-porterstemmer v1.0.2/go.mod h1:haWQqFT3RdOGz7PJuM3or/pWNJS1pKkoZJWCkWu0DVA=
|
||||
github.com/blevesearch/segment v0.0.0-20160915185041-762005e7a34f h1:kqbi9lqXLLs+zfWlgo1PIiRQ86n33K1JKotjj4rSYOg=
|
||||
github.com/blevesearch/segment v0.0.0-20160915185041-762005e7a34f/go.mod h1:IInt5XRvpiGE09KOk9mmCMLjHhydIhNPKPPFLFBB7L8=
|
||||
github.com/boombuler/barcode v0.0.0-20161226211916-fe0f26ff6d26 h1:NGpwhs9FOwddM6TptNrq2ycby4s24TcppSe5uG4DA/Q=
|
||||
github.com/boombuler/barcode v0.0.0-20161226211916-fe0f26ff6d26/go.mod h1:paBWMcWSl3LHKBqUq+rly7CNSldXjb2rDl3JlRe0mD8=
|
||||
github.com/bradfitz/gomemcache v0.0.0-20190329173943-551aad21a668 h1:U/lr3Dgy4WK+hNk4tyD+nuGjpVLPEHuJSFXMw11/HPA=
|
||||
github.com/bradfitz/gomemcache v0.0.0-20190329173943-551aad21a668/go.mod h1:H0wQNHz2YrLsuXOZozoeDmnHXkNCRmMW0gwFWDfEZDA=
|
||||
github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc=
|
||||
github.com/chaseadamsio/goorgeous v0.0.0-20170901132237-098da33fde5f h1:REH9VH5ubNR0skLaOxK7TRJeRbE2dDfvaouQo8FsRcA=
|
||||
github.com/chaseadamsio/goorgeous v0.0.0-20170901132237-098da33fde5f/go.mod h1:6QaC0vFoKWYDth94dHFNgRT2YkT5FHdQp/Yx15aAAi0=
|
||||
github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
|
||||
github.com/cockroachdb/apd v1.1.0 h1:3LFP3629v+1aKXU5Q37mxmRxX/pIu1nijXydLShEq5I=
|
||||
github.com/cockroachdb/apd v1.1.0/go.mod h1:8Sl8LxpKi29FqWXR16WEFZRNSz3SoPzUzeMeY4+DwBQ=
|
||||
github.com/corbym/gocrest v1.0.3 h1:gwEdq6RkTmq+09CTuM29DfKOCtZ7G7bcyxs3IZ6EVdU=
|
||||
github.com/corbym/gocrest v1.0.3/go.mod h1:maVFL5lbdS2PgfOQgGRWDYTeunSWQeiEgoNdTABShCs=
|
||||
github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk=
|
||||
github.com/coreos/bbolt v1.3.3/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk=
|
||||
github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
|
||||
github.com/coreos/etcd v3.3.15+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
|
||||
github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk=
|
||||
github.com/coreos/go-oidc v2.1.0+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc=
|
||||
github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
|
||||
github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
|
||||
github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
|
||||
github.com/coreos/go-systemd v0.0.0-20190719114852-fd7a80b32e1f/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
|
||||
github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA=
|
||||
github.com/couchbase/gomemcached v0.0.0-20190515232915-c4b4ca0eb21d h1:XMf4E1U+b9E3ElF0mjvfXZdflBRZz4gLp16nQ/QSHQM=
|
||||
github.com/couchbase/gomemcached v0.0.0-20190515232915-c4b4ca0eb21d/go.mod h1:srVSlQLB8iXBVXHgnqemxUXqN6FCvClgCMPCsjBDR7c=
|
||||
github.com/couchbase/gomemcached v0.0.0-20191004160342-7b5da2ec40b2 h1:vZryARwW4PSFXd9arwegEywvMTvPuXL3/oa+4L5NTe8=
|
||||
github.com/couchbase/gomemcached v0.0.0-20191004160342-7b5da2ec40b2/go.mod h1:srVSlQLB8iXBVXHgnqemxUXqN6FCvClgCMPCsjBDR7c=
|
||||
github.com/couchbase/goutils v0.0.0-20190315194238-f9d42b11473b h1:bZ9rKU2/V8sY+NulSfxDOnXTWcs1rySqdF1sVepihvo=
|
||||
github.com/couchbase/goutils v0.0.0-20190315194238-f9d42b11473b/go.mod h1:BQwMFlJzDjFDG3DJUdU0KORxn88UlsOULuxLExMh3Hs=
|
||||
github.com/couchbase/vellum v0.0.0-20190111184608-e91b68ff3efe h1:2o6Y7KMjJNsuMTF8f2H2eTKRhqH7+bQbjr+D+LnhE5M=
|
||||
github.com/couchbase/vellum v0.0.0-20190111184608-e91b68ff3efe/go.mod h1:prYTC8EgTu3gwbqJihkud9zRXISvyulAplQ6exdCo1g=
|
||||
github.com/couchbase/goutils v0.0.0-20191018232750-b49639060d85 h1:0WMIDtuXCKEm4wtAJgAAXa/qtM5O9MariLwgHaRlYmk=
|
||||
github.com/couchbase/goutils v0.0.0-20191018232750-b49639060d85/go.mod h1:BQwMFlJzDjFDG3DJUdU0KORxn88UlsOULuxLExMh3Hs=
|
||||
github.com/couchbase/vellum v0.0.0-20190829182332-ef2e028c01fd h1:zeuJhcG3f8eePshH3KxkNE+Xtl53pVln9MOUPMyr/1w=
|
||||
github.com/couchbase/vellum v0.0.0-20190829182332-ef2e028c01fd/go.mod h1:xbc8Ff/oG7h2ejd7AlwOpfd+6QZntc92ygpAOfGwcKY=
|
||||
github.com/couchbaselabs/go-couchbase v0.0.0-20190708161019-23e7ca2ce2b7 h1:1XjEY/gnjQ+AfXef2U6dxCquhiRzkEpxZuWqs+QxTL8=
|
||||
github.com/couchbaselabs/go-couchbase v0.0.0-20190708161019-23e7ca2ce2b7/go.mod h1:mby/05p8HE5yHEAKiIH/555NoblMs7PtW6NrYshDruc=
|
||||
github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE=
|
||||
github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY=
|
||||
github.com/cupcake/rdb v0.0.0-20161107195141-43ba34106c76/go.mod h1:vYwsqCOLxGiisLwp9rITslkFNpZD5rz43tf41QFkTWY=
|
||||
github.com/cznic/b v0.0.0-20181122101859-a26611c4d92d h1:SwD98825d6bdB+pEuTxWOXiSjBrHdOl/UVp75eI7JT8=
|
||||
@@ -125,37 +124,30 @@ github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSs
|
||||
github.com/denisenkom/go-mssqldb v0.0.0-20190707035753-2be1aa521ff4/go.mod h1:zAg7JM8CkOJ43xKXIj7eRO9kmWm/TW578qo+oDO6tuM=
|
||||
github.com/denisenkom/go-mssqldb v0.0.0-20190924004331-208c0a498538 h1:bpWCJ5MddHsv4Xtl3azkK89mZzd/vvut32mvAnKbyUA=
|
||||
github.com/denisenkom/go-mssqldb v0.0.0-20190924004331-208c0a498538/go.mod h1:xbL0rPBG9cCiLr28tMa8zpbdarY27NDyej4t/EjAShU=
|
||||
github.com/denisenkom/go-mssqldb v0.0.0-20191128021309-1d7a30a10f73 h1:OGNva6WhsKst5OZf7eZOklDztV3hwtTHovdrLHV+MsA=
|
||||
github.com/denisenkom/go-mssqldb v0.0.0-20191128021309-1d7a30a10f73/go.mod h1:xbL0rPBG9cCiLr28tMa8zpbdarY27NDyej4t/EjAShU=
|
||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible h1:7qlOGliEKZXTDg6OTjfoBKDXWrumCAMpl/TFQ4/5kLM=
|
||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
|
||||
github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
|
||||
github.com/dgryski/go-sip13 v0.0.0-20190329191031-25c5027a8c7b/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
|
||||
github.com/docker/go-units v0.3.3/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk=
|
||||
github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk=
|
||||
github.com/eapache/go-resiliency v1.1.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5mFgVsvEsIPBvNs=
|
||||
github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1:+020luEh2TKB4/GOp8oxxtq0Daoen/Cii55CzbTV6DU=
|
||||
github.com/eapache/queue v1.1.0/go.mod h1:6eCeP0CKFpHLu8blIFXhExK/dRa7WDZfr6jVFPTqq+I=
|
||||
github.com/editorconfig/editorconfig-core-go/v2 v2.1.1 h1:mhPg/0hGebcpiiQLqJD2PWWyoHRLEdZ3sXKaEvT1EQU=
|
||||
github.com/editorconfig/editorconfig-core-go/v2 v2.1.1/go.mod h1:/LuhWJiQ9Gvo1DhVpa4ssm5qeg8rrztdtI7j/iCie2k=
|
||||
github.com/edsrzf/mmap-go v1.0.0 h1:CEBF7HpRnUCSJgGUb5h1Gm7e3VkmVDrR8lvWVLtrOFw=
|
||||
github.com/edsrzf/mmap-go v1.0.0/go.mod h1:YO35OhQPt3KJa3ryjFM5Bs14WD66h8eGKpfaBNrHW5M=
|
||||
github.com/emirpasic/gods v1.12.0 h1:QAUIPSaCu4G+POclxeqb3F+WPpdKqFGlw36+yOzGlrg=
|
||||
github.com/emirpasic/gods v1.12.0/go.mod h1:YfzfFFoVP/catgzJb4IKIqXjX78Ha8FMSDh3ymbK86o=
|
||||
github.com/etcd-io/bbolt v1.3.2 h1:RLRQ0TKLX7DlBRXAJHvbmXL17Q3KNnTBtZ9B6Qo+/Y0=
|
||||
github.com/etcd-io/bbolt v1.3.2/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw=
|
||||
github.com/etcd-io/bbolt v1.3.3 h1:gSJmxrs37LgTqR/oyJBWok6k6SvXEUerFTbltIhXkBM=
|
||||
github.com/etcd-io/bbolt v1.3.3/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw=
|
||||
github.com/ethantkoenig/rupture v0.0.0-20180203182544-0a76f03a811a h1:M1bRpaZAn4GSsqu3hdK2R8H0AH9O6vqCTCbm2oAFGfE=
|
||||
github.com/ethantkoenig/rupture v0.0.0-20180203182544-0a76f03a811a/go.mod h1:MkKY/CB98aVE4VxO63X5vTQKUgcn+3XP15LMASe3lYs=
|
||||
github.com/facebookgo/clock v0.0.0-20150410010913-600d898af40a h1:yDWHCSQ40h88yih2JAcL6Ls/kVkSE8GFACTGVnMPruw=
|
||||
github.com/facebookgo/clock v0.0.0-20150410010913-600d898af40a/go.mod h1:7Ga40egUymuWXxAe151lTNnCv97MddSOVsjpPPkityA=
|
||||
github.com/facebookgo/ensure v0.0.0-20160127193407-b4ab57deab51 h1:0JZ+dUmQeA8IIVUMzysrX4/AKuQwWhV2dYQuPZdvdSQ=
|
||||
github.com/facebookgo/ensure v0.0.0-20160127193407-b4ab57deab51/go.mod h1:Yg+htXGokKKdzcwhuNDwVvN+uBxDGXJ7G/VN1d8fa64=
|
||||
github.com/facebookgo/freeport v0.0.0-20150612182905-d4adf43b75b9 h1:wWke/RUCl7VRjQhwPlR/v0glZXNYzBHdNUzf/Am2Nmg=
|
||||
github.com/facebookgo/freeport v0.0.0-20150612182905-d4adf43b75b9/go.mod h1:uPmAp6Sws4L7+Q/OokbWDAK1ibXYhB3PXFP1kol5hPg=
|
||||
github.com/facebookgo/grace v0.0.0-20160926231715-5729e484473f h1:0mlfEUWnUDVZnqWEVHGerL5bKYDKMEmT/Qk/W/3nGuo=
|
||||
github.com/facebookgo/grace v0.0.0-20160926231715-5729e484473f/go.mod h1:KigFdumBXUPSwzLDbeuzyt0elrL7+CP7TKuhrhT4bcU=
|
||||
github.com/facebookgo/httpdown v0.0.0-20160323221027-a3b1354551a2 h1:3Zvf9wRhl1cOhckN1oRGWPOkIhOketmEcrQ4TeFAoR4=
|
||||
github.com/facebookgo/httpdown v0.0.0-20160323221027-a3b1354551a2/go.mod h1:TUV/fX3XrTtBQb5+ttSUJzcFgLNpILONFTKmBuk5RSw=
|
||||
github.com/facebookgo/stack v0.0.0-20160209184415-751773369052 h1:JWuenKqqX8nojtoVVWjGfOF9635RETekkoH6Cc9SX0A=
|
||||
github.com/facebookgo/stack v0.0.0-20160209184415-751773369052/go.mod h1:UbMTZqLaRiH3MsBH8va0n7s1pQYcu3uTb8G4tygF4Zg=
|
||||
github.com/facebookgo/stats v0.0.0-20151006221625-1b76add642e4 h1:0YtRCqIZs2+Tz49QuH6cJVw/IFqzo39gEqZ0iYLxD2M=
|
||||
github.com/facebookgo/stats v0.0.0-20151006221625-1b76add642e4/go.mod h1:vsJz7uE339KUCpBXx3JAJzSRH7Uk4iGGyJzR529qDIA=
|
||||
github.com/facebookgo/subset v0.0.0-20150612182917-8dac2c3c4870 h1:E2s37DuLxFhQDg5gKsWoLBOB0n+ZW8s599zru8FJ2/Y=
|
||||
github.com/facebookgo/subset v0.0.0-20150612182917-8dac2c3c4870/go.mod h1:5tD+neXqOorC30/tWg0LCSkrqj/AR6gu8yY8/fpw1q0=
|
||||
github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568 h1:BHsljHzVlRcyQhjrss6TZTdY2VfCqZPbv5k3iBFa2ZQ=
|
||||
@@ -167,19 +159,18 @@ github.com/gliderlabs/ssh v0.2.2 h1:6zsha5zo/TWhRhwqCD3+EarCAgZ2yN28ipRnGPnwkI0=
|
||||
github.com/gliderlabs/ssh v0.2.2/go.mod h1:U7qILu1NlMHj9FlMhZLlkCdDnU1DBEAqr0aevW3Awn0=
|
||||
github.com/globalsign/mgo v0.0.0-20180905125535-1ca0a4f7cbcb/go.mod h1:xkRDCp4j0OGD1HRkm4kmhM+pmpv3AKq5SU7GMg4oO/Q=
|
||||
github.com/globalsign/mgo v0.0.0-20181015135952-eeefdecb41b8/go.mod h1:xkRDCp4j0OGD1HRkm4kmhM+pmpv3AKq5SU7GMg4oO/Q=
|
||||
github.com/glycerine/go-unsnap-stream v0.0.0-20180323001048-9f0cb55181dd h1:r04MMPyLHj/QwZuMJ5+7tJcBr1AQjpiAK/rZWRrQT7o=
|
||||
github.com/glycerine/go-unsnap-stream v0.0.0-20180323001048-9f0cb55181dd/go.mod h1:/20jfyN9Y5QPEAprSgKAUr+glWDY39ZiUEAYOEv5dsE=
|
||||
github.com/glycerine/goconvey v0.0.0-20190315024820-982ee783a72e h1:SiEs4J3BKVIeaWrH3tKaz3QLZhJ68iJ/A4xrzIoE5+Y=
|
||||
github.com/glycerine/goconvey v0.0.0-20190315024820-982ee783a72e/go.mod h1:Ogl1Tioa0aV7gstGFO7KhffUsb9M4ydbEbbxpcEDc24=
|
||||
github.com/glycerine/go-unsnap-stream v0.0.0-20181221182339-f9677308dec2/go.mod h1:/20jfyN9Y5QPEAprSgKAUr+glWDY39ZiUEAYOEv5dsE=
|
||||
github.com/glycerine/go-unsnap-stream v0.0.0-20190901134440-81cf024a9e0a h1:FQqoVvjbiUioBBFUL5up+h+GdCa/AnJsL/1bIs/veSI=
|
||||
github.com/glycerine/go-unsnap-stream v0.0.0-20190901134440-81cf024a9e0a/go.mod h1:/20jfyN9Y5QPEAprSgKAUr+glWDY39ZiUEAYOEv5dsE=
|
||||
github.com/glycerine/goconvey v0.0.0-20190410193231-58a59202ab31 h1:gclg6gY70GLy3PbkQ1AERPfmLMMagS60DKF78eWwLn8=
|
||||
github.com/glycerine/goconvey v0.0.0-20190410193231-58a59202ab31/go.mod h1:Ogl1Tioa0aV7gstGFO7KhffUsb9M4ydbEbbxpcEDc24=
|
||||
github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
|
||||
github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
|
||||
github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE=
|
||||
github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk=
|
||||
github.com/go-openapi/analysis v0.0.0-20180825180245-b006789cd277/go.mod h1:k70tL6pCuVxPJOHXQ+wIac1FUrvNkHolPie/cLEU6hI=
|
||||
github.com/go-openapi/analysis v0.17.0/go.mod h1:IowGgpVeD0vNm45So8nr+IcQ3pxVtpRoBWb8PVZO0ik=
|
||||
github.com/go-openapi/analysis v0.18.0/go.mod h1:IowGgpVeD0vNm45So8nr+IcQ3pxVtpRoBWb8PVZO0ik=
|
||||
github.com/go-openapi/analysis v0.19.2/go.mod h1:3P1osvZa9jKjb8ed2TPng3f0i/UY9snX6gxi44djMjk=
|
||||
github.com/go-openapi/analysis v0.19.4 h1:1TjOzrWkj+9BrjnM1yPAICbaoC0FyfD49oVkTBrSSa0=
|
||||
github.com/go-openapi/analysis v0.19.4/go.mod h1:3P1osvZa9jKjb8ed2TPng3f0i/UY9snX6gxi44djMjk=
|
||||
github.com/go-openapi/analysis v0.19.5 h1:8b2ZgKfKIUTVQpTb77MoRDIMEIwvDVw40o3aOXdfYzI=
|
||||
github.com/go-openapi/analysis v0.19.5/go.mod h1:hkEAkxagaIvIP7VTn8ygJNkd4kAYON2rCu0v0ObL0AU=
|
||||
@@ -191,39 +182,33 @@ github.com/go-openapi/inflect v0.19.0 h1:9jCH9scKIbHeV9m12SmPilScz6krDxKRasNNSNP
|
||||
github.com/go-openapi/inflect v0.19.0/go.mod h1:lHpZVlpIQqLyKwJ4N+YSc9hchQy/i12fJykb83CRBH4=
|
||||
github.com/go-openapi/jsonpointer v0.17.0/go.mod h1:cOnomiV+CVVwFLk0A/MExoFMjwdsUdVpsRhURCKh+3M=
|
||||
github.com/go-openapi/jsonpointer v0.18.0/go.mod h1:cOnomiV+CVVwFLk0A/MExoFMjwdsUdVpsRhURCKh+3M=
|
||||
github.com/go-openapi/jsonpointer v0.19.2 h1:A9+F4Dc/MCNB5jibxf6rRvOvR/iFgQdyNx9eIhnGqq0=
|
||||
github.com/go-openapi/jsonpointer v0.19.2/go.mod h1:3akKfEdA7DF1sugOqz1dVQHBcuDBPKZGEoHC/NkiQRg=
|
||||
github.com/go-openapi/jsonpointer v0.19.3 h1:gihV7YNZK1iK6Tgwwsxo2rJbD1GTbdm72325Bq8FI3w=
|
||||
github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
|
||||
github.com/go-openapi/jsonreference v0.17.0/go.mod h1:g4xxGn04lDIRh0GJb5QlpE3HfopLOL6uZrK/VgnsK9I=
|
||||
github.com/go-openapi/jsonreference v0.18.0/go.mod h1:g4xxGn04lDIRh0GJb5QlpE3HfopLOL6uZrK/VgnsK9I=
|
||||
github.com/go-openapi/jsonreference v0.19.2 h1:o20suLFB4Ri0tuzpWtyHlh7E7HnkqTNLq6aR6WVNS1w=
|
||||
github.com/go-openapi/jsonreference v0.19.2/go.mod h1:jMjeRr2HHw6nAVajTXJ4eiUwohSTlpa0o73RUL1owJc=
|
||||
github.com/go-openapi/jsonreference v0.19.3 h1:5cxNfTy0UVC3X8JL5ymxzyoUZmo8iZb+jeTWn7tUa8o=
|
||||
github.com/go-openapi/jsonreference v0.19.3/go.mod h1:rjx6GuL8TTa9VaixXglHmQmIL98+wF9xc8zWvFonSJ8=
|
||||
github.com/go-openapi/loads v0.17.0/go.mod h1:72tmFy5wsWx89uEVddd0RjRWPZm92WRLhf7AC+0+OOU=
|
||||
github.com/go-openapi/loads v0.18.0/go.mod h1:72tmFy5wsWx89uEVddd0RjRWPZm92WRLhf7AC+0+OOU=
|
||||
github.com/go-openapi/loads v0.19.0/go.mod h1:72tmFy5wsWx89uEVddd0RjRWPZm92WRLhf7AC+0+OOU=
|
||||
github.com/go-openapi/loads v0.19.2 h1:rf5ArTHmIJxyV5Oiks+Su0mUens1+AjpkPoWr5xFRcI=
|
||||
github.com/go-openapi/loads v0.19.2/go.mod h1:QAskZPMX5V0C2gvfkGZzJlINuP7Hx/4+ix5jWFxsNPs=
|
||||
github.com/go-openapi/loads v0.19.3 h1:jwIoahqCmaA5OBoc/B+1+Mu2L0Gr8xYQnbeyQEo/7b0=
|
||||
github.com/go-openapi/loads v0.19.3/go.mod h1:YVfqhUCdahYwR3f3iiwQLhicVRvLlU/WO5WPaZvcvSI=
|
||||
github.com/go-openapi/runtime v0.0.0-20180920151709-4f900dc2ade9/go.mod h1:6v9a6LTXWQCdL8k1AO3cvqx5OtZY/Y9wKTgaoP6YRfA=
|
||||
github.com/go-openapi/runtime v0.19.0/go.mod h1:OwNfisksmmaZse4+gpV3Ne9AyMOlP1lt4sK4FXt0O64=
|
||||
github.com/go-openapi/runtime v0.19.4 h1:csnOgcgAiuGoM/Po7PEpKDoNulCcF3FGbSnbHfxgjMI=
|
||||
github.com/go-openapi/runtime v0.19.4/go.mod h1:X277bwSUBxVlCYR3r7xgZZGKVvBd/29gLDlFGtJ8NL4=
|
||||
github.com/go-openapi/runtime v0.19.5 h1:h4Zk7oTfB3ZYM2oMNliQvL+3BrDstTIX8lqP7yaYCuI=
|
||||
github.com/go-openapi/runtime v0.19.5/go.mod h1:WIH6IYPXOrtgTClTV8xzdrD20jBlrK25D0aQbdSlqp8=
|
||||
github.com/go-openapi/spec v0.17.0/go.mod h1:XkF/MOi14NmjsfZ8VtAKf8pIlbZzyoTvZsdfssdxcBI=
|
||||
github.com/go-openapi/spec v0.18.0/go.mod h1:XkF/MOi14NmjsfZ8VtAKf8pIlbZzyoTvZsdfssdxcBI=
|
||||
github.com/go-openapi/spec v0.19.2 h1:SStNd1jRcYtfKCN7R0laGNs80WYYvn5CbBjM2sOmCrE=
|
||||
github.com/go-openapi/spec v0.19.2/go.mod h1:sCxk3jxKgioEJikev4fgkNmwS+3kuYdJtcsZsD5zxMY=
|
||||
github.com/go-openapi/spec v0.19.3 h1:0XRyw8kguri6Yw4SxhsQA/atC88yqrk0+G4YhI2wabc=
|
||||
github.com/go-openapi/spec v0.19.3/go.mod h1:FpwSN1ksY1eteniUU7X0N/BgJ7a4WvBFVA8Lj9mJglo=
|
||||
github.com/go-openapi/strfmt v0.17.0/go.mod h1:P82hnJI0CXkErkXi8IKjPbNBM6lV6+5pLP5l494TcyU=
|
||||
github.com/go-openapi/strfmt v0.18.0/go.mod h1:P82hnJI0CXkErkXi8IKjPbNBM6lV6+5pLP5l494TcyU=
|
||||
github.com/go-openapi/strfmt v0.19.0/go.mod h1:+uW+93UVvGGq2qGaZxdDeJqSAqBqBdl+ZPMF/cC8nDY=
|
||||
github.com/go-openapi/strfmt v0.19.2 h1:clPGfBnJohokno0e+d7hs6Yocrzjlgz6EsQSDncCRnE=
|
||||
github.com/go-openapi/strfmt v0.19.2/go.mod h1:0yX7dbo8mKIvc3XSKp7MNfxw4JytCfCD6+bY1AVL9LU=
|
||||
github.com/go-openapi/strfmt v0.19.3 h1:eRfyY5SkaNJCAwmmMcADjY31ow9+N7MCLW7oRkbsINA=
|
||||
github.com/go-openapi/strfmt v0.19.3/go.mod h1:0yX7dbo8mKIvc3XSKp7MNfxw4JytCfCD6+bY1AVL9LU=
|
||||
@@ -233,7 +218,6 @@ github.com/go-openapi/swag v0.19.2/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh
|
||||
github.com/go-openapi/swag v0.19.5 h1:lTz6Ys4CmqqCQmZPBlbQENR1/GucA2bzYTE12Pw4tFY=
|
||||
github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
|
||||
github.com/go-openapi/validate v0.18.0/go.mod h1:Uh4HdOzKt19xGIGm1qHf/ofbX1YQ4Y+MYsct2VUrAJ4=
|
||||
github.com/go-openapi/validate v0.19.2 h1:ky5l57HjyVRrsJfd2+Ro5Z9PjGuKbsmftwyMtk8H7js=
|
||||
github.com/go-openapi/validate v0.19.2/go.mod h1:1tRCw7m3jtI8eNWEEliiAqUIcBztB2KDnRCRMUi7GTA=
|
||||
github.com/go-openapi/validate v0.19.3 h1:PAH/2DylwWcIU1s0Y7k3yNmeAgWOcKrNE2Q7Ww/kCg4=
|
||||
github.com/go-openapi/validate v0.19.3/go.mod h1:90Vh6jjkTn+OT1Eefm0ZixWNFjhtOH7vS9k0lo6zwJo=
|
||||
@@ -243,45 +227,38 @@ github.com/go-sql-driver/mysql v1.4.1 h1:g24URVg0OFbNUTx9qqY1IRZ9D9z3iPyi5zKhQZp
|
||||
github.com/go-sql-driver/mysql v1.4.1/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w=
|
||||
github.com/go-stack/stack v1.8.0 h1:5SgMzNM5HxrEjV0ww2lTmX6E2Izsfxas4+YHWRs3Lsk=
|
||||
github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
|
||||
github.com/go-swagger/go-swagger v0.20.1 h1:37XFujv7lYHLOKawfzLDg4STwwgB5zhPjodN33asJto=
|
||||
github.com/go-swagger/go-swagger v0.20.1/go.mod h1:LoTpv6FHYXUvYnECHNLvi/qYNybk0d9wkJGH1cTANWE=
|
||||
github.com/go-swagger/go-swagger v0.21.0 h1:AX9mdfzp6eJtUe92nFrWmbK7ocRgkCDPJs0FsSSTDlA=
|
||||
github.com/go-swagger/go-swagger v0.21.0/go.mod h1:tDb8PdDVFcaE8EPXkMOsuxpL3UEPiwu1UDZar9Z/1RY=
|
||||
github.com/go-swagger/scan-repo-boundary v0.0.0-20180623220736-973b3573c013 h1:l9rI6sNaZgNC0LnF3MiE+qTmyBA/tZAg1rtyrGbUMK0=
|
||||
github.com/go-swagger/scan-repo-boundary v0.0.0-20180623220736-973b3573c013/go.mod h1:b65mBPzqzZWxOZGxSWrqs4GInLIn+u99Q9q7p+GKni0=
|
||||
github.com/go-xorm/sqlfiddle v0.0.0-20180821085327-62ce714f951a h1:9wScpmSP5A3Bk8V3XHWUcJmYTh+ZnlHVyc+A4oZYS3Y=
|
||||
github.com/go-xorm/sqlfiddle v0.0.0-20180821085327-62ce714f951a/go.mod h1:56xuuqnHyryaerycW3BfssRdxQstACi0Epw/yC5E2xM=
|
||||
github.com/go-xorm/xorm v0.7.9 h1:LZze6n1UvRmM5gpL9/U9Gucwqo6aWlFVlfcHKH10qA0=
|
||||
github.com/go-xorm/xorm v0.7.9/go.mod h1:XiVxrMMIhFkwSkh96BW7PACl7UhLtx2iJIHMdmjh5sQ=
|
||||
github.com/gobwas/glob v0.2.3 h1:A4xDbljILXROh+kObIiy5kIaPYD8e96x1tgBhUI5J+Y=
|
||||
github.com/gobwas/glob v0.2.3/go.mod h1:d3Ez4x06l9bZtSvzIay5+Yzi0fmZzPgnTbPcKjJAkT8=
|
||||
github.com/gofrs/uuid v3.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM=
|
||||
github.com/gogits/chardet v0.0.0-20150115103509-2404f7772561 h1:deE7ritpK04PgtpyVOS2TYcQEld9qLCD5b5EbVNOuLA=
|
||||
github.com/gogits/chardet v0.0.0-20150115103509-2404f7772561/go.mod h1:YgYOrVn3Nj9Tq0EvjmFbphRytDj7JNRoWSStJZWDJTQ=
|
||||
github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ=
|
||||
github.com/gogo/protobuf v1.2.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ=
|
||||
github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4=
|
||||
github.com/gogs/chardet v0.0.0-20191104214054-4b6791f73a28 h1:gBeyun7mySAKWg7Fb0GOcv0upX9bdaZScs8QcRo8mEY=
|
||||
github.com/gogs/chardet v0.0.0-20191104214054-4b6791f73a28/go.mod h1:Pcatq5tYkCW2Q6yrR2VRHlbHpZ/R4/7qyL1TCF7vl14=
|
||||
github.com/gogs/cron v0.0.0-20171120032916-9f6c956d3e14 h1:yXtpJr/LV6PFu4nTLgfjQdcMdzjbqqXMEnHfq0Or6p8=
|
||||
github.com/gogs/cron v0.0.0-20171120032916-9f6c956d3e14/go.mod h1:jPoNZLWDAqA5N3G5amEoiNbhVrmM+ZQEcnQvNQ2KaZk=
|
||||
github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe h1:lXe2qZdvpiX5WZkZR4hgp4KJVfY3nMkvmwbVkpv1rVY=
|
||||
github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe/go.mod h1:8vg3r2VgvsThLBIFL93Qb5yWzgyZWhEmBwUJWevAkK0=
|
||||
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
|
||||
github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
|
||||
github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
|
||||
github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
|
||||
github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
|
||||
github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y=
|
||||
github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/golang/protobuf v1.3.1 h1:YF8+flBXS5eO826T4nzqPrxfhQThhXl0YzfuUPu4SBg=
|
||||
github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/golang/protobuf v1.3.2 h1:6nsPYzhq5kReh6QImI3k5qWzO4PEbvbIW2cwSfR/6xs=
|
||||
github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db h1:woRePGFeVFfLKN/pOkfl+p/TAqKOfFu+7KPlMVpok/w=
|
||||
github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q=
|
||||
github.com/golang/snappy v0.0.1 h1:Qgr9rKW7uDUkrbSmQeiDsGa8SjGyCOGtuasMWwvp2P4=
|
||||
github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q=
|
||||
github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
|
||||
github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
|
||||
github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M=
|
||||
github.com/google/go-cmp v0.3.0 h1:crn/baboCvb5fXaQ0IJ1SGTsTVrWpDsCWC8EGETZijY=
|
||||
github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
|
||||
github.com/google/go-cmp v0.3.1 h1:Xye71clBPdm5HgqGwUkwhbynsUJZhDbS20FvLhQ2izg=
|
||||
github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
|
||||
@@ -295,18 +272,17 @@ github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/
|
||||
github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs=
|
||||
github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
|
||||
github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
|
||||
github.com/google/pprof v0.0.0-20190723021845-34ac40c74b70/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
|
||||
github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI=
|
||||
github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/google/uuid v1.1.1 h1:Gkbcsh/GbpXz7lPftLA3P6TYMwjCLYm83jiFQZF/3gY=
|
||||
github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg=
|
||||
github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk=
|
||||
github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
|
||||
github.com/gopherjs/gopherjs v0.0.0-20181103185306-d547d1d9531e h1:JKmoR8x90Iww1ks85zJ1lfDGgIiMDuIptTOhJq+zKyg=
|
||||
github.com/gopherjs/gopherjs v0.0.0-20181103185306-d547d1d9531e/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
|
||||
github.com/gopherjs/gopherjs v0.0.0-20190430165422-3e4dfb77656c h1:7lF+Vz0LqiRidnzC1Oq86fpX1q/iEv2KJdrCtttYjT4=
|
||||
github.com/gopherjs/gopherjs v0.0.0-20190430165422-3e4dfb77656c/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
|
||||
github.com/gopherjs/gopherjs v0.0.0-20190910122728-9d188e94fb99 h1:twflg0XRTjwKpxb/jFExr4HGq6on2dEOmnL6FV+fgPw=
|
||||
github.com/gopherjs/gopherjs v0.0.0-20190910122728-9d188e94fb99/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
|
||||
github.com/gorilla/context v1.1.1 h1:AWwleXJkX/nhcU9bZSnZoi3h/qGYqQAGhq6zZe/aQW8=
|
||||
github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg=
|
||||
github.com/gorilla/handlers v1.4.2 h1:0QniY0USkHQ1RGCLfKxeNHK9bkDHGRYGNDFBCS+YARg=
|
||||
@@ -317,7 +293,6 @@ github.com/gorilla/pat v0.0.0-20180118222023-199c85a7f6d1 h1:LqbZZ9sNMWVjeXS4NN5
|
||||
github.com/gorilla/pat v0.0.0-20180118222023-199c85a7f6d1/go.mod h1:YeAe0gNeiNT5hoiZRI4yiOky6jVdNvfO2N6Kav/HmxY=
|
||||
github.com/gorilla/securecookie v1.1.1 h1:miw7JPhV+b/lAHSXz4qd/nN9jRiAFV5FwjeKyCS8BvQ=
|
||||
github.com/gorilla/securecookie v1.1.1/go.mod h1:ra0sb63/xPlUeL+yeDciTfxMRAA+MP+HVt/4epWDjd4=
|
||||
github.com/gorilla/sessions v1.1.1 h1:YMDmfaK68mUixINzY/XjscuJ47uXFWSSHzFbBQM0PrE=
|
||||
github.com/gorilla/sessions v1.1.1/go.mod h1:8KCfur6+4Mqcc6S0FEfKuN15Vl5MgXW92AE8ovaJD0w=
|
||||
github.com/gorilla/sessions v1.2.0 h1:S7P+1Hm5V/AT9cjEcUD5uDaQSX0OE577aCXgoaKpYbQ=
|
||||
github.com/gorilla/sessions v1.2.0/go.mod h1:dk2InVEVJ0sfLlnXv9EAgkf6ecYs/i80K/zI+bUmuGM=
|
||||
@@ -325,21 +300,17 @@ github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoA
|
||||
github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs=
|
||||
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk=
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.9.6/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
|
||||
github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
|
||||
github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
|
||||
github.com/hashicorp/golang-lru v0.5.3/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4=
|
||||
github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4=
|
||||
github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
|
||||
github.com/hpcloud/tail v1.0.0 h1:nfCOvKYfkgYP8hkirhJocXT2+zOD8yUNjXaWfTlyFKI=
|
||||
github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU=
|
||||
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
|
||||
github.com/issue9/assert v1.3.2 h1:IaTa37u4m1fUuTH9K9ldO5IONKVDXjLiUO1T9vj0OF0=
|
||||
github.com/issue9/assert v1.3.2/go.mod h1:9Ger+iz8X7r1zMYYwEhh++2wMGWcNN2oVI+zIQXxcio=
|
||||
github.com/issue9/identicon v0.0.0-20160320065130-d36b54562f4c h1:A/PDn117UYld5mlxe58EpMguqpkeTMw5/FCo0ZPS/Ko=
|
||||
github.com/issue9/identicon v0.0.0-20160320065130-d36b54562f4c/go.mod h1:5mTb/PQNkqmq2x3IxlQZE0aSnTksJg7fg/oWmJ5SKXQ=
|
||||
github.com/jackc/fake v0.0.0-20150926172116-812a484cc733 h1:vr3AYkKovP8uR8AvSGGUK1IDqRa5lAAvEkZG1LKaCRc=
|
||||
github.com/jackc/fake v0.0.0-20150926172116-812a484cc733/go.mod h1:WrMFNQdiFJ80sQsxDoMokWK1W5TQtxBFNpzWTD84ibQ=
|
||||
github.com/jackc/pgx v3.6.0+incompatible/go.mod h1:0ZGrqGqkRlliWnWB4zKnWtjbSWbGkVEFm4TeybAXq+I=
|
||||
github.com/jarcoal/httpmock v0.0.0-20180424175123-9c70cfe4a1da/go.mod h1:ks+b9deReOc7jgqp+e7LuFiCBH6Rm5hL32cLcEAArb4=
|
||||
github.com/jaytaylor/html2text v0.0.0-20160923191438-8fb95d837f7d h1:ig/iUfDDg06RVW8OMby+GrmW6K2nPO3AFHlEIdvJSd4=
|
||||
github.com/jaytaylor/html2text v0.0.0-20160923191438-8fb95d837f7d/go.mod h1:CVKlgaMiht+LXvHG173ujK6JUhZXKb2u/BQtjPDIvyk=
|
||||
@@ -366,16 +337,10 @@ github.com/kevinburke/ssh_config v0.0.0-20190725054713-01f96b0aa0cd/go.mod h1:CT
|
||||
github.com/keybase/go-crypto v0.0.0-20170605145657-00ac4db533f6 h1:9mszGwKDxHEY2cy+9XxCQKWIfkGPSAEFrcN8ghzyAKg=
|
||||
github.com/keybase/go-crypto v0.0.0-20170605145657-00ac4db533f6/go.mod h1:ghbZscTyKdM07+Fw3KSi0hcJm+AlEUWj8QLlPtijN/M=
|
||||
github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q=
|
||||
github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00=
|
||||
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
|
||||
github.com/klauspost/compress v0.0.0-20161025140425-8df558b6cb6f h1:tCnZKEmDovgV4jmsclh6CuKk9AMzTzyVWfejgkgccVg=
|
||||
github.com/klauspost/compress v0.0.0-20161025140425-8df558b6cb6f/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A=
|
||||
github.com/klauspost/cpuid v0.0.0-20160302075316-09cded8978dc h1:WW8B7p7QBnFlqRVv/k6ro/S8Z7tCnYjJHcQNScx9YVs=
|
||||
github.com/klauspost/cpuid v0.0.0-20160302075316-09cded8978dc/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek=
|
||||
github.com/klauspost/crc32 v0.0.0-20161016154125-cb6bfca970f6 h1:KAZ1BW2TCmT6PRihDPpocIy1QTtsAsrx6TneU/4+CMg=
|
||||
github.com/klauspost/crc32 v0.0.0-20161016154125-cb6bfca970f6/go.mod h1:+ZoRqAPRLkC4NPOvfYeR5KNOrY6TD+/sAC3HXPZgDYg=
|
||||
github.com/klauspost/compress v1.9.2 h1:LfVyl+ZlLlLDeQ/d2AqfGIIH4qEDu0Ed2S5GyhCWIWY=
|
||||
github.com/klauspost/compress v1.9.2/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A=
|
||||
github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc=
|
||||
github.com/kr/pretty v0.1.0 h1:L/CwN0zerZDmRFUapSPitk6f+Q3+0za1rQkzVuMiMFI=
|
||||
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
|
||||
@@ -384,15 +349,14 @@ github.com/kr/pty v1.1.5/go.mod h1:9r2w37qlBe7rQ6e1fg1S/9xpWHSnaqNdHD3WcMdbPDA=
|
||||
github.com/kr/pty v1.1.8/go.mod h1:O1sed60cT9XZ5uDucP5qwvh+TE3NnUj51EiZO/lmSfw=
|
||||
github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE=
|
||||
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
|
||||
github.com/lafriks/xormstore v1.3.1 h1:KpzRUamSV3zmA85Kzw+PZOU9wgMbYsNzuDzLuBMbxpA=
|
||||
github.com/lafriks/xormstore v1.3.1/go.mod h1:qALRD4Vto2Ic7/A5eplMpu5V62mugtSqFysRwz8FETs=
|
||||
github.com/lafriks/xormstore v1.3.2 h1:hqi3F8s/B4rz8GuEZZDuHuOxRjeuOpEI/cC7vcnWwH4=
|
||||
github.com/lafriks/xormstore v1.3.2/go.mod h1:mVNIwIa25QIr8rfR7YlVjrqN/apswHkVdtLCyVYBzXw=
|
||||
github.com/lestrrat-go/jwx v0.9.0/go.mod h1:iEoxlYfZjvoGpuWwxUz+eR5e6KTJGsaRcy/YNA/UnBk=
|
||||
github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
|
||||
github.com/lib/pq v1.2.0 h1:LXpIM/LZ5xGFhOpXAQUIMM1HdyqzVYM13zNdjCEEcA0=
|
||||
github.com/lib/pq v1.2.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
|
||||
github.com/lunny/dingtalk_webhook v0.0.0-20171025031554-e3534c89ef96 h1:uNwtsDp7ci48vBTTxDuwcoTXz4lwtDTe7TjCQ0noaWY=
|
||||
github.com/lunny/dingtalk_webhook v0.0.0-20171025031554-e3534c89ef96/go.mod h1:mmIfjCSQlGYXmJ95jFN84AkQFnVABtKuJL8IrzwvUKQ=
|
||||
github.com/lunny/levelqueue v0.0.0-20190217115915-02b525a4418e h1:GSprKUrG9wNgwQgROvjPGXmcZrg4OLslOuZGB0uJjx8=
|
||||
github.com/lunny/levelqueue v0.0.0-20190217115915-02b525a4418e/go.mod h1:rQZVENnBOiVakCs97XvclbwJRTAv77CRFWcYVNDkVf8=
|
||||
github.com/lunny/log v0.0.0-20160921050905-7887c61bf0de h1:nyxwRdWHAVxpFcDThedEgQ07DbcRc5xgNObtbTp76fk=
|
||||
github.com/lunny/log v0.0.0-20160921050905-7887c61bf0de/go.mod h1:3q8WtuPQsoRbatJuy3nvq/hRSvuBJrHHr+ybPPiNvHQ=
|
||||
github.com/lunny/nodb v0.0.0-20160621015157-fc1ef06ad4af h1:UaWHNBdukWrSG3DRvHFR/hyfg681fceqQDYVTBncKfQ=
|
||||
@@ -403,13 +367,12 @@ github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czP
|
||||
github.com/mailru/easyjson v0.0.0-20180823135443-60711f1a8329/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
|
||||
github.com/mailru/easyjson v0.0.0-20190312143242-1de009706dbe/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
|
||||
github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
|
||||
github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e h1:hB2xlXdHp/pmPZq0y3QnmWAArdw9PqbmotexnWx/FU8=
|
||||
github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
|
||||
github.com/mailru/easyjson v0.7.0 h1:aizVhC/NAAcKWb+5QsU1iNOZb4Yws5UO2I+aIprQITM=
|
||||
github.com/mailru/easyjson v0.7.0/go.mod h1:KAzv3t3aY1NaHWoQz1+4F1ccyAH66Jk7yos7ldAVICs=
|
||||
github.com/markbates/going v1.0.0/go.mod h1:I6mnB4BPnEeqo85ynXIx1ZFLLbtiLHNXVgWeFO9OGOA=
|
||||
github.com/markbates/goth v1.56.0 h1:XEYedCgMNz5pi3ojXI8z2XUmXtBnMeuKUpx4Z6HlNj8=
|
||||
github.com/markbates/goth v1.56.0/go.mod h1:zZmAw0Es0Dpm7TT/4AdN14QrkiWLMrrU9Xei1o+/mdA=
|
||||
github.com/markbates/goth v1.61.2 h1:jDowrUH5qw8KGuQdKwFhLzkXkTYCIPfz3LHADJsiPIs=
|
||||
github.com/markbates/goth v1.61.2/go.mod h1:qh2QfwZoWRucQ+DR5KVKC6dUGkNCToWh4vS45GIzFsY=
|
||||
github.com/mattn/go-isatty v0.0.7 h1:UvyT9uN+3r7yLEYSlJsbQGdsaB/a0DlgWP3pql6iwOc=
|
||||
github.com/mattn/go-isatty v0.0.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
|
||||
github.com/mattn/go-oci8 v0.0.0-20190320171441-14ba190cf52d h1:m+dSK37rFf2fqppZhg15yI2IwC9BtucBiRwSDm9VL8g=
|
||||
@@ -438,18 +401,17 @@ github.com/mschoch/smat v0.0.0-20160514031455-90eadee771ae/go.mod h1:qAyveg+e4CE
|
||||
github.com/msteinert/pam v0.0.0-20151204160544-02ccfbfaf0cc h1:z1PgdCCmYYVL0BoJTUgmAq1p7ca8fzYIPsNyfsN3xAU=
|
||||
github.com/msteinert/pam v0.0.0-20151204160544-02ccfbfaf0cc/go.mod h1:np1wUFZ6tyoke22qDJZY40URn9Ae51gX7ljIWXN5TJs=
|
||||
github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U=
|
||||
github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U=
|
||||
github.com/nfnt/resize v0.0.0-20160724205520-891127d8d1b5 h1:BvoENQQU+fZ9uukda/RzCAL/191HHwJA5b13R6diVlY=
|
||||
github.com/nfnt/resize v0.0.0-20160724205520-891127d8d1b5/go.mod h1:jpp1/29i3P1S/RLdc7JQKbRpFeM1dOBd8T9ki5s+AY8=
|
||||
github.com/niklasfasching/go-org v0.1.8 h1:Kjvs6lP+LIILHhc9zIJ4Gu90a/pVY483if2Qmu8v4Fg=
|
||||
github.com/niklasfasching/go-org v0.1.8/go.mod h1:AsLD6X7djzRIz4/RFZu8vwRL0VGjUvGZCCH1Nz0VdrU=
|
||||
github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U=
|
||||
github.com/oliamb/cutter v0.2.2 h1:Lfwkya0HHNU1YLnGv2hTkzHfasrSMkgv4Dn+5rmlk3k=
|
||||
github.com/oliamb/cutter v0.2.2/go.mod h1:4BenG2/4GuRBDbVm/OPahDVqbrOemzpPiG5mi1iryBU=
|
||||
github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/ginkgo v1.7.0 h1:WSHQ+IS43OoUrWtD1/bbclrwK8TTH5hzp+umCiuxHgs=
|
||||
github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/ginkgo v1.8.0 h1:VkHVNpR4iVnU8XQR6DBm8BqYjN7CRzw+xKUbVVbbW9w=
|
||||
github.com/onsi/ginkgo v1.8.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/gomega v1.4.3 h1:RE1xgDvH7imwFD45h+u2SgIfERHlS2yNG4DObb5BSKU=
|
||||
github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
|
||||
github.com/onsi/gomega v1.5.0 h1:izbySO9zDPmjJ8rDjLvkA2zJHIo+HkYXHnf7eN7SSyo=
|
||||
github.com/onsi/gomega v1.5.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
|
||||
@@ -478,7 +440,6 @@ github.com/prometheus/client_golang v1.1.0 h1:BQ53HtBmfOitExawJ6LokA4x8ov/z0SYYb
|
||||
github.com/prometheus/client_golang v1.1.0/go.mod h1:I1FGZT9+L76gKKOs5djB6ezCbFQP1xR9D75/vuwEF3g=
|
||||
github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo=
|
||||
github.com/prometheus/client_model v0.0.0-20190115171406-56726106282f/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo=
|
||||
github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90 h1:S/YWwWx/RA8rT8tKFRuGUZhuA90OyIBpPCXkcbwU8DE=
|
||||
github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
|
||||
github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4 h1:gQz4mCbXsO+nc9n1hCxHcGA3Zx3Eo+UHZoInFGUIXNM=
|
||||
github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
|
||||
@@ -496,27 +457,20 @@ github.com/prometheus/procfs v0.0.3/go.mod h1:4A/X28fw3Fc593LaREMrKMqOKvUAntwMDa
|
||||
github.com/prometheus/procfs v0.0.4 h1:w8DjqFMJDjuVwdZBQoOozr4MVWOnwF7RcL/7uxBjY78=
|
||||
github.com/prometheus/procfs v0.0.4/go.mod h1:4A/X28fw3Fc593LaREMrKMqOKvUAntwMDaekg4FpcdQ=
|
||||
github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU=
|
||||
github.com/prometheus/tsdb v0.10.0/go.mod h1:oi49uRhEe9dPUTlS3JRZOwJuVi6tmh10QSgwXEyGCt4=
|
||||
github.com/quasoft/websspi v1.0.0 h1:5nDgdM5xSur9s+B5w2xQ5kxf5nUGqgFgU4W0aDLZ8Mw=
|
||||
github.com/quasoft/websspi v1.0.0/go.mod h1:HmVdl939dQ0WIXZhyik+ARdI03M6bQzaSEKcgpFmewk=
|
||||
github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4=
|
||||
github.com/remyoudompheng/bigfft v0.0.0-20190321074620-2f0d2b0e0001 h1:YDeskXpkNDhPdWN3REluVa46HQOVuVkjkd2sWnrABNQ=
|
||||
github.com/remyoudompheng/bigfft v0.0.0-20190321074620-2f0d2b0e0001/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo=
|
||||
github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg=
|
||||
github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ=
|
||||
github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
|
||||
github.com/russross/blackfriday v0.0.0-20180428102519-11635eb403ff h1:g9ZlAHmkc/h5So+OjNCkZWh+FjuKEOOOoyRkqlGA8+c=
|
||||
github.com/russross/blackfriday v0.0.0-20180428102519-11635eb403ff/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g=
|
||||
github.com/saintfish/chardet v0.0.0-20120816061221-3af4cd4741ca h1:NugYot0LIVPxTvN8n+Kvkn6TrbMyxQiuvKdEwFdR9vI=
|
||||
github.com/saintfish/chardet v0.0.0-20120816061221-3af4cd4741ca/go.mod h1:uugorj2VCxiV1x+LzaIdVa9b4S4qGAcH6cbhh4qVxOU=
|
||||
github.com/russross/blackfriday v1.5.2 h1:HyvC0ARfnZBqnXwABFeSZHpKvJHJJfPz81GNueLj0oo=
|
||||
github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g=
|
||||
github.com/satori/go.uuid v1.2.0 h1:0uYX9dsZ2yD7q2RtLRtPSdGDWzjeM3TbMJP9utgA0ww=
|
||||
github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0=
|
||||
github.com/sergi/go-diff v1.0.0 h1:Kpca3qRNrduNnOQeazBd0ysaKrUJiIuISHxogkT9RPQ=
|
||||
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=
|
||||
github.com/shopspring/decimal v0.0.0-20180709203117-cd690d0c9e24 h1:pntxY8Ary0t43dCZ5dqY4YTJCObLY1kIXl0uzMv+7DE=
|
||||
github.com/shopspring/decimal v0.0.0-20180709203117-cd690d0c9e24/go.mod h1:M+9NzErvs504Cn4c5DxATwIqPbtswREoFCre64PpcG4=
|
||||
github.com/shurcooL/httpfs v0.0.0-20190527155220-6a4d4a70508b h1:4kg1wyftSKxLtnPAvcRWakIPpokB9w780/KwrNLnfPA=
|
||||
github.com/shurcooL/httpfs v0.0.0-20190527155220-6a4d4a70508b/go.mod h1:ZY1cvUeJuFPAdZ/B6v7RHavJWZn2YPVFQ1OSXhCGOkg=
|
||||
github.com/shurcooL/sanitized_anchor_name v0.0.0-20160918041101-1dba4b3954bc h1:3wIrJvFb3Pf6B/2mDBnN1G5IfUVev4X5apadQlWOczE=
|
||||
github.com/shurcooL/sanitized_anchor_name v0.0.0-20160918041101-1dba4b3954bc/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
|
||||
github.com/shurcooL/vfsgen v0.0.0-20181202132449-6a9ea43bcacd h1:ug7PpSOB5RBPK1Kg6qskGBoP3Vnj/aNYFTznWvlkGo0=
|
||||
github.com/shurcooL/vfsgen v0.0.0-20181202132449-6a9ea43bcacd/go.mod h1:TrYk7fJVaAttu97ZZKrO9UbRa8izdowaMIZcxYMbVaw=
|
||||
github.com/siddontang/go v0.0.0-20180604090527-bdc77568d726/go.mod h1:3yhqj7WBBfRhbBlzyOC3gUxftwsU0u8gqevxwIHQpMw=
|
||||
@@ -525,28 +479,28 @@ github.com/siddontang/go-snappy v0.0.0-20140704025258-d8f7bb82a96d/go.mod h1:vq0
|
||||
github.com/siddontang/ledisdb v0.0.0-20190202134119-8ceb77e66a92/go.mod h1:mF1DpOSOUiJRMR+FDqaqu3EBqrybQtrDDszLUZ6oxPg=
|
||||
github.com/siddontang/rdb v0.0.0-20150307021120-fc89ed2e418d/go.mod h1:AMEsy7v5z92TR1JKMkLLoaOQk++LVnOKL3ScbJ8GNGA=
|
||||
github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
|
||||
github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE=
|
||||
github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc=
|
||||
github.com/smartystreets/assertions v0.0.0-20190116191733-b6c0e53d7304 h1:Jpy1PXuP99tXNrhbq2BaPz9B+jNAvH1JPQQpG/9GCXY=
|
||||
github.com/smartystreets/assertions v0.0.0-20190116191733-b6c0e53d7304/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc=
|
||||
github.com/smartystreets/assertions v1.0.1 h1:voD4ITNjPL5jjBfgR/r8fPIIBrliWrWHeiJApdr3r4w=
|
||||
github.com/smartystreets/assertions v1.0.1/go.mod h1:kHHU4qYBaI3q23Pp3VPrmWhuIUrLW/7eUrw0BU5VaoM=
|
||||
github.com/smartystreets/goconvey v0.0.0-20181108003508-044398e4856c/go.mod h1:XDJAKZRPZ1CvBcN2aX5YOUTYGHki24fSF0Iv48Ibg0s=
|
||||
github.com/smartystreets/goconvey v0.0.0-20190330032615-68dc04aab96a/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA=
|
||||
github.com/smartystreets/goconvey v0.0.0-20190731233626-505e41936337 h1:WN9BUFbdyOsSH/XohnWpXOlq9NBD5sGAB2FciQMUEe8=
|
||||
github.com/smartystreets/goconvey v0.0.0-20190731233626-505e41936337/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA=
|
||||
github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM=
|
||||
github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA=
|
||||
github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA=
|
||||
github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
|
||||
github.com/spf13/afero v1.2.2 h1:5jhuqJyZCZf2JRofRvN/nIFgIWNzPa3/Vz8mYylgbWc=
|
||||
github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk=
|
||||
github.com/spf13/cast v1.3.0 h1:oget//CVOEoFewqQxwr0Ej5yjygnqGkvggSE/gB35Q8=
|
||||
github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
|
||||
github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU=
|
||||
github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
|
||||
github.com/spf13/jwalterweatherman v1.1.0 h1:ue6voC5bR5F8YxI5S67j9i582FU4Qvo2bmqnqMYADFk=
|
||||
github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo=
|
||||
github.com/spf13/pflag v1.0.3 h1:zPAT6CGy6wXeQ7NtTnaTerfKOsV6V6F8agHXFiazDkg=
|
||||
github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
|
||||
github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s=
|
||||
github.com/spf13/viper v1.4.0 h1:yXHLWeravcrgGyFSyCgdYpXQ9dR9c/WED3pg1RhxqEU=
|
||||
github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE=
|
||||
github.com/src-d/gcfg v1.4.0 h1:xXbNR5AlLSA315x2UO+fTSSAXCDf+Ar38/6oyGbDKQ4=
|
||||
@@ -555,13 +509,12 @@ github.com/steveyen/gtreap v0.0.0-20150807155958-0abe01ef9be2 h1:JNEGSiWg6D3lcBC
|
||||
github.com/steveyen/gtreap v0.0.0-20150807155958-0abe01ef9be2/go.mod h1:mjqs7N0Q6m5HpR7QfXVBZXZWSqTjQLeTujjA/xUp2uw=
|
||||
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/objx v0.2.0 h1:Hbg2NidpLE8veEBkEZTL3CvlkUIVzuU9jDplZO54c48=
|
||||
github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE=
|
||||
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
|
||||
github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q=
|
||||
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
|
||||
github.com/stretchr/testify v1.4.0 h1:2E4SXV/wtOkTonXsotYi4li6zVWxYlZuYNCXe9XRJyk=
|
||||
github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
|
||||
github.com/syndtr/goleveldb v0.0.0-20190203031304-2f17a3356c66 h1:AwmkkZT+TucFotNCL+aNJ/0KCMsRtlXN9fs8uoOMSRk=
|
||||
github.com/syndtr/goleveldb v0.0.0-20190203031304-2f17a3356c66/go.mod h1:ZVVdQEZoIme9iO1Ch2Jdy24qqXrMMOU6lpPAyBWyWuQ=
|
||||
github.com/syndtr/goleveldb v1.0.0 h1:fBdIW9lB4Iz0n9khmH8w27SJ3QEJ7+IgjPEwGSZiFdE=
|
||||
github.com/syndtr/goleveldb v1.0.0/go.mod h1:ZVVdQEZoIme9iO1Ch2Jdy24qqXrMMOU6lpPAyBWyWuQ=
|
||||
@@ -569,42 +522,43 @@ github.com/tecbot/gorocksdb v0.0.0-20181010114359-8752a9433481 h1:HOxvxvnntLiPn1
|
||||
github.com/tecbot/gorocksdb v0.0.0-20181010114359-8752a9433481/go.mod h1:ahpPrc7HpcfEWDQRZEmnXMzHY03mLDYMCxeDzy46i+8=
|
||||
github.com/tidwall/pretty v1.0.0 h1:HsD+QiTn7sK6flMKIvNmpqz1qrpP3Ps6jOKIKMooyg4=
|
||||
github.com/tidwall/pretty v1.0.0/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk=
|
||||
github.com/tinylib/msgp v0.0.0-20180516164116-c8cf64dff200 h1:ZVvr38DYEyOPyelySqvF0I9I++85NnUMsWkroBDS4fs=
|
||||
github.com/tinylib/msgp v0.0.0-20180516164116-c8cf64dff200/go.mod h1:+d+yLhGm8mzTaHzB+wgMYrodPfmZrzkirds8fDWklFE=
|
||||
github.com/tinylib/msgp v1.1.0 h1:9fQd+ICuRIu/ue4vxJZu6/LzxN0HwMds2nq/0cFvxHU=
|
||||
github.com/tinylib/msgp v1.1.0/go.mod h1:+d+yLhGm8mzTaHzB+wgMYrodPfmZrzkirds8fDWklFE=
|
||||
github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
|
||||
github.com/toqueteos/webbrowser v1.2.0 h1:tVP/gpK69Fx+qMJKsLE7TD8LuGWPnEV71wBN9rrstGQ=
|
||||
github.com/toqueteos/webbrowser v1.2.0/go.mod h1:XWoZq4cyp9WeUeak7w7LXRUQf1F1ATJMir8RTqb4ayM=
|
||||
github.com/tstranex/u2f v1.0.0 h1:HhJkSzDDlVSVIVt7pDJwCHQj67k7A5EeBgPmeD+pVsQ=
|
||||
github.com/tstranex/u2f v1.0.0/go.mod h1:eahSLaqAS0zsIEv80+vXT7WanXs7MQQDg3j3wGBSayo=
|
||||
github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc=
|
||||
github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw=
|
||||
github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY=
|
||||
github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0=
|
||||
github.com/unknwon/cae v0.0.0-20190822084630-55a0b64484a1 h1:SpoCl3+Pta5/ubQyF+Fmx65obtpfkyzeaOIneCE3MTw=
|
||||
github.com/unknwon/cae v0.0.0-20190822084630-55a0b64484a1/go.mod h1:QaSeRctcea9fK6piJpAMCCPKxzJ01+xFcr2k1m3WRPU=
|
||||
github.com/unknwon/com v0.0.0-20190804042917-757f69c95f3e h1:GSGeB9EAKY2spCABz6xOX5DbxZEXolK+nBSvmsQwRjM=
|
||||
github.com/unknwon/com v0.0.0-20190804042917-757f69c95f3e/go.mod h1:tOOxU81rwgoCLoOVVPHb6T/wt8HZygqH5id+GNnlCXM=
|
||||
github.com/unknwon/com v1.0.1 h1:3d1LTxD+Lnf3soQiD4Cp/0BRB+Rsa/+RTvz8GMMzIXs=
|
||||
github.com/unknwon/com v1.0.1/go.mod h1:tOOxU81rwgoCLoOVVPHb6T/wt8HZygqH5id+GNnlCXM=
|
||||
github.com/unknwon/i18n v0.0.0-20190805065654-5c6446a380b6 h1:sRrkJEHtNoaSvyXMbRgofEOX4/3gMiraevQKJdIBhYE=
|
||||
github.com/unknwon/i18n v0.0.0-20190805065654-5c6446a380b6/go.mod h1:+5rDk6sDGpl3azws3O+f+GpFSyN9GVr0K8cvQLQM2ZQ=
|
||||
github.com/unknwon/paginater v0.0.0-20151104151617-7748a72e0141 h1:Z79lyIznnziKADUf0J7EP8Z4ZL7YJDiPuaazlfUBSy4=
|
||||
github.com/unknwon/paginater v0.0.0-20151104151617-7748a72e0141/go.mod h1:TBwoao3Q4Eb/cp+dHbXDfRTrZSsj/k7kLr2j1oWRWC0=
|
||||
github.com/urfave/cli v1.20.0 h1:fDqGv3UG/4jbVl/QkFwEdddtEDjh/5Ov6X+0B/3bPaw=
|
||||
github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
|
||||
github.com/willf/bitset v0.0.0-20180426185212-8ce1146b8621 h1:E8u341JM/N8LCnPXBV6ZFD1RKo/j+qHl1XOqSV+GstA=
|
||||
github.com/willf/bitset v0.0.0-20180426185212-8ce1146b8621/go.mod h1:RjeCKbqT1RxIR/KWY6phxZiaY1IyutSBfGjNPySAYV4=
|
||||
github.com/willf/bitset v1.1.10 h1:NotGKqX0KwQ72NUzqrjZq5ipPNDQex9lo3WpaS8L2sc=
|
||||
github.com/willf/bitset v1.1.10/go.mod h1:RjeCKbqT1RxIR/KWY6phxZiaY1IyutSBfGjNPySAYV4=
|
||||
github.com/xanzy/ssh-agent v0.2.1 h1:TCbipTQL2JiiCprBWx9frJ2eJlCYT00NmctrHxVAr70=
|
||||
github.com/xanzy/ssh-agent v0.2.1/go.mod h1:mLlQY/MoOhWBj+gOGMQkOeiEvkx+8pJSI+0Bx9h2kr4=
|
||||
github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU=
|
||||
github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q=
|
||||
github.com/yohcop/openid-go v0.0.0-20160914080427-2c050d2dae53 h1:HsIQ6yAjfjQ3IxPGrTusxp6Qxn92gNVq2x5CbvQvx3w=
|
||||
github.com/yohcop/openid-go v0.0.0-20160914080427-2c050d2dae53/go.mod h1:f6elajwZV+xceiaqgRL090YzLEDGSbqr3poGL3ZgXYo=
|
||||
github.com/yuin/goldmark v1.1.19 h1:0s2/60x0XsFCXHeFut+F3azDVAAyIMyUfJRbRexiTYs=
|
||||
github.com/yuin/goldmark v1.1.19/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||
github.com/ziutek/mymysql v1.5.4 h1:GB0qdRGsTwQSBVYuVShFBKaXSnSnYYC2d9knnE1LHFs=
|
||||
github.com/ziutek/mymysql v1.5.4/go.mod h1:LMSpPZ6DbqWFxNCHW77HeMg9I646SAhApZ/wKdgO/C0=
|
||||
go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
|
||||
go.etcd.io/bbolt v1.3.3 h1:MUGmc65QhB3pIlaQ5bB4LwqSj6GIonVJXpZiaKNyaKk=
|
||||
go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
|
||||
go.mongodb.org/mongo-driver v1.0.3/go.mod h1:u7ryQJ+DOzQmeO7zB6MHyr8jkEQvC8vH7qLUO4lqsUM=
|
||||
go.mongodb.org/mongo-driver v1.1.0 h1:aeOqSrhl9eDRAap/3T5pCfMBEBxZ0vuXBP+RMtp2KX8=
|
||||
go.mongodb.org/mongo-driver v1.1.0/go.mod h1:u7ryQJ+DOzQmeO7zB6MHyr8jkEQvC8vH7qLUO4lqsUM=
|
||||
go.mongodb.org/mongo-driver v1.1.1 h1:Sq1fR+0c58RME5EoqKdjkiQAmPjmfHlZOoRI6fTUOcs=
|
||||
go.mongodb.org/mongo-driver v1.1.1/go.mod h1:u7ryQJ+DOzQmeO7zB6MHyr8jkEQvC8vH7qLUO4lqsUM=
|
||||
go.opencensus.io v0.20.1/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk=
|
||||
@@ -615,32 +569,31 @@ go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/
|
||||
go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q=
|
||||
golang.org/x/crypto v0.0.0-20180820150726-614d502a4dac/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20190219172222-a4c6cb3142f2/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20190320223903-b7391e95e576/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20190325154230-a5d413f7728c/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20190617133340-57b3e21c3d56/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4 h1:HuIa8hRrWRSrqYzx1qI49NNxhdi2PrY7gxVSq1JjLDc=
|
||||
golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20190907121410-71b5226ff739/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20190927123631-a832865fa7ad h1:5E5raQxcv+6CZ11RrBYQe5WRbUIWpScjh0kvHZkZIrQ=
|
||||
golang.org/x/crypto v0.0.0-20190927123631-a832865fa7ad/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20200219234226-1ad67e1f0ef4 h1:4icQlpeqbz3WxfgP6Eq3szTj95KTrlH/CwzBzoxuFd0=
|
||||
golang.org/x/crypto v0.0.0-20200219234226-1ad67e1f0ef4/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
|
||||
golang.org/x/exp v0.0.0-20190731235908-ec7cb31e5a56/go.mod h1:JhuoJpWY28nO4Vef9tZUw9qufEGTyX1+7lmHxV5q5G4=
|
||||
golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
|
||||
golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
|
||||
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
|
||||
golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
|
||||
golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
|
||||
golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
|
||||
golang.org/x/lint v0.0.0-20190409202823-959b441ac422/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
|
||||
golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE=
|
||||
golang.org/x/mobile v0.0.0-20190814143026-e8b3e6111d02/go.mod h1:z5wpDCy2wbnXyFdvEuY3LhY9gBUL86/IOILm+Hsjx+E=
|
||||
golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc=
|
||||
golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY=
|
||||
golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
|
||||
golang.org/x/net v0.0.0-20180218175443-cbe0f9307d01/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
@@ -660,16 +613,12 @@ golang.org/x/net v0.0.0-20190522155817-f3200d17e092/go.mod h1:HSz+uSET+XFnRR8LxR
|
||||
golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks=
|
||||
golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20190724013045-ca1201d0de80 h1:Ao/3l156eZf2AW5wK8a7/smtodRU+gha3+BeqJ69lRk=
|
||||
golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297 h1:k7pJ2yAPLPgbskkFdhRCsA77k2fySZ1zf2zCjvQCiIM=
|
||||
golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20190909003024-a7b16738d86b h1:XfVGCX+0T4WOStkaOsJRllbsiImhB2jgVBGc9L0lPGc=
|
||||
golang.org/x/net v0.0.0-20190909003024-a7b16738d86b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20191101175033-0deb6923b6d9 h1:DPz9iiH3YoKiKhX/ijjoZvT0VFwK2c6CWYWQ7Zyr8TU=
|
||||
golang.org/x/net v0.0.0-20191101175033-0deb6923b6d9/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/oauth2 v0.0.0-20180620175406-ef147856a6dd/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
|
||||
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
|
||||
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421 h1:Wo7BWFiOk0QRFMLYMqJGFMd9CgUAcGx7V+qEg/h5IBI=
|
||||
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
|
||||
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45 h1:SVwTIAaPC2U/AvvLNZ2a7OVsmBpC8L5BlwK1whH3hm0=
|
||||
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
|
||||
@@ -685,13 +634,13 @@ golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5h
|
||||
golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181122145206-62eef0e2fa9b/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190221075227-b4e8571b14e0/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190321052220-f7bb7a8bee54/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
@@ -699,11 +648,13 @@ golang.org/x/sys v0.0.0-20190616124812-15dcb6c0061f/go.mod h1:h1NjWce9XRLGQEsW7w
|
||||
golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190730183949-1393eb018365/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190801041406-cbf593c0f2f3 h1:4y9KwBHBgBNwDbtu44R5o1fdOCQUEXhbk/P4A9WmJq0=
|
||||
golang.org/x/sys v0.0.0-20190801041406-cbf593c0f2f3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190910064555-bbd175535a8b h1:3S2h5FadpNr0zUUCVZjlKIEYF+KaX/OBplTGo89CYHI=
|
||||
golang.org/x/sys v0.0.0-20190910064555-bbd175535a8b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190907184412-d223b2b6db03/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191010194322-b09406accb47 h1:/XfQ9z7ib8eEJX2hdgFTZJ/ntt0swNk5oYBziWeTCvY=
|
||||
golang.org/x/sys v0.0.0-20191010194322-b09406accb47/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20200219091948-cb0a6d8edb6c h1:jceGD5YNJGgGMkJz79agzOln1K9TaZUjv5ird16qniQ=
|
||||
golang.org/x/sys v0.0.0-20200219091948-cb0a6d8edb6c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.2 h1:tW2bmiBqwgJj/UpqtC8EpXEZVYOwU0yG4iWbprSVAcs=
|
||||
@@ -713,7 +664,6 @@ golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxb
|
||||
golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY=
|
||||
golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
|
||||
@@ -722,18 +672,16 @@ golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3
|
||||
golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
|
||||
golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
||||
golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
||||
golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
||||
golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||
golang.org/x/tools v0.0.0-20190614205625-5aca471b1d59/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||
golang.org/x/tools v0.0.0-20190617190820-da514acc4774/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||
golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||
golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||
golang.org/x/tools v0.0.0-20190729092621-ff9f1409240a/go.mod h1:jcCCGcm9btYwXyDqrUWc6MKQKKGJCWEQ3AfLSRIbEuI=
|
||||
golang.org/x/tools v0.0.0-20190808195139-e713427fea3f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20190820033707-85edb9ef3283/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20190910221609-7f5965fd7709 h1:2Ep+/X9v6ij0U1YP++QCLyZgWQHUwVJZkC6tSrH1Iuw=
|
||||
golang.org/x/tools v0.0.0-20190910221609-7f5965fd7709/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20190907020128-2ca718005c18/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20191213221258-04c2e8eff935 h1:kJQZhwFzSwJS2BxboKjdZzWczQOZx8VuH7Y8hhuGUtM=
|
||||
golang.org/x/tools v0.0.0-20191213221258-04c2e8eff935/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
|
||||
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
google.golang.org/api v0.3.1/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk=
|
||||
google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE=
|
||||
google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M=
|
||||
@@ -743,10 +691,9 @@ google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9Ywl
|
||||
google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
google.golang.org/appengine v1.6.0 h1:Tfd7cKwKbFRsI8RMAD3oqqw7JPFRrvFlOsfbgVkjOOw=
|
||||
google.golang.org/appengine v1.6.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
google.golang.org/appengine v1.6.1 h1:QzqyMA1tlu6CgqCDUtU9V+ZKhLFT2dkJuANu5QaxI3I=
|
||||
google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0=
|
||||
google.golang.org/appengine v1.6.2/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0=
|
||||
google.golang.org/appengine v1.6.4 h1:WiKh4+/eMB2HaY7QhCfW/R7MuRAoA8QMCSJA6jP5/fo=
|
||||
google.golang.org/appengine v1.6.4/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0=
|
||||
google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc=
|
||||
@@ -762,28 +709,25 @@ google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZi
|
||||
google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
|
||||
google.golang.org/grpc v1.21.0/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
|
||||
google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
|
||||
google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg=
|
||||
gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw=
|
||||
gopkg.in/alexcesaro/quotedprintable.v3 v3.0.0-20150716171945-2caba252f4dc h1:2gGKlE2+asNV9m7xrywl36YYNnBG5ZQ0r/BOOxqPpmk=
|
||||
gopkg.in/alexcesaro/quotedprintable.v3 v3.0.0-20150716171945-2caba252f4dc/go.mod h1:m7x9LTH6d71AHyAX77c9yqWCCa3UKHcVEj9y7hAtKDk=
|
||||
gopkg.in/asn1-ber.v1 v1.0.0-20150924051756-4e86f4367175 h1:nn6Zav2sOQHCFJHEspya8KqxhFwKci30UxHy3HXPTyQ=
|
||||
gopkg.in/asn1-ber.v1 v1.0.0-20150924051756-4e86f4367175/go.mod h1:cuepJuh7vyXfUyUwEgHQXw849cJrilpS5NeIjOWESAw=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 h1:qIbj1fsPNlZgppZ+VLlY7N33q108Sa+fhmuc+sWQYwY=
|
||||
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo=
|
||||
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/editorconfig/editorconfig-core-go.v1 v1.3.0 h1:oxOEwvhxLMpWpN+0pb2r9TWrM0DCFBHxbuIlS27tmFg=
|
||||
gopkg.in/editorconfig/editorconfig-core-go.v1 v1.3.0/go.mod h1:s2mQFI9McjArkyCwyEwU//+luQENTnD/Lfb/7Sj3/kQ=
|
||||
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
|
||||
gopkg.in/fsnotify.v1 v1.4.7 h1:xOHLXZwVvI9hhs+cLKq5+I5onOuwQLhQwiu63xxlHs4=
|
||||
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
|
||||
gopkg.in/gomail.v2 v2.0.0-20160411212932-81ebce5c23df h1:n7WqCuqOuCbNr617RXOY0AWRXxgwEyPp2z+p0+hgMuE=
|
||||
gopkg.in/gomail.v2 v2.0.0-20160411212932-81ebce5c23df/go.mod h1:LRQQ+SO6ZHR7tOkpBDuZnXENFzX8qRjMDMyPD6BRkCw=
|
||||
gopkg.in/ini.v1 v1.42.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
|
||||
gopkg.in/ini.v1 v1.44.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
|
||||
gopkg.in/ini.v1 v1.44.2/go.mod h1:M3Cogqpuv0QCi3ExAY5V4uOt4qb/R3xZubo9m8lK5wg=
|
||||
gopkg.in/ini.v1 v1.46.0 h1:VeDZbLYGaupuvIrsYCEOe/L/2Pcs5n7hdO1ZTjporag=
|
||||
gopkg.in/ini.v1 v1.46.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
|
||||
gopkg.in/ini.v1 v1.51.1 h1:GyboHr4UqMiLUybYjd22ZjQIKEJEpgtLXtuGbR21Oho=
|
||||
gopkg.in/ini.v1 v1.51.1/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
|
||||
gopkg.in/ldap.v3 v3.0.2 h1:R6RBtabK6e1GO0eQKtkyOFbAHO73QesLzI2w2DZ6b9w=
|
||||
gopkg.in/ldap.v3 v3.0.2/go.mod h1:oxD7NyBuxchC+SgJDE1Q5Od05eGt29SDQVBmV+HYbzw=
|
||||
gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo=
|
||||
@@ -794,8 +738,6 @@ gopkg.in/src-d/go-git-fixtures.v3 v3.5.0 h1:ivZFOIltbce2Mo8IjzUHAFoq/IylO9WHhNOA
|
||||
gopkg.in/src-d/go-git-fixtures.v3 v3.5.0/go.mod h1:dLBcvytrw/TYZsNTWCnkNF2DSIlzWYqTe3rJR56Ac7g=
|
||||
gopkg.in/src-d/go-git.v4 v4.13.1 h1:SRtFyV8Kxc0UP7aCHcijOMQGPxHSmMOPrzulQWolkYE=
|
||||
gopkg.in/src-d/go-git.v4 v4.13.1/go.mod h1:nx5NYcxdKxq5fpltdHnPa2Exj4Sx0EclMWZQbYDu2z8=
|
||||
gopkg.in/stretchr/testify.v1 v1.2.2 h1:yhQC6Uy5CqibAIlk1wlusa/MJ3iAN49/BsR/dCCKz3M=
|
||||
gopkg.in/stretchr/testify.v1 v1.2.2/go.mod h1:QI5V/q6UbPmuhtm10CaFZxED9NreB8PnFYN9JcR6TxU=
|
||||
gopkg.in/testfixtures.v2 v2.5.0 h1:N08B7l2GzFQenyYbzqthDnKAA+cmb17iAZhhFxr7JHw=
|
||||
gopkg.in/testfixtures.v2 v2.5.0/go.mod h1:vyAq+MYCgNpR29qitQdLZhdbLFf4mR/2MFJRFoQZZ2M=
|
||||
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ=
|
||||
@@ -810,8 +752,6 @@ honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWh
|
||||
honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.1-2019.2.2/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg=
|
||||
mvdan.cc/xurls/v2 v2.1.0 h1:KaMb5GLhlcSX+e+qhbRJODnUUBvlw01jt4yrjFIHAuA=
|
||||
mvdan.cc/xurls/v2 v2.1.0/go.mod h1:5GrSd9rOnKOpZaji1OZLYL/yeAAtGDlo/cFe+8K5n8E=
|
||||
rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
|
||||
@@ -819,7 +759,9 @@ strk.kbt.io/projects/go/libravatar v0.0.0-20191008002943-06d1c002b251 h1:mUcz5b3
|
||||
strk.kbt.io/projects/go/libravatar v0.0.0-20191008002943-06d1c002b251/go.mod h1:FJGmPh3vz9jSos1L/F91iAgnC/aejc0wIIrF2ZwJxdY=
|
||||
xorm.io/builder v0.3.6 h1:ha28mQ2M+TFx96Hxo+iq6tQgnkC9IZkM6D8w9sKHHF8=
|
||||
xorm.io/builder v0.3.6/go.mod h1:LEFAPISnRzG+zxaxj2vPicRwz67BdhFreKg8yv8/TgU=
|
||||
xorm.io/core v0.7.2-0.20190928055935-90aeac8d08eb h1:msX3zG3BPl8Ti+LDzP33/9K7BzO/WqFXk610K1kYKfo=
|
||||
xorm.io/core v0.7.2-0.20190928055935-90aeac8d08eb/go.mod h1:jJfd0UAEzZ4t87nbQYtVjmqpIODugN6PD2D9E+dJvdM=
|
||||
xorm.io/core v0.7.2 h1:mEO22A2Z7a3fPaZMk6gKL/jMD80iiyNwRrX5HOv3XLw=
|
||||
xorm.io/core v0.7.2/go.mod h1:jJfd0UAEzZ4t87nbQYtVjmqpIODugN6PD2D9E+dJvdM=
|
||||
xorm.io/xorm v0.8.0 h1:iALxgJrX8O00f8Jk22GbZwPmxJNgssV5Mv4uc2HL9PM=
|
||||
xorm.io/xorm v0.8.0/go.mod h1:ZkJLEYLoVyg7amJK/5r779bHyzs2AU8f8VMiP6BM7uY=
|
||||
xorm.io/xorm v0.8.1 h1:4f2KXuQxVdaX3RdI3Fw81NzMiSpZeyCZt8m3sEVeIkQ=
|
||||
xorm.io/xorm v0.8.1/go.mod h1:ZkJLEYLoVyg7amJK/5r779bHyzs2AU8f8VMiP6BM7uY=
|
||||
|
@@ -69,7 +69,7 @@ func TestAPIAdminOrgCreateBadVisibility(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPIAdminOrgCreateNotAdmin(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
nonAdminUsername := "user2"
|
||||
session := loginUser(t, nonAdminUsername)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
@@ -16,7 +16,7 @@ import (
|
||||
)
|
||||
|
||||
func TestAPIAdminCreateAndDeleteSSHKey(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
// user1 is an admin user
|
||||
session := loginUser(t, "user1")
|
||||
keyOwner := models.AssertExistsAndLoadBean(t, &models.User{Name: "user2"}).(*models.User)
|
||||
@@ -46,7 +46,7 @@ func TestAPIAdminCreateAndDeleteSSHKey(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPIAdminDeleteMissingSSHKey(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
// user1 is an admin user
|
||||
session := loginUser(t, "user1")
|
||||
|
||||
@@ -56,7 +56,7 @@ func TestAPIAdminDeleteMissingSSHKey(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPIAdminDeleteUnauthorizedKey(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
adminUsername := "user1"
|
||||
normalUsername := "user2"
|
||||
session := loginUser(t, adminUsername)
|
||||
@@ -79,7 +79,7 @@ func TestAPIAdminDeleteUnauthorizedKey(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPISudoUser(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
adminUsername := "user1"
|
||||
normalUsername := "user2"
|
||||
session := loginUser(t, adminUsername)
|
||||
@@ -95,7 +95,7 @@ func TestAPISudoUser(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPISudoUserForbidden(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
adminUsername := "user1"
|
||||
normalUsername := "user2"
|
||||
|
||||
@@ -108,7 +108,7 @@ func TestAPISudoUserForbidden(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPIListUsers(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
adminUsername := "user1"
|
||||
session := loginUser(t, adminUsername)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
@@ -131,13 +131,13 @@ func TestAPIListUsers(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPIListUsersNotLoggedIn(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
req := NewRequest(t, "GET", "/api/v1/admin/users")
|
||||
MakeRequest(t, req, http.StatusUnauthorized)
|
||||
}
|
||||
|
||||
func TestAPIListUsersNonAdmin(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
nonAdminUsername := "user2"
|
||||
session := loginUser(t, nonAdminUsername)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
@@ -14,7 +14,7 @@ import (
|
||||
)
|
||||
|
||||
func testAPIGetBranch(t *testing.T, branchName string, exists bool) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
session := loginUser(t, "user2")
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
@@ -16,7 +16,7 @@ import (
|
||||
)
|
||||
|
||||
func TestAPIListRepoComments(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
comment := models.AssertExistsAndLoadBean(t, &models.Comment{},
|
||||
models.Cond("type = ?", models.CommentTypeComment)).(*models.Comment)
|
||||
@@ -40,7 +40,7 @@ func TestAPIListRepoComments(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPIListIssueComments(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
comment := models.AssertExistsAndLoadBean(t, &models.Comment{},
|
||||
models.Cond("type = ?", models.CommentTypeComment)).(*models.Comment)
|
||||
@@ -61,7 +61,7 @@ func TestAPIListIssueComments(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPICreateComment(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
const commentBody = "Comment body"
|
||||
|
||||
issue := models.AssertExistsAndLoadBean(t, &models.Issue{}).(*models.Issue)
|
||||
@@ -84,7 +84,7 @@ func TestAPICreateComment(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPIEditComment(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
const newCommentBody = "This is the new comment body"
|
||||
|
||||
comment := models.AssertExistsAndLoadBean(t, &models.Comment{},
|
||||
@@ -110,7 +110,7 @@ func TestAPIEditComment(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPIDeleteComment(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
comment := models.AssertExistsAndLoadBean(t, &models.Comment{},
|
||||
models.Cond("type = ?", models.CommentTypeComment)).(*models.Comment)
|
||||
|
@@ -12,7 +12,7 @@ import (
|
||||
)
|
||||
|
||||
func TestCreateForkNoLogin(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
req := NewRequestWithJSON(t, "POST", "/api/v1/repos/user2/repo1/forks", &api.CreateForkOption{})
|
||||
MakeRequest(t, req, http.StatusUnauthorized)
|
||||
}
|
||||
|
@@ -18,7 +18,7 @@ import (
|
||||
type makeRequestFunc func(testing.TB, *http.Request, int) *httptest.ResponseRecorder
|
||||
|
||||
func TestGPGKeys(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
session := loginUser(t, "user2")
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
|
@@ -231,3 +231,38 @@ func doAPIMergePullRequest(ctx APITestContext, owner, repo string, index int64)
|
||||
ctx.Session.MakeRequest(t, req, 200)
|
||||
}
|
||||
}
|
||||
|
||||
func doAPIGetBranch(ctx APITestContext, branch string, callback ...func(*testing.T, api.Branch)) func(*testing.T) {
|
||||
return func(t *testing.T) {
|
||||
req := NewRequestf(t, "GET", "/api/v1/repos/%s/%s/branches/%s?token=%s", ctx.Username, ctx.Reponame, branch, ctx.Token)
|
||||
if ctx.ExpectedCode != 0 {
|
||||
ctx.Session.MakeRequest(t, req, ctx.ExpectedCode)
|
||||
return
|
||||
}
|
||||
resp := ctx.Session.MakeRequest(t, req, http.StatusOK)
|
||||
|
||||
var branch api.Branch
|
||||
DecodeJSON(t, resp, &branch)
|
||||
if len(callback) > 0 {
|
||||
callback[0](t, branch)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func doAPICreateFile(ctx APITestContext, treepath string, options *api.CreateFileOptions, callback ...func(*testing.T, api.FileResponse)) func(*testing.T) {
|
||||
return func(t *testing.T) {
|
||||
url := fmt.Sprintf("/api/v1/repos/%s/%s/contents/%s?token=%s", ctx.Username, ctx.Reponame, treepath, ctx.Token)
|
||||
req := NewRequestWithJSON(t, "POST", url, &options)
|
||||
if ctx.ExpectedCode != 0 {
|
||||
ctx.Session.MakeRequest(t, req, ctx.ExpectedCode)
|
||||
return
|
||||
}
|
||||
resp := ctx.Session.MakeRequest(t, req, http.StatusCreated)
|
||||
|
||||
var contents api.FileResponse
|
||||
DecodeJSON(t, resp, &contents)
|
||||
if len(callback) > 0 {
|
||||
callback[0](t, contents)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
47
integrations/api_issue_milestone_test.go
Normal file
47
integrations/api_issue_milestone_test.go
Normal file
@@ -0,0 +1,47 @@
|
||||
// Copyright 2020 The Gitea Authors. All rights reserved.
|
||||
// Use of this source code is governed by a MIT-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package integrations
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"net/http"
|
||||
"testing"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
"code.gitea.io/gitea/modules/structs"
|
||||
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
func TestAPIIssuesMilestone(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
milestone := models.AssertExistsAndLoadBean(t, &models.Milestone{ID: 1}).(*models.Milestone)
|
||||
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: milestone.RepoID}).(*models.Repository)
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: repo.OwnerID}).(*models.User)
|
||||
assert.Equal(t, int64(1), int64(milestone.NumIssues))
|
||||
assert.Equal(t, structs.StateOpen, milestone.State())
|
||||
|
||||
session := loginUser(t, owner.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
// update values of issue
|
||||
milestoneState := "closed"
|
||||
|
||||
urlStr := fmt.Sprintf("/api/v1/repos/%s/%s/milestones/%d?token=%s", owner.Name, repo.Name, milestone.ID, token)
|
||||
req := NewRequestWithJSON(t, "PATCH", urlStr, structs.EditMilestoneOption{
|
||||
State: &milestoneState,
|
||||
})
|
||||
resp := session.MakeRequest(t, req, http.StatusOK)
|
||||
var apiMilestone structs.Milestone
|
||||
DecodeJSON(t, resp, &apiMilestone)
|
||||
assert.EqualValues(t, "closed", apiMilestone.State)
|
||||
|
||||
req = NewRequest(t, "GET", urlStr)
|
||||
resp = session.MakeRequest(t, req, http.StatusOK)
|
||||
var apiMilestone2 structs.Milestone
|
||||
DecodeJSON(t, resp, &apiMilestone2)
|
||||
assert.EqualValues(t, "closed", apiMilestone2.State)
|
||||
}
|
139
integrations/api_issue_reaction_test.go
Normal file
139
integrations/api_issue_reaction_test.go
Normal file
@@ -0,0 +1,139 @@
|
||||
// Copyright 2019 The Gitea Authors. All rights reserved.
|
||||
// Use of this source code is governed by a MIT-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package integrations
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"net/http"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
api "code.gitea.io/gitea/modules/structs"
|
||||
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
func TestAPIIssuesReactions(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
issue := models.AssertExistsAndLoadBean(t, &models.Issue{ID: 1}).(*models.Issue)
|
||||
_ = issue.LoadRepo()
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: issue.Repo.OwnerID}).(*models.User)
|
||||
|
||||
session := loginUser(t, owner.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
user2 := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
|
||||
urlStr := fmt.Sprintf("/api/v1/repos/%s/%s/issues/%d/reactions?token=%s",
|
||||
owner.Name, issue.Repo.Name, issue.Index, token)
|
||||
|
||||
//Try to add not allowed reaction
|
||||
req := NewRequestWithJSON(t, "POST", urlStr, &api.EditReactionOption{
|
||||
Reaction: "wrong",
|
||||
})
|
||||
resp := session.MakeRequest(t, req, http.StatusForbidden)
|
||||
|
||||
//Delete not allowed reaction
|
||||
req = NewRequestWithJSON(t, "DELETE", urlStr, &api.EditReactionOption{
|
||||
Reaction: "zzz",
|
||||
})
|
||||
resp = session.MakeRequest(t, req, http.StatusOK)
|
||||
|
||||
//Add allowed reaction
|
||||
req = NewRequestWithJSON(t, "POST", urlStr, &api.EditReactionOption{
|
||||
Reaction: "rocket",
|
||||
})
|
||||
resp = session.MakeRequest(t, req, http.StatusCreated)
|
||||
var apiNewReaction api.Reaction
|
||||
DecodeJSON(t, resp, &apiNewReaction)
|
||||
|
||||
//Add existing reaction
|
||||
resp = session.MakeRequest(t, req, http.StatusForbidden)
|
||||
|
||||
//Get end result of reaction list of issue #1
|
||||
req = NewRequestf(t, "GET", urlStr)
|
||||
resp = session.MakeRequest(t, req, http.StatusOK)
|
||||
var apiReactions []*api.Reaction
|
||||
DecodeJSON(t, resp, &apiReactions)
|
||||
expectResponse := make(map[int]api.Reaction)
|
||||
expectResponse[0] = api.Reaction{
|
||||
User: user2.APIFormat(),
|
||||
Reaction: "eyes",
|
||||
Created: time.Unix(1573248003, 0),
|
||||
}
|
||||
expectResponse[1] = apiNewReaction
|
||||
assert.Len(t, apiReactions, 2)
|
||||
for i, r := range apiReactions {
|
||||
assert.Equal(t, expectResponse[i].Reaction, r.Reaction)
|
||||
assert.Equal(t, expectResponse[i].Created.Unix(), r.Created.Unix())
|
||||
assert.Equal(t, expectResponse[i].User.ID, r.User.ID)
|
||||
}
|
||||
}
|
||||
|
||||
func TestAPICommentReactions(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
comment := models.AssertExistsAndLoadBean(t, &models.Comment{ID: 2}).(*models.Comment)
|
||||
_ = comment.LoadIssue()
|
||||
issue := comment.Issue
|
||||
_ = issue.LoadRepo()
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: issue.Repo.OwnerID}).(*models.User)
|
||||
|
||||
session := loginUser(t, owner.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
user1 := models.AssertExistsAndLoadBean(t, &models.User{ID: 1}).(*models.User)
|
||||
user2 := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
|
||||
urlStr := fmt.Sprintf("/api/v1/repos/%s/%s/issues/comments/%d/reactions?token=%s",
|
||||
owner.Name, issue.Repo.Name, comment.ID, token)
|
||||
|
||||
//Try to add not allowed reaction
|
||||
req := NewRequestWithJSON(t, "POST", urlStr, &api.EditReactionOption{
|
||||
Reaction: "wrong",
|
||||
})
|
||||
resp := session.MakeRequest(t, req, http.StatusForbidden)
|
||||
|
||||
//Delete none existing reaction
|
||||
req = NewRequestWithJSON(t, "DELETE", urlStr, &api.EditReactionOption{
|
||||
Reaction: "eyes",
|
||||
})
|
||||
resp = session.MakeRequest(t, req, http.StatusOK)
|
||||
|
||||
//Add allowed reaction
|
||||
req = NewRequestWithJSON(t, "POST", urlStr, &api.EditReactionOption{
|
||||
Reaction: "+1",
|
||||
})
|
||||
resp = session.MakeRequest(t, req, http.StatusCreated)
|
||||
var apiNewReaction api.Reaction
|
||||
DecodeJSON(t, resp, &apiNewReaction)
|
||||
|
||||
//Add existing reaction
|
||||
resp = session.MakeRequest(t, req, http.StatusForbidden)
|
||||
|
||||
//Get end result of reaction list of issue #1
|
||||
req = NewRequestf(t, "GET", urlStr)
|
||||
resp = session.MakeRequest(t, req, http.StatusOK)
|
||||
var apiReactions []*api.Reaction
|
||||
DecodeJSON(t, resp, &apiReactions)
|
||||
expectResponse := make(map[int]api.Reaction)
|
||||
expectResponse[0] = api.Reaction{
|
||||
User: user2.APIFormat(),
|
||||
Reaction: "laugh",
|
||||
Created: time.Unix(1573248004, 0),
|
||||
}
|
||||
expectResponse[1] = api.Reaction{
|
||||
User: user1.APIFormat(),
|
||||
Reaction: "laugh",
|
||||
Created: time.Unix(1573248005, 0),
|
||||
}
|
||||
expectResponse[2] = apiNewReaction
|
||||
assert.Len(t, apiReactions, 3)
|
||||
for i, r := range apiReactions {
|
||||
assert.Equal(t, expectResponse[i].Reaction, r.Reaction)
|
||||
assert.Equal(t, expectResponse[i].Created.Unix(), r.Created.Unix())
|
||||
assert.Equal(t, expectResponse[i].User.ID, r.User.ID)
|
||||
}
|
||||
}
|
83
integrations/api_issue_stopwatch_test.go
Normal file
83
integrations/api_issue_stopwatch_test.go
Normal file
@@ -0,0 +1,83 @@
|
||||
// Copyright 2019 The Gitea Authors. All rights reserved.
|
||||
// Use of this source code is governed by a MIT-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package integrations
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
"testing"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
api "code.gitea.io/gitea/modules/structs"
|
||||
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
func TestAPIListStopWatches(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: repo.OwnerID}).(*models.User)
|
||||
|
||||
session := loginUser(t, owner.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
req := NewRequestf(t, "GET", "/api/v1/user/stopwatches?token=%s", token)
|
||||
resp := session.MakeRequest(t, req, http.StatusOK)
|
||||
var apiWatches []*api.StopWatch
|
||||
DecodeJSON(t, resp, &apiWatches)
|
||||
expect := models.AssertExistsAndLoadBean(t, &models.Stopwatch{UserID: owner.ID}).(*models.Stopwatch)
|
||||
expectAPI, _ := expect.APIFormat()
|
||||
assert.Len(t, apiWatches, 1)
|
||||
|
||||
assert.EqualValues(t, expectAPI.IssueIndex, apiWatches[0].IssueIndex)
|
||||
assert.EqualValues(t, expectAPI.Created.Unix(), apiWatches[0].Created.Unix())
|
||||
}
|
||||
|
||||
func TestAPIStopStopWatches(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
issue := models.AssertExistsAndLoadBean(t, &models.Issue{ID: 2}).(*models.Issue)
|
||||
_ = issue.LoadRepo()
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: issue.Repo.OwnerID}).(*models.User)
|
||||
user := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
|
||||
|
||||
session := loginUser(t, user.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
req := NewRequestf(t, "POST", "/api/v1/repos/%s/%s/issues/%d/stopwatch/stop?token=%s", owner.Name, issue.Repo.Name, issue.Index, token)
|
||||
session.MakeRequest(t, req, http.StatusCreated)
|
||||
session.MakeRequest(t, req, http.StatusConflict)
|
||||
}
|
||||
|
||||
func TestAPICancelStopWatches(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
issue := models.AssertExistsAndLoadBean(t, &models.Issue{ID: 1}).(*models.Issue)
|
||||
_ = issue.LoadRepo()
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: issue.Repo.OwnerID}).(*models.User)
|
||||
user := models.AssertExistsAndLoadBean(t, &models.User{ID: 1}).(*models.User)
|
||||
|
||||
session := loginUser(t, user.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
req := NewRequestf(t, "DELETE", "/api/v1/repos/%s/%s/issues/%d/stopwatch/delete?token=%s", owner.Name, issue.Repo.Name, issue.Index, token)
|
||||
session.MakeRequest(t, req, http.StatusNoContent)
|
||||
session.MakeRequest(t, req, http.StatusConflict)
|
||||
}
|
||||
|
||||
func TestAPIStartStopWatches(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
issue := models.AssertExistsAndLoadBean(t, &models.Issue{ID: 3}).(*models.Issue)
|
||||
_ = issue.LoadRepo()
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: issue.Repo.OwnerID}).(*models.User)
|
||||
user := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
|
||||
|
||||
session := loginUser(t, user.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
req := NewRequestf(t, "POST", "/api/v1/repos/%s/%s/issues/%d/stopwatch/start?token=%s", owner.Name, issue.Repo.Name, issue.Index, token)
|
||||
session.MakeRequest(t, req, http.StatusCreated)
|
||||
session.MakeRequest(t, req, http.StatusConflict)
|
||||
}
|
@@ -7,6 +7,7 @@ package integrations
|
||||
import (
|
||||
"fmt"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"testing"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
@@ -16,7 +17,7 @@ import (
|
||||
)
|
||||
|
||||
func TestAPIListIssues(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: repo.OwnerID}).(*models.User)
|
||||
@@ -35,15 +36,15 @@ func TestAPIListIssues(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPICreateIssue(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
const body, title = "apiTestBody", "apiTestTitle"
|
||||
|
||||
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: repo.OwnerID}).(*models.User)
|
||||
repoBefore := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: repoBefore.OwnerID}).(*models.User)
|
||||
|
||||
session := loginUser(t, owner.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
urlStr := fmt.Sprintf("/api/v1/repos/%s/%s/issues?state=all&token=%s", owner.Name, repo.Name, token)
|
||||
urlStr := fmt.Sprintf("/api/v1/repos/%s/%s/issues?state=all&token=%s", owner.Name, repoBefore.Name, token)
|
||||
req := NewRequestWithJSON(t, "POST", urlStr, &api.CreateIssueOption{
|
||||
Body: body,
|
||||
Title: title,
|
||||
@@ -56,9 +57,119 @@ func TestAPICreateIssue(t *testing.T) {
|
||||
assert.Equal(t, apiIssue.Title, title)
|
||||
|
||||
models.AssertExistsAndLoadBean(t, &models.Issue{
|
||||
RepoID: repo.ID,
|
||||
RepoID: repoBefore.ID,
|
||||
AssigneeID: owner.ID,
|
||||
Content: body,
|
||||
Title: title,
|
||||
})
|
||||
|
||||
repoAfter := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
|
||||
assert.Equal(t, repoBefore.NumIssues+1, repoAfter.NumIssues)
|
||||
assert.Equal(t, repoBefore.NumClosedIssues, repoAfter.NumClosedIssues)
|
||||
}
|
||||
|
||||
func TestAPIEditIssue(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
issueBefore := models.AssertExistsAndLoadBean(t, &models.Issue{ID: 10}).(*models.Issue)
|
||||
repoBefore := models.AssertExistsAndLoadBean(t, &models.Repository{ID: issueBefore.RepoID}).(*models.Repository)
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: repoBefore.OwnerID}).(*models.User)
|
||||
assert.NoError(t, issueBefore.LoadAttributes())
|
||||
assert.Equal(t, int64(1019307200), int64(issueBefore.DeadlineUnix))
|
||||
assert.Equal(t, api.StateOpen, issueBefore.State())
|
||||
|
||||
session := loginUser(t, owner.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
// update values of issue
|
||||
issueState := "closed"
|
||||
removeDeadline := true
|
||||
milestone := int64(4)
|
||||
body := "new content!"
|
||||
title := "new title from api set"
|
||||
|
||||
urlStr := fmt.Sprintf("/api/v1/repos/%s/%s/issues/%d?token=%s", owner.Name, repoBefore.Name, issueBefore.Index, token)
|
||||
req := NewRequestWithJSON(t, "PATCH", urlStr, api.EditIssueOption{
|
||||
State: &issueState,
|
||||
RemoveDeadline: &removeDeadline,
|
||||
Milestone: &milestone,
|
||||
Body: &body,
|
||||
Title: title,
|
||||
|
||||
// ToDo change more
|
||||
})
|
||||
resp := session.MakeRequest(t, req, http.StatusCreated)
|
||||
var apiIssue api.Issue
|
||||
DecodeJSON(t, resp, &apiIssue)
|
||||
|
||||
issueAfter := models.AssertExistsAndLoadBean(t, &models.Issue{ID: 10}).(*models.Issue)
|
||||
repoAfter := models.AssertExistsAndLoadBean(t, &models.Repository{ID: issueBefore.RepoID}).(*models.Repository)
|
||||
|
||||
// check deleted user
|
||||
assert.Equal(t, int64(500), issueAfter.PosterID)
|
||||
assert.NoError(t, issueAfter.LoadAttributes())
|
||||
assert.Equal(t, int64(-1), issueAfter.PosterID)
|
||||
assert.Equal(t, int64(-1), issueBefore.PosterID)
|
||||
assert.Equal(t, int64(-1), apiIssue.Poster.ID)
|
||||
|
||||
// check repo change
|
||||
assert.Equal(t, repoBefore.NumClosedIssues+1, repoAfter.NumClosedIssues)
|
||||
|
||||
// API response
|
||||
assert.Equal(t, api.StateClosed, apiIssue.State)
|
||||
assert.Equal(t, milestone, apiIssue.Milestone.ID)
|
||||
assert.Equal(t, body, apiIssue.Body)
|
||||
assert.True(t, apiIssue.Deadline == nil)
|
||||
assert.Equal(t, title, apiIssue.Title)
|
||||
|
||||
// in database
|
||||
assert.Equal(t, api.StateClosed, issueAfter.State())
|
||||
assert.Equal(t, milestone, issueAfter.MilestoneID)
|
||||
assert.Equal(t, int64(0), int64(issueAfter.DeadlineUnix))
|
||||
assert.Equal(t, body, issueAfter.Content)
|
||||
assert.Equal(t, title, issueAfter.Title)
|
||||
}
|
||||
|
||||
func TestAPISearchIssue(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
session := loginUser(t, "user2")
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
link, _ := url.Parse("/api/v1/repos/issues/search")
|
||||
req := NewRequest(t, "GET", link.String())
|
||||
resp := session.MakeRequest(t, req, http.StatusOK)
|
||||
var apiIssues []*api.Issue
|
||||
DecodeJSON(t, resp, &apiIssues)
|
||||
|
||||
assert.Len(t, apiIssues, 8)
|
||||
|
||||
query := url.Values{}
|
||||
query.Add("token", token)
|
||||
link.RawQuery = query.Encode()
|
||||
req = NewRequest(t, "GET", link.String())
|
||||
resp = session.MakeRequest(t, req, http.StatusOK)
|
||||
DecodeJSON(t, resp, &apiIssues)
|
||||
assert.Len(t, apiIssues, 8)
|
||||
|
||||
query.Add("state", "closed")
|
||||
link.RawQuery = query.Encode()
|
||||
req = NewRequest(t, "GET", link.String())
|
||||
resp = session.MakeRequest(t, req, http.StatusOK)
|
||||
DecodeJSON(t, resp, &apiIssues)
|
||||
assert.Len(t, apiIssues, 2)
|
||||
|
||||
query.Set("state", "all")
|
||||
link.RawQuery = query.Encode()
|
||||
req = NewRequest(t, "GET", link.String())
|
||||
resp = session.MakeRequest(t, req, http.StatusOK)
|
||||
DecodeJSON(t, resp, &apiIssues)
|
||||
assert.Len(t, apiIssues, 10) //there are more but 10 is page item limit
|
||||
|
||||
query.Add("page", "2")
|
||||
link.RawQuery = query.Encode()
|
||||
req = NewRequest(t, "GET", link.String())
|
||||
resp = session.MakeRequest(t, req, http.StatusOK)
|
||||
DecodeJSON(t, resp, &apiIssues)
|
||||
assert.Len(t, apiIssues, 0)
|
||||
}
|
||||
|
109
integrations/api_issue_tracked_time_test.go
Normal file
109
integrations/api_issue_tracked_time_test.go
Normal file
@@ -0,0 +1,109 @@
|
||||
// Copyright 2019 The Gitea Authors. All rights reserved.
|
||||
// Use of this source code is governed by a MIT-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package integrations
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"net/http"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
api "code.gitea.io/gitea/modules/structs"
|
||||
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
func TestAPIGetTrackedTimes(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
user2 := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
|
||||
issue2 := models.AssertExistsAndLoadBean(t, &models.Issue{ID: 2}).(*models.Issue)
|
||||
assert.NoError(t, issue2.LoadRepo())
|
||||
|
||||
session := loginUser(t, user2.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
req := NewRequestf(t, "GET", "/api/v1/repos/%s/%s/issues/%d/times?token=%s", user2.Name, issue2.Repo.Name, issue2.Index, token)
|
||||
resp := session.MakeRequest(t, req, http.StatusOK)
|
||||
var apiTimes api.TrackedTimeList
|
||||
DecodeJSON(t, resp, &apiTimes)
|
||||
expect, err := models.GetTrackedTimes(models.FindTrackedTimesOptions{IssueID: issue2.ID})
|
||||
assert.NoError(t, err)
|
||||
assert.Len(t, apiTimes, 3)
|
||||
|
||||
for i, time := range expect {
|
||||
assert.Equal(t, time.ID, apiTimes[i].ID)
|
||||
assert.EqualValues(t, issue2.Title, apiTimes[i].Issue.Title)
|
||||
assert.EqualValues(t, issue2.ID, apiTimes[i].IssueID)
|
||||
assert.Equal(t, time.Created.Unix(), apiTimes[i].Created.Unix())
|
||||
assert.Equal(t, time.Time, apiTimes[i].Time)
|
||||
user, err := models.GetUserByID(time.UserID)
|
||||
assert.NoError(t, err)
|
||||
assert.Equal(t, user.Name, apiTimes[i].UserName)
|
||||
}
|
||||
}
|
||||
|
||||
func TestAPIDeleteTrackedTime(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
time6 := models.AssertExistsAndLoadBean(t, &models.TrackedTime{ID: 6}).(*models.TrackedTime)
|
||||
issue2 := models.AssertExistsAndLoadBean(t, &models.Issue{ID: 2}).(*models.Issue)
|
||||
assert.NoError(t, issue2.LoadRepo())
|
||||
user2 := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
|
||||
|
||||
session := loginUser(t, user2.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
//Deletion not allowed
|
||||
req := NewRequestf(t, "DELETE", "/api/v1/repos/%s/%s/issues/%d/times/%d?token=%s", user2.Name, issue2.Repo.Name, issue2.Index, time6.ID, token)
|
||||
session.MakeRequest(t, req, http.StatusForbidden)
|
||||
/* Delete own time <-- ToDo: timout without reason
|
||||
time3 := models.AssertExistsAndLoadBean(t, &models.TrackedTime{ID: 3}).(*models.TrackedTime)
|
||||
req = NewRequestf(t, "DELETE", "/api/v1/repos/%s/%s/issues/%d/times/%d?token=%s", user2.Name, issue2.Repo.Name, issue2.Index, time3.ID, token)
|
||||
session.MakeRequest(t, req, http.StatusNoContent)
|
||||
//Delete non existing time
|
||||
session.MakeRequest(t, req, http.StatusInternalServerError) */
|
||||
|
||||
//Reset time of user 2 on issue 2
|
||||
trackedSeconds, err := models.GetTrackedSeconds(models.FindTrackedTimesOptions{IssueID: 2, UserID: 2})
|
||||
assert.NoError(t, err)
|
||||
assert.Equal(t, int64(3662), trackedSeconds)
|
||||
|
||||
req = NewRequestf(t, "DELETE", "/api/v1/repos/%s/%s/issues/%d/times?token=%s", user2.Name, issue2.Repo.Name, issue2.Index, token)
|
||||
session.MakeRequest(t, req, http.StatusNoContent)
|
||||
session.MakeRequest(t, req, http.StatusNotFound)
|
||||
|
||||
trackedSeconds, err = models.GetTrackedSeconds(models.FindTrackedTimesOptions{IssueID: 2, UserID: 2})
|
||||
assert.NoError(t, err)
|
||||
assert.Equal(t, int64(0), trackedSeconds)
|
||||
}
|
||||
|
||||
func TestAPIAddTrackedTimes(t *testing.T) {
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
issue2 := models.AssertExistsAndLoadBean(t, &models.Issue{ID: 2}).(*models.Issue)
|
||||
assert.NoError(t, issue2.LoadRepo())
|
||||
user2 := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
|
||||
admin := models.AssertExistsAndLoadBean(t, &models.User{ID: 1}).(*models.User)
|
||||
|
||||
session := loginUser(t, admin.Name)
|
||||
token := getTokenForLoggedInUser(t, session)
|
||||
|
||||
urlStr := fmt.Sprintf("/api/v1/repos/%s/%s/issues/%d/times?token=%s", user2.Name, issue2.Repo.Name, issue2.Index, token)
|
||||
|
||||
req := NewRequestWithJSON(t, "POST", urlStr, &api.AddTimeOption{
|
||||
Time: 33,
|
||||
User: user2.Name,
|
||||
Created: time.Unix(947688818, 0),
|
||||
})
|
||||
resp := session.MakeRequest(t, req, http.StatusOK)
|
||||
var apiNewTime api.TrackedTime
|
||||
DecodeJSON(t, resp, &apiNewTime)
|
||||
|
||||
assert.EqualValues(t, 33, apiNewTime.Time)
|
||||
assert.EqualValues(t, user2.ID, apiNewTime.UserID)
|
||||
assert.EqualValues(t, 947688818, apiNewTime.Created.Unix())
|
||||
}
|
@@ -17,13 +17,13 @@ import (
|
||||
)
|
||||
|
||||
func TestViewDeployKeysNoLogin(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
req := NewRequest(t, "GET", "/api/v1/repos/user2/repo1/keys")
|
||||
MakeRequest(t, req, http.StatusUnauthorized)
|
||||
}
|
||||
|
||||
func TestCreateDeployKeyNoLogin(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
req := NewRequestWithJSON(t, "POST", "/api/v1/repos/user2/repo1/keys", api.CreateKeyOption{
|
||||
Title: "title",
|
||||
Key: "key",
|
||||
@@ -32,19 +32,19 @@ func TestCreateDeployKeyNoLogin(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestGetDeployKeyNoLogin(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
req := NewRequest(t, "GET", "/api/v1/repos/user2/repo1/keys/1")
|
||||
MakeRequest(t, req, http.StatusUnauthorized)
|
||||
}
|
||||
|
||||
func TestDeleteDeployKeyNoLogin(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
req := NewRequest(t, "DELETE", "/api/v1/repos/user2/repo1/keys/1")
|
||||
MakeRequest(t, req, http.StatusUnauthorized)
|
||||
}
|
||||
|
||||
func TestCreateReadOnlyDeployKey(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
repo := models.AssertExistsAndLoadBean(t, &models.Repository{Name: "repo1"}).(*models.Repository)
|
||||
repoOwner := models.AssertExistsAndLoadBean(t, &models.User{ID: repo.OwnerID}).(*models.User)
|
||||
|
||||
@@ -70,7 +70,7 @@ func TestCreateReadOnlyDeployKey(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestCreateReadWriteDeployKey(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
repo := models.AssertExistsAndLoadBean(t, &models.Repository{Name: "repo1"}).(*models.Repository)
|
||||
repoOwner := models.AssertExistsAndLoadBean(t, &models.User{ID: repo.OwnerID}).(*models.User)
|
||||
|
||||
@@ -95,7 +95,7 @@ func TestCreateReadWriteDeployKey(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestCreateUserKey(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
user := models.AssertExistsAndLoadBean(t, &models.User{Name: "user1"}).(*models.User)
|
||||
|
||||
session := loginUser(t, "user1")
|
||||
|
@@ -19,7 +19,7 @@ import (
|
||||
)
|
||||
|
||||
func TestAPIViewPulls(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: repo.OwnerID}).(*models.User)
|
||||
|
||||
@@ -36,7 +36,7 @@ func TestAPIViewPulls(t *testing.T) {
|
||||
|
||||
// TestAPIMergePullWIP ensures that we can't merge a WIP pull request
|
||||
func TestAPIMergePullWIP(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: repo.OwnerID}).(*models.User)
|
||||
pr := models.AssertExistsAndLoadBean(t, &models.PullRequest{Status: models.PullRequestStatusMergeable}, models.Cond("has_merged = ?", false)).(*models.PullRequest)
|
||||
@@ -59,7 +59,7 @@ func TestAPIMergePullWIP(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPICreatePullSuccess1(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
repo10 := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 10}).(*models.Repository)
|
||||
// repo10 have code, pulls units.
|
||||
repo11 := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 11}).(*models.Repository)
|
||||
@@ -79,7 +79,7 @@ func TestAPICreatePullSuccess1(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPICreatePullSuccess2(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
repo10 := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 10}).(*models.Repository)
|
||||
owner10 := models.AssertExistsAndLoadBean(t, &models.User{ID: repo10.OwnerID}).(*models.User)
|
||||
|
||||
|
@@ -42,7 +42,7 @@ func createNewReleaseUsingAPI(t *testing.T, session *TestSession, token string,
|
||||
}
|
||||
|
||||
func TestAPICreateAndUpdateRelease(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: repo.OwnerID}).(*models.User)
|
||||
@@ -93,7 +93,7 @@ func TestAPICreateAndUpdateRelease(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPICreateReleaseToDefaultBranch(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: repo.OwnerID}).(*models.User)
|
||||
@@ -104,7 +104,7 @@ func TestAPICreateReleaseToDefaultBranch(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPICreateReleaseToDefaultBranchOnExistingTag(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
|
||||
repo := models.AssertExistsAndLoadBean(t, &models.Repository{ID: 1}).(*models.Repository)
|
||||
owner := models.AssertExistsAndLoadBean(t, &models.User{ID: repo.OwnerID}).(*models.User)
|
||||
|
@@ -11,6 +11,7 @@ import (
|
||||
"net/url"
|
||||
"path/filepath"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
"code.gitea.io/gitea/models"
|
||||
"code.gitea.io/gitea/modules/context"
|
||||
@@ -30,12 +31,16 @@ func getCreateFileOptions() api.CreateFileOptions {
|
||||
NewBranchName: "master",
|
||||
Message: "Making this new file new/file.txt",
|
||||
Author: api.Identity{
|
||||
Name: "Anne Doe",
|
||||
Email: "annedoe@example.com",
|
||||
},
|
||||
Committer: api.Identity{
|
||||
Name: "John Doe",
|
||||
Email: "johndoe@example.com",
|
||||
},
|
||||
Committer: api.Identity{
|
||||
Name: "Jane Doe",
|
||||
Email: "janedoe@example.com",
|
||||
Dates: api.CommitDateOptions{
|
||||
Author: time.Unix(946684810, 0),
|
||||
Committer: time.Unix(978307190, 0),
|
||||
},
|
||||
},
|
||||
Content: contentEncoded,
|
||||
@@ -77,21 +82,23 @@ func getExpectedFileResponseForCreate(commitID, treePath string) *api.FileRespon
|
||||
HTMLURL: setting.AppURL + "user2/repo1/commit/" + commitID,
|
||||
Author: &api.CommitUser{
|
||||
Identity: api.Identity{
|
||||
Name: "Jane Doe",
|
||||
Email: "janedoe@example.com",
|
||||
Name: "Anne Doe",
|
||||
Email: "annedoe@example.com",
|
||||
},
|
||||
Date: "2000-01-01T00:00:10Z",
|
||||
},
|
||||
Committer: &api.CommitUser{
|
||||
Identity: api.Identity{
|
||||
Name: "John Doe",
|
||||
Email: "johndoe@example.com",
|
||||
},
|
||||
Date: "2000-12-31T23:59:50Z",
|
||||
},
|
||||
Message: "Updates README.md\n",
|
||||
},
|
||||
Verification: &api.PayloadCommitVerification{
|
||||
Verified: false,
|
||||
Reason: "unsigned",
|
||||
Reason: "gpg.error.not_signed_commit",
|
||||
Signature: "",
|
||||
Payload: "",
|
||||
},
|
||||
@@ -139,6 +146,10 @@ func TestAPICreateFile(t *testing.T) {
|
||||
assert.EqualValues(t, expectedFileResponse.Commit.HTMLURL, fileResponse.Commit.HTMLURL)
|
||||
assert.EqualValues(t, expectedFileResponse.Commit.Author.Email, fileResponse.Commit.Author.Email)
|
||||
assert.EqualValues(t, expectedFileResponse.Commit.Author.Name, fileResponse.Commit.Author.Name)
|
||||
assert.EqualValues(t, expectedFileResponse.Commit.Author.Date, fileResponse.Commit.Author.Date)
|
||||
assert.EqualValues(t, expectedFileResponse.Commit.Committer.Email, fileResponse.Commit.Committer.Email)
|
||||
assert.EqualValues(t, expectedFileResponse.Commit.Committer.Name, fileResponse.Commit.Committer.Name)
|
||||
assert.EqualValues(t, expectedFileResponse.Commit.Committer.Date, fileResponse.Commit.Committer.Date)
|
||||
gitRepo.Close()
|
||||
}
|
||||
|
||||
|
@@ -35,8 +35,8 @@ func getUpdateFileOptions() *api.UpdateFileOptions {
|
||||
Email: "johndoe@example.com",
|
||||
},
|
||||
Committer: api.Identity{
|
||||
Name: "Jane Doe",
|
||||
Email: "janedoe@example.com",
|
||||
Name: "Anne Doe",
|
||||
Email: "annedoe@example.com",
|
||||
},
|
||||
},
|
||||
SHA: "103ff9234cefeee5ec5361d22b49fbb04d385885",
|
||||
@@ -80,21 +80,21 @@ func getExpectedFileResponseForUpdate(commitID, treePath string) *api.FileRespon
|
||||
HTMLURL: setting.AppURL + "user2/repo1/commit/" + commitID,
|
||||
Author: &api.CommitUser{
|
||||
Identity: api.Identity{
|
||||
Name: "Jane Doe",
|
||||
Email: "janedoe@example.com",
|
||||
Name: "John Doe",
|
||||
Email: "johndoe@example.com",
|
||||
},
|
||||
},
|
||||
Committer: &api.CommitUser{
|
||||
Identity: api.Identity{
|
||||
Name: "John Doe",
|
||||
Email: "johndoe@example.com",
|
||||
Name: "Anne Doe",
|
||||
Email: "annedoe@example.com",
|
||||
},
|
||||
},
|
||||
Message: "My update of README.md\n",
|
||||
},
|
||||
Verification: &api.PayloadCommitVerification{
|
||||
Verified: false,
|
||||
Reason: "unsigned",
|
||||
Reason: "gpg.error.not_signed_commit",
|
||||
Signature: "",
|
||||
Payload: "",
|
||||
},
|
||||
|
@@ -15,7 +15,7 @@ import (
|
||||
)
|
||||
|
||||
func TestAPIReposGitBlobs(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
user2 := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User) // owner of the repo1 & repo16
|
||||
user3 := models.AssertExistsAndLoadBean(t, &models.User{ID: 3}).(*models.User) // owner of the repo3
|
||||
user4 := models.AssertExistsAndLoadBean(t, &models.User{ID: 4}).(*models.User) // owner of neither repos
|
||||
|
@@ -15,7 +15,7 @@ import (
|
||||
)
|
||||
|
||||
func TestAPIReposGitCommits(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
user := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
|
||||
// Login as User2.
|
||||
session := loginUser(t, user.Name)
|
||||
@@ -35,7 +35,7 @@ func TestAPIReposGitCommits(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPIReposGitCommitList(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
user := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
|
||||
// Login as User2.
|
||||
session := loginUser(t, user.Name)
|
||||
@@ -55,7 +55,7 @@ func TestAPIReposGitCommitList(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPIReposGitCommitListPage2Empty(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
user := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
|
||||
// Login as User2.
|
||||
session := loginUser(t, user.Name)
|
||||
@@ -72,7 +72,7 @@ func TestAPIReposGitCommitListPage2Empty(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestAPIReposGitCommitListDifferentBranch(t *testing.T) {
|
||||
prepareTestEnv(t)
|
||||
defer prepareTestEnv(t)()
|
||||
user := models.AssertExistsAndLoadBean(t, &models.User{ID: 2}).(*models.User)
|
||||
// Login as User2.
|
||||
session := loginUser(t, user.Name)
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user