Commit graph

1907 commits

Author SHA1 Message Date
Chri-s
9350ba7947 Add protected branch whitelists for merging (#3689)
* Add database migrations for merge whitelist

* Add merge whitelist settings for protected branches

* Add checks for merge whitelists
2018-03-25 13:01:32 +03:00
Gerben
2dc6f15eca Don't warn users about *every* dirty form (#3707)
The choice regarding which forms should or should not trigger a warning
is subjective. I tried to be consistent and not warn about forms that:
 - run an action, rather than edit data: search, send an email.
 - delete data: a warning about losing data would be confusing

Note that forms on sign-in pages were already ignored (using a selector,
rather than an explicit class on the form element).

Fixes #3698.
2018-03-23 22:10:42 +08:00
Jonas Franz
43fc430c07 Improve release page UI (#3693)
* Improve release page ui by adding size

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

* Add documentation to a.MustSize()

Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-03-19 18:06:00 +02:00
Jonas Franz
59e70c5ee9 Escape branch name in dropdown menu (#3691)
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-03-19 22:29:16 +08:00
Lunny Xiao
9e5d0a09eb
Global code search support (#3664)
* add global code search on explore

* fix bug when no anyone public repos

* change the icon

* fix typo and add UnitTypeCode check for login non-admin user

* fix ui description when no match
2018-03-16 22:04:33 +08:00
Chri-s
a2a49c93c7 Added checks for protected branches in pull requests (#3544)
* Added checks for protected branches in pull requests

Signed-off-by: Christian Wulff <NChris@posteo.net>

* Moved check for protected branch into new function CheckUserAllowedToMerge

Signed-off-by: Christian Wulff <NChris@posteo.net>

* Removed merge conflict lines from last commit

Signed-off-by: Christian Wulff <NChris@posteo.net>

* Explicit check for error type in ViewIssue

Signed-off-by: Christian Wulff <NChris@posteo.net>
2018-03-13 11:46:14 +08:00
Lauris BH
c0d41b1b77 Add label descriptions (#3662)
* Add label descriptions

* Add default descriptions to label template
2018-03-13 10:03:55 +08:00
bugreport0
b333e7129d Add separate string for the 'Create Team' button. (#3647)
* Add separate string for the 'Create Team' button.

* Add separate string for the 'Create Team' button.
2018-03-09 19:37:24 +02:00
bugreport0
9fc418a652 Add string to confirm wiki data erasure (#3629)
* Add a string to confirm wiki data erasure.

* Add a string to confirm wiki data erasure.
2018-03-06 15:25:21 +08:00
bugreport0
595da53d3c Fix incorrect 'Erase Wiki Data' string identifier. (#3613) 2018-03-02 22:31:15 +02:00
Allen Wild
8606d9f5bc Add admin dashboard option to run health checks (#3606)
There's one for git gc, why not git fsck too?

Also add a couple more trace logs to GitFsck to see progress
2018-03-02 11:09:43 +02:00
Morgan Bazalgette
535445c32e Rework special link parsing in the post-processing of markup (#3354)
* Get rid of autolink

* autolink in markdown

* Replace email addresses with mailto links

* better handling of links

* Remove autolink.js from footer

* Refactor entire html.go

* fix some bugs

* Make tests green, move what we can to html_internal_test, various other changes to processor logic

* Make markdown tests work again

This is just a description to allow me to force push in order to restart
the drone build.

* Fix failing markdown tests in routers/api/v1/misc

* Add license headers, log errors, future-proof <body>

* fix formatting
2018-02-27 09:09:18 +02:00
Lunny Xiao
769ab1e424 fix gpg expired bug when time is zero (#3584) 2018-02-26 12:25:45 +02:00
Bo-Yi Wu
fc265b036f feat: Add branch link in branch list. (#3576) 2018-02-24 23:17:59 +02:00
Lauris BH
58893384e8 Add issue closed time column to fix activity closed issues list (#3537)
Signed-off-by: Lauris Bukšis-Haberkorns <lauris@nix.lv>
2018-02-19 10:39:26 +08:00
Lauris BH
ae30315a62
Fix escaping changed title in comments (#3530)
* Fix escaping changed title in comments

* Fix escaping of wiki page titile

Signed-off-by: Lauris Bukšis-Haberkorns <lauris@nix.lv>
2018-02-18 22:06:37 +02:00
Piotr Orzechowski
b104ab3ca1 Add option to enable or disable swagger endpoints (#3502) 2018-02-14 06:46:00 +02:00
Jonas Franz
2cb4649acf Escape search query (#3486)
Signed-off-by: Jonas Franz <info@jonasfranz.de>
2018-02-11 15:42:28 +02:00
modmew8
ffd0062438 Fix checklist padding (#3460)
* Changed style of checklist in issuelist.

* Adjusted padding for progressbar, updated index.css.

* Fixed another wrong tab to spaces.

Signed-off-by: modmew8 <modmew8@gmail.com>
2018-02-06 12:22:31 +02:00
modmew8
e08b3a592e Emoji Autocomplete (#3433)
* Implemented emoji autocomplete.

* Changed emoji access url.

* Reverted vendor css to default, moved all style changes to _tribute.less

* Made no-results overwriteable, added missing autocomplete to edit issue field.

Signed-off-by: modmew8 <modmew8@gmail.com>
2018-02-03 10:09:35 +02:00
Lauris BH
f9a5cc4d8e
Use correct transaltion key for delete email button (#3422) 2018-01-31 00:31:06 +02:00
muhfaris
bec09378f9 Fix Delete repository message (#3260) 2018-01-15 08:03:30 +02:00
Alberto González Palomo
45c264f681 Templates for extra links in top navbar and repo tool tabs. (#3308)
These templates add content to the top navbar
and to the repository page.
This way we do not have to copy and modify the whole
template, and re-modify it after upgrading Gitea if
it changes.

Signed-off-by: Alberto González Palomo <bugs@sentido-labs.com>
2018-01-10 08:19:50 +02:00
Morgan Bazalgette
b5fba4cd42 Fix organization profile on mobile devices (#3332) 2018-01-10 01:11:01 +02:00
Vlad Temian
e78786ef39 Writable deploy keys (closes #671) (#3225)
* Add is_writable checkbox to deploy keys interface

* Add writable key option to deploy key form

* Add support for writable ssh keys in the interface

* Rename IsWritable to ReadOnly

* Test: create read-only and read-write deploy keys via api

* Add DeployKey access mode migration

* Update gitea sdk via govendor

* Fix deploykey migration

* Add unittests for writable deploy keys

* Move template text to locale

* Remove implicit column update

* Remove duplicate locales

* Replace ReadOnly field with IsReadOnly method

* Fix deploy_keys related integration test

* Rename v54 migration with v55

* Fix migration hell
2018-01-07 00:55:53 +02:00
Morgan Bazalgette
8ef1711055 Make the space for repo actions wider on repo header (#3312) 2018-01-06 19:20:13 +02:00
Lauris BH
8ac1501ad7
Add Pull Request merge options - Ignore white-space for conflict checking, Rebase, Squash merge (#3188)
* Pull request options migration and UI in settings

* Add ignore whitespace functionality

* Fix settings if pull requests are disabled

* Fix migration transaction

* Merge with Rebase functionality

* UI changes and related functionality for pull request merging button

* Implement squash functionality

* Fix rebase merging

* Fix pull request merge tests

* Add squash and rebase tests

* Fix API method to reuse default message functions

* Some refactoring and small fixes

* Remove more hardcoded values from tests

* Remove unneeded check from API method

* Fix variable name and comment typo

* Fix reset commit count after PR merge
2018-01-05 20:56:50 +02:00
modmew8
d996da6bab Added progressbar for issues (#1146). (#3171)
* Added progressbar for issues (#1146).

* Updated the generated index.css.

Signed-off-by: modmew8 <modmew8@gmail.com>

* Removed stored progress percentage and changed it to css calc. Also added the issue task progress to the user/dashboard/issues.

Signed-off-by: modmew8 <modmew8@gmail.com>

* Removed unnecessary blanks.

Signed-off-by: modmew8 <modmew8@gmail.com>

* Formatted the files correctly, fmt-check terminates now without errors.

Signed-off-by: modmew8 <modmew8@gmail.com>

* Removed variables, made computing the tasks on demand with precompiled regexp.

Signed-off-by: modmew8 <modmew8@gmail.com>
2018-01-03 02:34:13 -06:00
Thomas Boerger
c4a8d4ce45 Add more additional template snippets (#3286) 2018-01-02 11:32:41 +01:00
Morgan Bazalgette
3d3faa2624 Responsive view (#2750)
* Viewport meta tag

* responsive: dashboard

* responsive: issues page

* responsive: Explore page

* responsive: navbar, and some navbar css refactoring

* responsive: button for collapsing navbar in mobile view

* Mark the hamburger button as active when pressed

* better homepage for responsive views

* Bring back jump class in navbar

The class was necessary, because this way the
dropdown doesn't assume the contents of the
selected item.

* make repository homes responsive

* Make file view page responsive

* Make forms look good on responsive views

* make commits and commit diff view responsive

* issues and PRs

* responsive wiki

* Don't place auto-init far off the page

* Minor changes to amend broken stuff

minor improvements

- make login/sign up in navbar stackable
- make navbar in explore and sign in not stackable

Change selected class in TestPullCompare

Fix typo that happened when rebasing

fix dashboard on org view

improve profile UI

Use clearing on file diff to fix broken UI caused by floating elements

remove unresolved merge conflict, and | Sanitize

Fix repo home not loading
2017-12-30 18:47:52 -06:00
Chris Woodward
5332052019 Fixed missing end tag for organization link (#3229) 2017-12-19 09:47:30 +02:00
Jesstern Rays
1123313240 Use correct camel casing for JavaScript (#3224)
JavaScript should be spelt with an uppercase 'S' as per seen in [Mozilla](https://developer.mozilla.org/en-US/docs/Web/JavaScript)
2017-12-18 19:31:32 -06:00
Sandro Santilli
7e59587173 Open external tracker in blank window, consistently with wiki (#3227)
Closes #3216
2017-12-18 19:30:34 -06:00
Sandro Santilli
eb2b4df0ed Change SSL Mode from checkbox to string in admin page (#3208)
Closes #3207

Use a string, not a checkbox because "require", "verify-full",
"verify-ca" and "disable" values are supported ...
2017-12-16 23:25:00 +02:00
Ethan Koenig
bde0409433 Fix repo links on user profile (#3197) 2017-12-15 06:55:08 +02:00
silverwind
1687aa59e6 Improve suppressed diff boxes (#3193) 2017-12-14 20:26:59 +02:00
Ethan Koenig
0b77dbc11c Fix new pull request link (#3133)
* Fix new pull request link

* Only show button for branches
2017-12-13 13:06:25 +08:00
Lunny Xiao
e3f88719ab fix source download link when no code unit allowed (#3166) 2017-12-12 08:45:02 +02:00
haytona
f27a6461e3 Enable emoji for wiki view (#3158)
Enable emoji for wiki page content. It is enabled in the edit preview so the view should match.

Signed-off-by: Hamish Carpenter <hamish@hamishcarpenter.com>
2017-12-12 03:02:55 +02:00
Lunny Xiao
3b525d5696
fix gpg tmpl (#3153) 2017-12-11 22:07:25 +08:00
harry
03ec35ed79 Mention completion for issue editor. (#3136)
* new issue mention

* Mention completion on new issue and view issue page.

* Code format.

* Require tribute in pull request page.
2017-12-11 14:03:04 +08:00
Lunny Xiao
f2e20c81b6 Refactor struct's time to remove unnecessary memory usage (#3142)
* refactor struct's time to remove unnecessary memory usage

* use AsTimePtr simple code

* fix tests

* fix time compare

* fix template on gpg

* use AddDuration instead of Add
2017-12-11 06:37:04 +02:00
Sasha Varlamov
7ec6cddd27 Add 'mark all read' option to notifications (#3097)
* Add 'mark all read' option to notifications

Signed-off-by: Sasha Varlamov <sasha@sashavarlamov.com>

* Fix exported comment

Signed-off-by: Sasha Varlamov <sasha@sashavarlamov.com>

* Format method comments

Signed-off-by: Sasha Varlamov <sasha@sashavarlamov.com>

* Fix exported comment

Signed-off-by: Sasha Varlamov <sasha@sashavarlamov.com>

Format method comments

Signed-off-by: Sasha Varlamov <sasha@sashavarlamov.com>

Tests for reactions (#3083)

* Unit tests for reactions

* Fix import order

Signed-off-by: Lauris Bukšis-Haberkorns <lauris@nix.lv>

Fix reaction possition when there is attachments (#3099)

Refactor notifications swap function

* Accept change to drop beforeupdate call

* Update purge notifications error message for consistency

* Drop unnecessary check for mark all as read button

* Remove debugging comment
2017-12-07 13:52:57 +08:00
silverwind
1ed7f18815 Rework button styles on repo and commit page (#3104) 2017-12-07 09:26:12 +08:00
Ethan Koenig
03eb47b216 Fix repo links (#3093) 2017-12-05 13:52:53 +08:00
Lauris BH
5dc37b187c
Add reactions to issues/PR and comments (#2856) 2017-12-04 01:14:26 +02:00
techknowlogick
993b86628b Minor copy changes (#3074)
* Minor copy changes
Fixes #3058

* Use TrN for translations that depend on count
Fix minor type with branches count
2017-12-03 22:52:30 +02:00
Ethan Koenig
ab62da283a Fix avatar URLs (#3069)
* Fix avatar URLs

* import order
2017-12-03 19:55:13 +08:00
techknowlogick
b0971ae37c Reduce overhead of upgrades for users with custom stylesheets/JS (#3051) 2017-12-03 02:26:06 +02:00
silverwind
4947cfb7b0 Remove box-shadow from UI, fix dashboard issue (#3065) 2017-12-03 01:16:35 +02:00