7144 Commits (23414ac2a1d83f91ff47c5d8bbedebe709b1f408)
 

Author SHA1 Message Date
Zsombor 23414ac2a1 Fix panic: template: repo/issue/list:210: unexpected "=" in operand (#6041) 5 years ago
zeripath 7f38e2d0de
Update and expand information about building Gitea (#6019)
* Update and expand building information

Signed-off-by: Andrew Thornton <art27@cantab.net>

* remove extraneous extra line

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Fix spelling mistake

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Note about documentation for the website

Signed-off-by: Andrew Thornton <art27@cantab.net>

* More changes

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Clarified the automatic build dependency

* Update the from-source to match the hacking information

* Extend quotes

* Update required go and discord link

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Update hacking-on-gitea.en-us.md

Add in information about postcss
5 years ago
zeripath 2a03e96bce
Allow markdown files to read from the LFS (#5787)
This PR makes it possible for the markdown renderer to render images and media straight from the LFS.

Fix #5746

Signed-off-by: Andrew Thornton [art27@cantab.net](mailto:art27@cantab.net)
5 years ago
zeripath 296814e887 Refactor editor upload, update and delete to use git plumbing and add LFS support (#5702)
* Use git plumbing for upload: #5621 repo_editor.go: UploadRepoFile

* Use git plumbing for upload: #5621 repo_editor.go: GetDiffPreview

* Use git plumbing for upload: #5621 repo_editor.go: DeleteRepoFile

* Use git plumbing for upload: #5621 repo_editor.go: UploadRepoFiles

* Move branch checkout functions out of repo_editor.go as they are no longer used there

* BUGFIX: The default permissions should be 100644

    This is a change from the previous code but is more in keeping
    with the default behaviour of git.

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Standardise cleanUploadFilename to more closely match git

See verify_path in: 7f4e641693/read-cache.c (L951)

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Redirect on bad paths

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Refactor to move the uploading functions out to a module

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Add LFS support

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Update upload.go attribution header

Upload.go is essentially the remnants of repo_editor.go. The remaining code is essentially unchanged from the Gogs code, hence the Gogs attribution.

* Delete upload files after session committed

* Ensure that GIT_AUTHOR_NAME etc. are valid for git

see #5774

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Add in test cases per @lafriks comment

* Add space between gitea and github imports

Signed-off-by: Andrew Thornton <art27@cantab.net>

* more examples in TestCleanUploadName

Signed-off-by: Andrew Thornton <art27@cantab.net>

* fix formatting

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Set the SSH_ORIGINAL_COMMAND to ensure hooks are run

Signed-off-by: Andrew Thornton <art27@cantab.net>

* Switch off SSH_ORIGINAL_COMMAND

Signed-off-by: Andrew Thornton <art27@cantab.net>
5 years ago
manuelluis fc038caa69 In basic auth check for tokens before call UserSignIn (#5725)
* Check first if user/password is a token

* In basic auth check if user/password is a token

* Remove unnecessary else statement

* Changes of fmt
5 years ago
GiteaBot 48a9025346 [skip ci] Updated translations via Crowdin 5 years ago
Luo Yifei 7884353a04 Add the Owner Name to differentiate when merging (#3807) 5 years ago
GiteaBot baffea1ddb [skip ci] Updated translations via Crowdin 5 years ago
Antoine GIRARD 9eb00fed13 Run benchmark at tag to track performances (#6035) 5 years ago
silverwind 353282e658 Add autoprefixer to css build (#6029)
* Add autoprefixer to css build

* also use autoprefixer on theme files
5 years ago
Lanre Adelowo d0cb5aa9f9 fix #3200 (#6033) 5 years ago
Lanre Adelowo c71c28eab8 update docs (#6032) 5 years ago
Lanre Adelowo 9d8178b3ac Add option to close issues via commit on a non master branch (#5992)
* fixes #5957

* add tests to make sure config option is respected

* use already defined struct

* - use migration to make the flag repo wide not for the entire gitea instance
Also note that the config value can still be set so as to be able to control the value for new repositories that are to be created

- fix copy/paste error in copyright header year and rearrange import

- use repo config instead of server config value to determine if a commit should close an issue

- update testsuite

* use global config only when creating a new repository

* allow repo admin toggle feature via UI

* fix typo and improve testcase

* fix fixtures

* add DEFAULT prefix to config value

* fix test
5 years ago
zeripath c0adb5ea8b
Create repository on organisation by default on its dashboard (#6026)
* Create repository on organisation by default on its dashboard
* Only show owners the add new repositories to an organisation button.

Fix #3253

Signed-off-by: Andrew Thornton <art27@cantab.net>
5 years ago
Lunny Xiao 820e28c904
Split setting.go as multiple files (#6014)
* split setting.go as multiple files

* fix comments
5 years ago
Lunny Xiao 9e8cc3b18d add default time out for git operations (#6015) 5 years ago
silverwind 681345dc99 UI: Make dashboard navbar and footer full-width (#6013)
* UI: Make dashboard navbar full-width

* more tweaks: full-width footer and consistent padding

* fix page layout causing unneccesary scrollbars on small pages
5 years ago
Lanre Adelowo 3a33742e38 disable git fsck for mirrored repos by default (#6018) 5 years ago
Thomas Loubiou d252d4eb8c Remove extra spaces (#6016) 5 years ago
Paul 8c865f3ce8 Fix metrics auth token detection (#6006)
Signed-off-by: Pauls Barkans <paulsb@gmail.com>
5 years ago
zeripath 11a9ce6a2b Increase the version of less (#6010) 5 years ago
silverwind c3d8fb73dc fix header menu misalignment (#6002) 5 years ago
GiteaBot db58dbabfc [skip ci] Updated translations via Crowdin 5 years ago
Richard Mahn ba91214633 Feature - #3031 - search for org repos (#5986) 5 years ago
Thomas Loubiou 7fb09f035a Fix #5799 - swagger for mergePullRequest (#5996) 5 years ago
Lanre Adelowo 2e85e70e38 Enhance closed PR and Issue status in the list (#6000)
* working version

* Update options/locale/locale_en-US.ini

Co-Authored-By: adelowo <adelowomailbox@gmail.com>

* update templates
5 years ago
GiteaBot f60b1d8fe2 [skip ci] Updated translations via Crowdin 5 years ago
silverwind 4c5b585a6f UI: Make navbar full width (#5998) 5 years ago
silverwind 6606d650fa UI: Fix repo header issues (#5995)
Fixes: https://github.com/go-gitea/gitea/issues/5985
5 years ago
John Olheiser f51e7ed18e Update U2F section defaults (#5994)
Signed-off-by: jolheiser <john.olheiser@gmail.com>
5 years ago
Lunny Xiao 01bbf5ea69 Add API to list tags (#5850)
* Add API to list tags

* update dependency gitea sdk vendor

* fix swagger generation

* fix swagger

* add tests

* update code.gitea.io/git vendor
5 years ago
Lunny Xiao 2d213b64d1 use native golang SSH library but ssh-keygen when enable built-in SSH server to remove dependent on that command lines (#5976)
* use native golang SSH library but ssh-keygen when enable built-in SSH server to remove dependent on that command lines

* fix tests and add comment head
5 years ago
Lunny Xiao 06a1739553 fix bug when deleting a linked account will removed all (#5989) 5 years ago
Lanre Adelowo 9dfdf80af0 Expose issue stopwatch toggling via API (#5970) 5 years ago
zeripath cc48c12d8f Fix empty ssh key importing in ldap (#5984) 5 years ago
Monty Taylor 44d6a904d3 Support n as a line highlight prefix (#5987)
We're working on rolling out gitea as a replacement for a fairly
large cgit installation. Part of this involves a metric ton of
mod_rewrite rules so that links people have out in the wild will
still work. Unfortunately, cgit uses #n1 in the url to indicate
a single line highlight, which doesn't get passed to the server
and therefore can't be rewritten.

We've got a local workaround by shoving a script block into a
custom header template, but thought it might be nicer to upstream
a simple patch to support #n as a prefix for single line highlights.
(luckily for simplicity, cgit does not support ranges)

Signed-off-by: Monty Taylor <mordred@inaugust.com>
5 years ago
Richard Mahn da1edbfb79 Feature - Pagination for git tree API (#5838)
* Feature - Pagination for git tree API

* Handles case when page is negative

* Does a for loop over the start and end rather than all entries

* Removed redundent logic

* Adds per_page as a query parameter

* Adds DEFAULT_GIT_TREES_PER_PAGE for settings, ran make fmt

* Fix typo in cheat-sheet en

* Makes page start at 1, generated swagger

* Use updates to SDK

* Updates to use latest sdk

* Updates swagger for tree api

* Adds test for GetTreeBySHA

* Updates per PR reviews

* Updates per PR reviews

* Remove file

* Formatting

* Fix to swagger file

* Fix to swagger

* Update v1_json.tmpl

* Fix to swagger file
5 years ago
GiteaBot 0c840a924a [skip ci] Updated translations via Crowdin 5 years ago
techknowlogick ad059fdbbc
Admin config page mailertype setting option update (#5973)
* Fix #5972
5 years ago
silverwind 0c721fe016 UI: Dashboard tweaks (#5974)
- Don't show divider below heatmap when it's hidden via media-query
- Make divider between user menu adhere to container width
- Remove excessiv margins on heatmap
5 years ago
zeripath f286a5abb4 Allow Macaron to be set to log through to gitea.log (#5667)
* Allow Macaron to be set to log through gitea.log

Fix #4291
5 years ago
Gabriel Silva Simões 3b7f41f9f7 Fix serving of raw wiki files other than .md (#5814)
* Fix serving of raw wiki files other than .md

Closes #4690.
Closes #4395.

Signed-off-by: Gabriel Silva Simões <simoes.sgabriel@gmail.com>

* Simplify code at routers/repo/wiki.go

Signed-off-by: Gabriel Silva Simões <simoes.sgabriel@gmail.com>

* Add more files to user2/repo1.wiki for testing

Signed-off-by: Gabriel Silva Simões <simoes.sgabriel@gmail.com>

* Update macaron to v1.3.2

Signed-off-by: Gabriel Silva Simões <simoes.sgabriel@gmail.com>

* Add tests for WikiRaw

Signed-off-by: Gabriel Silva Simões <simoes.sgabriel@gmail.com>

* Fix NewResponseWriter usage due to macaron update

Signed-off-by: Gabriel Silva Simões <simoes.sgabriel@gmail.com>

* Add raw to reserved wiki names

Signed-off-by: Gabriel Silva Simões <simoes.sgabriel@gmail.com>
5 years ago
techknowlogick 4a747aef7b
Upgrade alpine to 3.9 (#5909) 5 years ago
silverwind acaf5c96fe UI: Repo header tweaks (#5945)
* UI: Repo header tweaks

- Use basic buttons on the header buttons, matching gogs
- Make 'Manage topic' text smaller, remove margin-left with no topics
present
- Move various inline styles to CSS
- Use flexbox on header title and buttons

* fix indentation

* reverse media query wrapping

* fix inconsisten whitespace
5 years ago
Lanre Adelowo c20034be31 Display the branch name in the commit view (#5950)
* add branch info

* Remove blank lines

* Remove blank lines

* update git dependency
5 years ago
silverwind 2ec9bf9048 UI: Fixes for repo topic editor (#5971)
- Properly hides the edit interface when saving a empty topic list
- Align the Done button with the edit box
5 years ago
GiteaBot 1772893505 [skip ci] Updated translations via Crowdin 5 years ago
techknowlogick 9de871a0f8
add other session providers (#5963) 5 years ago
Lunny Xiao bf4badad1d Pull request conflict files detection (#5951)
* add conflict detection

* test pull request conflict files

* fix detection files number

* fix comments
5 years ago
GiteaBot 680a57ce92 [skip ci] Updated translations via Crowdin 5 years ago