* Improve issue autolinks
Update autolinks to match what github does here:
Issue in same repo: #1
Issue in different repo: org/repo#1Fixes#6264
* Use setting.AppURL when parsing URL
Using setting.AppURL here is a more reliable way of parsing the current
URL and what other functions in this file seem to use.
* Make ComposeMetas always return a valid context
* Add per repository markdown renderers for better context
* Update for use of context metas
Now that we include the user and repo name inside context metas, update
various code and tests for this new logic
* Make Ghost not link to 404 page
* Make correct localization label show
* Create and use GetLastEventLabelFake for when a Ghost user has made the action, thus not linking to a user profile
* Add corresponding _fake entries to locale_en-US
* Make Ghost avatar not link to 404 page
* Make Ghost on milestone_issues not link to 404 page
* Remove all CommitStatus when a repo is deleted
Signed-off-by: jolheiser <[email protected]>
* Minor UI tweaks (#5782)
Added 'No License' option
Added link and octicon change for external issue trackers
Reset password now notifies right away if the code is invalid
Signed-off-by: jolheiser <[email protected]>
* More UI tweaks
More info in PR
* Generate stylesheet for arc-green
* Make gofmt work
* Change PR integration since the button is changed
* Rebase
* Generate stylesheet
* UI updates
Made the PR button a "basic" button
Vertically centered the issue checkboxes
Labels will update only once after modal is closed
* Commit to reference related issues
Resolves#5782Resolves#5861
Addresses original question in #5993
* Change the comment wording since PR button is no longer little and green.
* Revert changes that made Windows work
* Regenerate stylesheet
* Regenerate stylesheets
* make generate-stylesheets
* Update integration again, changed button style
Signed-off-by: jolheiser <[email protected]>
* Added ID to PR button
Changed integration to use the ID to avoid breaking in the future
* Added missing semi-colons
* Added back distinction between issue actions and filters (overlooked it before)
Moved action button over next to other action dropdowns
* Remove extra tab formatting in list.tmpl
* Remove more formatting from GoLand
* Replace hardcoded "No License" with i18n license helper.
* Add emoji to labels
Minor cleanup of tribute code in footer.tmpl
Signed-off-by: jolheiser <[email protected]>
* Quick find/replace in other i18n files containing label translations
Signed-off-by: jolheiser <[email protected]>
* Revert "Quick find/replace in other i18n files containing label translations"
This reverts commit ec3e1a3a17.
* Add style to overwrite emoji height in labels
* Revert Makefile change that makes Windows work
* Don't display buttons if there are no notices
* clear stopwatch on merging a PR
* remove redundant gt check
* use ctx.Flash as per @bkcsoft comment
* stop timer on closing issues/PRs too
* updated translation as per review
* redirect to login page after successfully activating account
* remove unrelated changes
* stop timer for issues that are closed via commits too..Not just the 'close' UI button
* comments: Fix an incorrent DOM element selection.
This commit fixes a bug that was causing text from previously edited
comment to get saved when two comments were edited one after other.
Text area with id of `#content` isn't unique on the page but it was
being treated as unique by the event handling code.
Fixes: #5581.
* templates: Remove `id` from textarea in commit edit form.
An element is assigned an `id` only if it is unique for the whole page
but in this case there can be multiple textarea so it should have one.
* Add branch protection for approvals
Signed-off-by: Jonas Franz <[email protected]>
* Add required approvals
Signed-off-by: Jonas Franz <[email protected]>
* Add missing comments and fmt
Signed-off-by: Jonas Franz <[email protected]>
* Add type = approval and group by reviewer_id to review
* Prevent users from adding negative review limits
* Add migration for approval whitelists
Signed-off-by: Jonas Franz <[email protected]>
* add milestone issues and pulls page instead of redirecting issues page
* add milestone when creating issue from milestone page
* refactor to merge similiar codes as a new function issues
* remove milestone info on milestone issues list
* fix missing params
* prevent pull request to be merged when PR is a WIP
* add tests
* add helper to prepend WIP: in PR title
* move default wip prefixes into settings
* use configurable WIP prefixes in javascript and default to first one in templates
* add documentation
* add unit test on pull model
Signed-off-by: Julien Tant <[email protected]>
* Initial ui components for pull request review
* Add Review
Add IssueComment types
Signed-off-by: Jonas Franz <[email protected]>
(cherry picked from commit 2b4daab)
Signed-off-by: Jonas Franz <[email protected]>
* Replace ReviewComment with Content
Signed-off-by: Jonas Franz <[email protected]>
* Add load functions
Add ReviewID to findComments
Signed-off-by: Jonas Franz <[email protected]>
* Add create review comment implementation
Add migration for review
Other small changes
Signed-off-by: Jonas Franz <[email protected]>
* Simplified create and find functions for review
Signed-off-by: Jonas Franz <[email protected]>
* Moved "Pending" to first position
Signed-off-by: Jonas Franz <[email protected]>
* Add GetCurrentReview to simplify fetching current review
Signed-off-by: Jonas Franz <[email protected]>
* Preview for listing comments
Signed-off-by: Jonas Franz <[email protected]>
* Move new comment form to its own file
Signed-off-by: Jonas Franz <[email protected]>
* Implement Review form
Show Review comments on comment stream
Signed-off-by: Jonas Franz <[email protected]>
* Add support for single comments
Showing buttons in context
Signed-off-by: Jonas Franz <[email protected]>
* Add pending tag to pending review comments
Signed-off-by: Jonas Franz <[email protected]>
* Add unit tests for Review
Signed-off-by: Jonas Franz <[email protected]>
* Fetch all review ids at once
Add unit tests
Signed-off-by: Jonas Franz <[email protected]>
* gofmt
Signed-off-by: Jonas Franz <[email protected]>
* Improved comment rendering in "Files" view by adding Comments to DiffLine
Signed-off-by: Jonas Franz <[email protected]>
* Add support for invalidating comments
Signed-off-by: Jonas Franz <[email protected]>
* Switched back to code.gitea.io/git
Signed-off-by: Jonas Franz <[email protected]>
* Moved review migration from v64 to v65
Signed-off-by: Jonas Franz <[email protected]>
* Rebuild css
Signed-off-by: Jonas Franz <[email protected]>
* gofmt
Signed-off-by: Jonas Franz <[email protected]>
* Improve translations
Signed-off-by: Jonas Franz <[email protected]>
* Fix unit tests by updating fixtures and updating outdated test
Signed-off-by: Jonas Franz <[email protected]>
* Comments will be shown at the right place now
Signed-off-by: Jonas Franz <[email protected]>
* Add support for deleting CodeComments
Signed-off-by: Jonas Franz <[email protected]>
* Fix problems caused by files in subdirectories
Signed-off-by: Jonas Franz <[email protected]>
* Add support for showing code comments of reviews in conversation
Signed-off-by: Jonas Franz <[email protected]>
* Add support for "Show/Hide outdated"
Signed-off-by: Jonas Franz <[email protected]>
* Update code.gitea.io/git
Signed-off-by: Jonas Franz <[email protected]>
* Add support for new webhooks
Signed-off-by: Jonas Franz <[email protected]>
* Update comparison
Signed-off-by: Jonas Franz <[email protected]>
* Resolve conflicts
Signed-off-by: Jonas Franz <[email protected]>
* Minor UI improvements
* update code.gitea.io/git
* Fix ui bug reported by @lunny causing wrong position of add button
Add functionality to "Cancel" button
Add scale effects to add button
Hide "Cancel" button for existing comments
Signed-off-by: Jonas Franz <[email protected]>
* Prepare solving conflicts
Signed-off-by: Jonas Franz <[email protected]>
* Show add button only if no comments already exist for the line
Signed-off-by: Jonas Franz <[email protected]>
* Add missing vendor files
Signed-off-by: Jonas Franz <[email protected]>
* Check if reviewer is nil
Signed-off-by: Jonas Franz <[email protected]>
* Show forms only to users who are logged in
Signed-off-by: Jonas Franz <[email protected]>
* Revert "Show forms only to users who are logged in"
This reverts commit c083682
Signed-off-by: Jonas Franz <[email protected]>
* Save patch in comment
Render patch for code comments
Signed-off-by: Jonas Franz <[email protected]>
* Add link to comment in code
Signed-off-by: Jonas Franz <[email protected]>
* Add reply form to comment list
Show forms only to signed in users
Signed-off-by: Jonas Franz <[email protected]>
* Add 'Reply' as translatable
Add CODE_COMMENT_LINES setting
Signed-off-by: Jonas Franz <[email protected]>
* gofmt
Signed-off-by: Jonas Franz <[email protected]>
* Fix problems introduced by checking for singed in user
Signed-off-by: Jonas Franz <[email protected]>
* Add v70
Signed-off-by: Jonas Franz <[email protected]>
* Update generated stylesheet
Signed-off-by: Jonas Franz <[email protected]>
* Fix preview
Beginn with new review comment patch system
Signed-off-by: Jonas Franz <[email protected]>
* Add new algo to generate diff for line range
Remove old algo used for cutting big diffs (it was very buggy)
* Add documentation and example for CutDiffAroundLine
* Fix example of CutDiffAroundLine
* Fix some comment UI rendering bugs
* Add code comment edit mode
* Send notifications / actions to users until review gets published
Fix diff generation bug
Fix wrong hashtag
* Fix vet errors
* Send notifications also for single comments
* Fix some notification bugs, fix link
* Fix: add comment icon is only shown on code lines
* Add lint comment
* Add unit tests for git diff
* Add more error messages
* Regenerated css
Signed-off-by: Jonas Franz <[email protected]>
* fmt
Signed-off-by: Jonas Franz <[email protected]>
* Regenerated CSS with latest less version
Signed-off-by: Jonas Franz <[email protected]>
* Fix test by updating comment type to new ID
Signed-off-by: Jonas Franz <[email protected]>
* Introducing CodeComments as type for map[string]map[int64][]*Comment
Other minor code improvements
Signed-off-by: Jonas Franz <[email protected]>
* Fix data-tab issues
Signed-off-by: Jonas Franz <[email protected]>
* Remove unnecessary change
Signed-off-by: Jonas Franz <[email protected]>
* refactored checkForInvalidation
Signed-off-by: Jonas Franz <[email protected]>
* Append comments instead of setting
Signed-off-by: Jonas Franz <[email protected]>
* Use HeadRepo instead of BaseRepo
Signed-off-by: Jonas Franz <[email protected]>
* Update migration
Signed-off-by: Jonas Franz <[email protected]>
* Regenerated CSS
Signed-off-by: Jonas Franz <[email protected]>
* Add copyright
Signed-off-by: Jonas Franz <[email protected]>
* Update index.css
Signed-off-by: Jonas Franz <[email protected]>
* Implemented basic api endpoint to manage deadlines
* Fixed checking for permissions
* Updating a deadline from the ui is now entirely done via the api
* cleanup
* Cosmetics
* fixed lint + fmt
* Added swagger model definition for deadline response
* Updated gitea-sdk
* Updated gitea-sdk
* More cleanup
* Generate swagger json
* Merge branch 'master' of https://github.com/go-gitea/gitea into issue-due-date-api
# Conflicts:
# public/swagger.v1.json
* Fixed permission to update a deadline via api
* Re-added form to change a deadline
* Added client-side validation + not ignore error messages from the api
* Added locale for error message
* Merge branch 'master' of https://github.com/go-gitea/gitea
# Conflicts:
# models/issue_comment.go
* Proper date validation
* Fixed indention
* moved css to css file
* added documentation for error codes
* after merge cleanup
* Added swagger description
* DO NOTHING BUT TRIGGER THAT F*CKIN CI SO IT PICKS UP THE LATEST COMMIT AS IT SHOULD
* DO NOTHING BUT TRIGGER THAT F*CKIN CI SO IT PICKS UP THE LATEST COMMIT AS IT SHOULD
* regenerated stylesheets
* Started adding deadline to ui
* Implemented basic issue due date managing
* Improved UI for due date managing
* Added at least write access to the repo in order to modify issue due dates
* Ui improvements
* Added issue comments creation when adding/modifying/removing a due date
* Show due date in issue list
* Added api support for issue due dates
* Fixed lint suggestions
* Added deadline to sdk
* Updated css
* Added support for adding/modifiying deadlines for pull requests via api
* Fixed comments not created when updating or removing a deadline
* update sdk (will do properly once go-gitea/go-sdk#103 is merged)
* enhanced updateIssueDeadline
* Removed unnessecary Issue.DeadlineString
* UI improvements
* Small improvments to comment creation
+ ui & validation improvements
* Check if an issue is overdue is now a seperate function
* Updated go-sdk with govendor as it was merged
* Simplified isOverdue method
* removed unessecary deadline to 0 set
* Update swagger definitions
* Added missing return
* Added an explanary comment
* Improved updateIssueDeadline method so it'll only update `deadline_unix`
* Small changes and improvements
* no need to explicitly load the issue when updating a deadline, just use whats already there
* small optimisations
* Added check if a deadline was modified before updating it
* Moved comment creating logic into its own function
* Code cleanup for creating deadline comment
* locale improvement
* When modifying a deadline, the old deadline is saved with the comment
* small improvments to xorm session handling when updating an issue deadline
+ style nitpicks
* style nitpicks
* Moved checking for if the user has write acces to middleware
* Show total tracked time in issue and milestone list
Show total tracked time at issue page
Signed-off-by: Jonas Franz <[email protected]>
* Optimizing TotalTimes by using SumInt
Signed-off-by: Jonas Franz <[email protected]>
* Fixing wrong total times for milestones caused by a missing JOIN
Adding unit tests for total times
Signed-off-by: Jonas Franz <[email protected]>
* Logging error instead of ignoring it
Signed-off-by: Jonas Franz <[email protected]>
* Correcting spelling mistakes
Signed-off-by: Jonas Franz <[email protected]>
* Change error message to a short version
Signed-off-by: Jonas Franz <[email protected]>
* Add error handling to TotalTimes
Add variable for totalTimes
Signed-off-by: Jonas Franz <[email protected]>
* Introduce TotalTrackedTimes as variable of issue
Load TotalTrackedTimes by loading attributes of IssueList
Load TotalTrackedTimes by loading attributes of single issue
Add Sec2Time as helper to use it in templates
Signed-off-by: Jonas Franz <[email protected]>
* Fixed test + gofmt
Signed-off-by: Jonas Franz <[email protected]>
* Load TotalTrackedTimes via MilestoneList instead of single requests
Signed-off-by: Jonas Franz <[email protected]>
* Add documentation for MilestoneList
Signed-off-by: Jonas Franz <[email protected]>
* Add documentation for MilestoneList
Signed-off-by: Jonas Franz <[email protected]>
* Fix test
Signed-off-by: Jonas Franz <[email protected]>
* Change comment from SQL query to description
Signed-off-by: Jonas Franz <[email protected]>
* Fix unit test by using int64 instead of int
Signed-off-by: Jonas Franz <[email protected]>
* Fix unit test by using int64 instead of int
Signed-off-by: Jonas Franz <[email protected]>
* Check if timetracker is enabled
Signed-off-by: Jonas Franz <[email protected]>
* Fix test by enabling timetracking
Signed-off-by: Jonas Franz <[email protected]>
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.
* Added checks for protected branches in pull requests
Signed-off-by: Christian Wulff <[email protected]>
* Moved check for protected branch into new function CheckUserAllowedToMerge
Signed-off-by: Christian Wulff <[email protected]>
* Removed merge conflict lines from last commit
Signed-off-by: Christian Wulff <[email protected]>
* Explicit check for error type in ViewIssue
Signed-off-by: Christian Wulff <[email protected]>
* Changed style of checklist in issuelist.
* Adjusted padding for progressbar, updated index.css.
* Fixed another wrong tab to spaces.
Signed-off-by: modmew8 <[email protected]>
* 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
* Added progressbar for issues (#1146).
* Updated the generated index.css.
Signed-off-by: modmew8 <[email protected]>
* 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 <[email protected]>
* Removed unnecessary blanks.
Signed-off-by: modmew8 <[email protected]>
* Formatted the files correctly, fmt-check terminates now without errors.
Signed-off-by: modmew8 <[email protected]>
* Removed variables, made computing the tasks on demand with precompiled regexp.
Signed-off-by: modmew8 <[email protected]>