Commit Graph

684 Commits

Author SHA1 Message Date
Mario Lubenka 8eba27c792 Repository avatar fallback configuration (#7087)
* Only show repository avatar in list when one was selected

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Adds fallback configuration option for repository avatar

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Implements repository avatar fallback

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Adds admin task for deleting generated repository avatars

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Solve linting issues

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Save avatar before updating database

* Linting

* Update models/repo.go

Co-Authored-By: zeripath <art27@cantab.net>
2019-06-02 14:40:12 +08:00
GiteaBot d95caf50ec [skip ci] Updated translations via Crowdin 2019-05-30 16:49:44 +00:00
GiteaBot cdd10f145b [skip ci] Updated translations via Crowdin 2019-05-30 02:25:01 +00:00
Sergey Dryabzhinsky 3fd18838aa Repository avatars (#6986)
* Repository avatars

- first variant of code from old work for gogs
- add migration 87
- add new option in app.ini
- add en-US locale string
- add new class in repository.less

* Add changed index.css, remove unused template name

* Update en-us doc about configuration options

* Add comments to new functions, add new option to docker app.ini

* Add comment for lint

* Remove variable, not needed

* Fix formatting

* Update swagger api template

* Check if avatar exists

* Fix avatar link/path checks

* Typo

* TEXT column can't have a default value

* Fixes:

- remove old avatar file on upload
- use ID in name of avatar file - users may upload same files
- add simple tests

* Fix fmt check

* Generate PNG instead of "static" GIF

* More informative comment

* Fix error message

* Update avatar upload checks:

- add file size check
- add new option
- update config docs
- add new string to en-us locale

* Fixes:

- use FileHEader field for check file size
- add new test - upload big image

* Fix formatting

* Update comments

* Update log message

* Removed wrong style - not needed

* Use Sync2 to migrate

* Update repos list view

- bigger avatar
- fix html blocks alignment

* A little adjust avatar size

* Use small icons for explore/repo list

* Use new cool avatar preparation func by @lafriks

* Missing changes for new function

* Remove unused import, move imports

* Missed new option definition in app.ini

Add file size check in user/profile avatar upload

* Use smaller field length for Avatar

* Use session to update repo DB data, update DeleteAvatar - use session too

* Fix err variable definition

* As suggested @lafriks - return as soon as possible, code readability
2019-05-29 22:22:26 -04:00
GiteaBot d01e728090 [skip ci] Updated translations via Crowdin 2019-05-28 16:02:55 +00:00
GiteaBot 27b271d457 [skip ci] Updated translations via Crowdin 2019-05-28 09:44:31 +00:00
zeripath bd9ed96da5
Install page - Handle invalid administrator username better (#7060)
* Install page - detect invalid admin username before installing

* Also fix #6954
2019-05-28 07:18:40 +01:00
GiteaBot 5f05aa13e0 [skip ci] Updated translations via Crowdin 2019-05-25 08:41:06 +00:00
GiteaBot 61f00bc238 [skip ci] Updated translations via Crowdin 2019-05-24 16:44:08 +00:00
GiteaBot 6ff9349a09 [skip ci] Updated translations via Crowdin 2019-05-24 09:12:13 +00:00
Vladimir Panteleev a98e085031 Show git-notes (#6984)
* Show git-notes

* Make git-notes heading text localizable

* Refactor git-notes data fetching to a separate function

* Display the author and time of git notes

* Move note bubble inside the commit bubble

* Revert "Move note bubble inside the commit bubble"

This reverts commit c0951fe0e3.

* Add test for git-notes

* testing ui

* Polish CSS

* Apply suggestions from code review

Co-Authored-By: Lauris BH <lauris@nix.lv>
2019-05-24 10:52:05 +03:00
Lunny Xiao d5a98a2969 Add support of utf8mb4 for mysql (#6992) 2019-05-24 00:15:26 -04:00
GiteaBot 7dd983797c [skip ci] Updated translations via Crowdin 2019-05-15 15:52:29 +00:00
GiteaBot 5df5bfbd13 [skip ci] Updated translations via Crowdin 2019-05-13 15:41:18 +00:00
GiteaBot 3d82367bdc [skip ci] Updated translations via Crowdin 2019-05-12 11:13:32 +00:00
GiteaBot 1658cd04e9 [skip ci] Updated translations via Crowdin 2019-05-11 09:16:08 +00:00
Jannik Beyerstedt f378cb572a improve description of branch protection (fix #6886) (#6906)
The branch protection description text were not quite accurate.
2019-05-11 10:42:19 +03:00
GiteaBot a84f10ad1a [skip ci] Updated translations via Crowdin 2019-05-08 07:53:17 +00:00
GiteaBot 91c2c237f9 [skip ci] Updated translations via Crowdin 2019-05-07 17:23:26 +00:00
GiteaBot 9139f35ff6 [skip ci] Updated translations via Crowdin 2019-05-07 01:14:01 +00:00
Lunny Xiao 08069dc465
Improve migrations to support migrating milestones/labels/issues/comments/pullrequests (#6290)
* add migrations

* fix package dependency

* fix lints

* implements migrations except pull requests

* add releases

* migrating releases

* fix bug

* fix lint

* fix migrate releases

* fix tests

* add rollback

* pull request migtations

* fix import

* fix go module vendor

* add tests for upload to gitea

* more migrate options

* fix swagger-check

* fix misspell

* add options on migration UI

* fix log error

* improve UI options on migrating

* add support for username password when migrating from github

* fix tests

* remove comments and fix migrate limitation

* improve error handles

* migrate API will also support migrate milestones/labels/issues/pulls/releases

* fix tests and remove unused codes

* add DownloaderFactory and docs about how to create a new Downloader

* fix misspell

* fix migration docs

* Add hints about migrate options on migration page

* fix tests
2019-05-07 09:12:51 +08:00
GiteaBot 1c7c739eb9 [skip ci] Updated translations via Crowdin 2019-05-06 19:51:02 +00:00
Lunny Xiao 01ebd52a1f fix config ui error about cache ttl (#6861) 2019-05-06 17:35:11 +03:00
GiteaBot 5d5eae6aea [skip ci] Updated translations via Crowdin 2019-05-06 12:18:49 +00:00
GiteaBot 722a2bd7ec [skip ci] Updated translations via Crowdin 2019-05-05 19:42:06 +00:00
GiteaBot 9148e45ed7 [skip ci] Updated translations via Crowdin 2019-05-05 18:59:35 +00:00
Simon a2a006a5d5 Add GET requests to webhook (#6771)
* Add GET requests to webhook

* make fmt

* Handle invalid http method on webhook

* Uppercase http method in webhook

* Rename v85.go to v86.go

* make fmt
2019-05-05 14:09:02 -04:00
GiteaBot c1da790cee [skip ci] Updated translations via Crowdin 2019-05-05 13:49:50 +00:00
Lauris BH 410301f0ee
Improve localization of git activity stats (#6848) 2019-05-04 23:32:37 +03:00
Lauris BH 1fa9662946
Git statistics in Activity tab (#4724)
* Initial implementation for git statistics in Activity tab

* Create top user by commit count endpoint

* Add UI and update src-d/go-git dependency

* Add coloring

* Fix typo

* Move git activity stats data extraction to git module

* Fix message

* Add git code stats test
2019-05-04 15:39:03 +03:00
GiteaBot 26c7c97447 [skip ci] Updated translations via Crowdin 2019-05-02 20:30:21 +00:00
GiteaBot 26042a8175 [skip ci] Updated translations via Crowdin 2019-04-30 13:30:05 +00:00
GiteaBot ccf4783980 [skip ci] Updated translations via Crowdin 2019-04-29 01:47:24 +00:00
GiteaBot 3d26b3f216 [skip ci] Updated translations via Crowdin 2019-04-28 19:50:49 +00:00
GiteaBot e0172f0db7 [skip ci] Updated translations via Crowdin 2019-04-24 04:56:25 +00:00
GiteaBot 2a0e86d5f2 [skip ci] Updated translations via Crowdin 2019-04-22 20:43:37 +00:00
Mario Lubenka bc86134759 Show "delete branch" button on closed pull requests (#6570) (#6601)
* Show button to delete a pull request branch after a pull request has been closed (#6570)

Signed-off-by: Mario Lubenka <mario.lubenka@googlemail.com>

* Update routers/repo/pull.go

Co-Authored-By: saitho <mario.lubenka@googlemail.com>
2019-04-20 23:50:34 +03:00
GiteaBot b1bb700665 [skip ci] Updated translations via Crowdin 2019-04-20 11:49:59 +00:00
GiteaBot b74dc970e9 [skip ci] Updated translations via Crowdin 2019-04-20 04:17:31 +00:00
GiteaBot 40dc458bb6 [skip ci] Updated translations via Crowdin 2019-04-20 02:49:19 +00:00
Andrzej Ressel 469d9b7d9a Add option to blame files (#5721) 2019-04-19 22:47:00 -04:00
Daniel Grier b9d1fb6de3 Add support for MS Teams webhooks (#6632) 2019-04-19 10:18:06 -04:00
GiteaBot dae94e33be [skip ci] Updated translations via Crowdin 2019-04-19 02:57:33 +00:00
techknowlogick 56da256853
Telegram webhook (#4227) 2019-04-18 22:45:02 -04:00
AJ ONeal 6dbd261852 UX + Security current user password reset (#5042)
* allow current user to reset their own password

* handle reset password edge cases properly and consistently

* remove dangling assignment

* properly label account recovery instead of reset password

* remove 'Click here' from button

* update English-only account-recovery templates
2019-04-18 10:23:59 +03:00
GiteaBot fdb933cd67 [skip ci] Updated translations via Crowdin 2019-04-18 05:02:47 +00:00
Richard Mahn 2262811e40 Fixes 4762 - Content API for Creating, Updating, Deleting Files (#6314) 2019-04-17 12:06:35 -04:00
GiteaBot 059195b127 [skip ci] Updated translations via Crowdin 2019-04-17 14:52:57 +00:00
GiteaBot cf0a9a04a9 [skip ci] Updated translations via Crowdin 2019-04-17 11:14:20 +00:00
Jonas Franz 7a4c29c739 OAuth2 Grant UI (#6625)
* Add oauth2 grants ui

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Add delete functionality
Add translations

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Fix unit tests

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Fix unit tests

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Refactor DeleteOAuth2Grant
Use results.Close()

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Refactor DeleteOAuth2Grant (again)

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Check if user ID is zero

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Check if grant ID is zero

Signed-off-by: Jonas Franz <info@jonasfranz.software>
2019-04-17 16:18:16 +08:00