* Change language statistics to save size instead of percentage (#11681)
* Change language statistics to save size instead of percentage in database
Co-Authored-By: Cirno the Strongest <[email protected]>
* Do not exclude if only language
* Fix edge cases with special langauges
Co-authored-by: Cirno the Strongest <[email protected]>
* Fix language stat calculation (#11692)
* Fix language stat calculation
* Group languages and ignore 0 size files
* remove unneeded code
Co-authored-by: Cirno the Strongest <[email protected]>
GH has different HardBreaks behaviour for markdown comments and documents.
Comments have hard breaks and documents have soft breaks - therefore Gitea's rendering will always be different from GH's if we only provide one setting.
Here we split the setting in to two - one for documents and one for comments and other things.
Signed-off-by: Andrew Thornton [email protected]
Changes to index.js as per @silverwind
Co-authored-by: silverwind <[email protected]>
Changes to docs as per @guillep2k
Co-authored-by: guillep2k <[email protected]>
* Fix repo-list private and total count bugs
Signed-off-by: Andrew Thornton <[email protected]>
* Ensure limited and private org public repos are displayed on "private"
Signed-off-by: Andrew Thornton <[email protected]>
* switch from onlyPrivate to is_private
Signed-off-by: Andrew Thornton <[email protected]>
* Generate swagger
Signed-off-by: Andrew Thornton <[email protected]>
Co-authored-by: guillep2k <[email protected]>
Co-authored-by: guillep2k <[email protected]>
* Allow all members of private orgs to see public repos
Fix#10144
Signed-off-by: Andrew Thornton <[email protected]>
* Update models/repo_list.go
Co-authored-by: Lauris BH <[email protected]>
* Refactor Cron and merge dashboard tasks
* Merge Cron and Dashboard tasks
* Make every cron task report a system notice on completion
* Refactor the creation of these tasks
* Ensure that execution counts of tasks is correct
* Allow cron tasks to be started from the cron page
* golangci-lint fixes
* Enforce that only one task with the same name can be registered
Signed-off-by: Andrew Thornton <[email protected]>
* fix name check
Signed-off-by: Andrew Thornton <[email protected]>
* as per @guillep2k
* as per @lafriks
Signed-off-by: Andrew Thornton <[email protected]>
* Add git.CommandContext variants
Signed-off-by: Andrew Thornton <[email protected]>
Co-authored-by: Lauris BH <[email protected]>
Co-authored-by: Lunny Xiao <[email protected]>
Co-authored-by: techknowlogick <[email protected]>
The migration introduced in #8742 breaks mysql installations. This pr fixes that by correctly using CONCAT.
Signed-off-by: kolaente <[email protected]>
* Properly generate ref URLs
Tags used to not generate correct URLs (src/branch/tags/1.0.0 instead of
src/tags/1.0.0).
Also cleans up some code around it with the created helper functions.
* Fix formatting and create migration
* Add copyright head to utils_test
* Use a raw query for the ref migration
* Remove semicolon
* Quote column and table names in migration SQL
* Change || to CONCAT, since MSSQL does not support ||
* Make migration engine aware
* Add missing import
* Move ref EndName and URL to the issue service
* Fix tests
* Add test for commit refs
* Update issue.go
* Use the right command for building JavaScript bundles
* Prepare for merge
* Check for refs/* before prepending in migration
* Update services/issue/issue_test.go
* Update modules/git/utils_test.go
Co-authored-by: techknowlogick <[email protected]>
Co-authored-by: techknowlogick <[email protected]>
* Correctly set the organization num repos
Correctly set the organization num repos to the number of
accessible repos for the user
Fix#11194
Signed-off-by: Andrew Thornton <[email protected]>
* as per @lunny
Signed-off-by: Andrew Thornton <[email protected]>
* attempt to fix mssql
Signed-off-by: Andrew Thornton <[email protected]>
* Update models/user.go
* Explicit columns
Signed-off-by: Andrew Thornton <[email protected]>
* Add test and fix 0 counted orgs
Signed-off-by: Andrew Thornton <[email protected]>
* remove orgname from api
Signed-off-by: Andrew Thornton <[email protected]>
* Set background of openIDConnect logo to white in arc-green theme
* Fixed linting off arc-green theme
Signed-off-by: Leo Maroni <[email protected]>
* Revert changes of first commit (white background) and replaced the image
* Updated openid_connect (part 2)
* Update public/img/auth/openid_connect.svg
Now in one line
Co-authored-by: silverwind <[email protected]>
Co-authored-by: silverwind <[email protected]>
Co-authored-by: zeripath <[email protected]>
Co-authored-by: Lauris BH <[email protected]>
prevent double entries in results of GetOrgsCanCreateRepoByUserID
I first try to only add GroupBy directly but xorm return broken user objects ...
... solution was to just query related UserIDs(OrgIDs) first and return OrgUsers based on this IDs
close#11258
Co-authored-by: zeripath <[email protected]>
* Fix creation of Org repos
Fix go-gitea#9269
* Change variable name to appease linter
* Update PR with suggestions
Add a note for user.CanCreateRepo() about failure assumptions
Change repo.create help message
Co-authored-by: guillep2k <[email protected]>
Instead of further handling requests to public which causes issues like #11088, immediately terminate requests to directories js, css, fomantic if no file is found which is checked against a hardcoded list. Maybe there is a way to retrieve the top-level entries below public in a dynamic fashion.
I also added fomantic to the reserved usernames and sorted the list.
Fixes: #11088
* Add a way to mark Conversation (code comment) resolved
mark Conversation is a way to mark a Conversation is stale
or be solved. when it's marked as stale, will be hided like
stale. all Pull Request writer , Offical Reviewers and poster
can add or remove Conversation resolved mark.
Signed-off-by: a1012112796 <[email protected]>
* fix lint
* Apply suggestions from code review
* Add ResolveDoer
* fix ui
Co-Authored-By: Lauris BH <[email protected]>
Co-Authored-By: 6543 <[email protected]>
* change IsResolved to an function
Add permission check in UpdateResolveConversation
* Apply suggestions from code review
* change return error for permisson check
* add default message for deleted user
* get issue message from comment
* add migration for ``ResolveDoerID`` column
another change:
* block mark pending review as resolved because it's not necessary
Co-authored-by: guillep2k <[email protected]>
* change button color
* resolve button size
* fix code style
* remove unusefull code
Co-authored-by: guillep2k <[email protected]>
Co-authored-by: Lauris BH <[email protected]>
Co-authored-by: 6543 <[email protected]>
Co-authored-by: guillep2k <[email protected]>
* Fix InsertReleases Nil Insert on Attachments
* FIX "No element on slice when insert" & smal refactor
* again
* impruve
* rm useles newline
* Apply suggestions from code review
Co-Authored-By: zeripath <[email protected]>
* process insert as a whole
Co-authored-by: zeripath <[email protected]>
* Cache PullRequest Divergence
* only re-calc divergence if AddTestPullRequestTask() is exec
* migrate already open pulls
* finalize
* take care of closed¬-merged+deleted-branch pull requests
* fix nil pointer exeption
Signed-off-by: 6543 <[email protected]>
* try this
* no error its a warn
* init gitea-repositories-meta
* dont use gitDivergence type
* CI.restart()
* CI.restart()
* CI.restart()
* CI.restart()
* check IsUserAllowedToUpdate independend from CommitsBehind
* make sure duplicate token names cannot be used
* add check to api routes too
* add @lunny s suggestion
* fix & don't forget User.ID
* AccessTokenByNameExists() return error too
* unique token for each test
* fix lint
Signed-off-by: 6543 <[email protected]>
Co-authored-by: Lanre Adelowo <[email protected]>
* fix some bug about Request review
* fix ``CreateComment`` wrong using ,it will not work when use Sqlite
* fix wrong js click event code , it will send wrong data when it has
many choices
Signed-off-by: a1012112796 <[email protected]>
* Apply suggestions from code review
Co-Authored-By: Lauris BH <[email protected]>
* add getReviewerByIssueIDAndUserID
fix wrong conditions check in initIssueComments after #10972
* call CI again
Co-authored-by: Lauris BH <[email protected]>
Co-authored-by: techknowlogick <[email protected]>
Co-authored-by: guillep2k <[email protected]>
* Update header.tmpl
* Update _repository.less
* Update pull.go
* Update indexer.go
* Update pull.go
* Update pull.go
* Update indexer.go
* fix forked repo doesn't have language stat
* fix forked repo doesn't have language stat
* fix forked repo doesn't have language stat
* fix forked repo doesn't have language stat
* fix forked repo doesn't have language stat
* fix forked repo doesn't have language stat
* fix forked repo doesn't have language stat
* fix forked repo doesn't have language stat
* fix forked repo doesn't have language stat
* fix forked repo doesn't have language stat
* fix forked repo doesn't have language stat
Thanks the advice from lunny and 6543.
* fix forked repo doesn't have language stat
Modified as suggested by 6543.
* fix forked repo doesn't have language stat
simplify the function.
* fix forked repo doesn't have language stat
update the indexer after the loop
Co-authored-by: techknowlogick <[email protected]>
Co-authored-by: Lauris BH <[email protected]>
* remove a user from being assigned to any issue/PR if (s)he is removed as a collaborator
* fix gender specific comment
* do not remove users that still have access to the repo if they are a member of a team that can access the repo
* add context to errors
* updates
* incorporate review fixes
* Update models/repo_collaboration.go
Co-Authored-By: 6543 <[email protected]>
* Update models/repo_collaboration.go
Co-Authored-By: 6543 <[email protected]>
* Fix Rebase Relict
* Fix & Impruve
* use xorm builder
* all in one session
* generalize reconsiderIssueAssignees
* Only Unwatch if have no access anymore
* prepare for reuse
* Same things if remove User from Team
* fix lint
* let mysql take time to react
* add description
* CI.restart()
* CI.restart()
Co-authored-by: Lanre Adelowo <[email protected]>
Co-authored-by: techknowlogick <[email protected]>
Co-authored-by: Lauris BH <[email protected]>
* add request review feature in pull request
add a way to notify specific reviewers to review like github , by add or delet a special type
review . The acton is is similar to Assign , so many code reuse the function and items of
Assignee, but the meaning and result is different.
The Permission style is is similar to github, that only writer can add a review request from Reviewers,
but the poster can recall and remove a review request after a reviwer has revied even if he don't have
Write Premission. only manager , the poster and reviewer of a request review can remove it.
The reviewers can be requested to review contain all readers for private repo , for public, contain
all writers and watchers.
The offical Review Request will block merge if Reject can block it.
an other change: add ui otify for Assignees.
Co-authored-by: guillep2k <[email protected]>
Co-authored-by: Lauris BH <[email protected]>
Signed-off-by: a1012112796 <[email protected]>
* new change
* add placeholder string
* do some changes follow #10238 to add review requests num on lists also
change icon for review requests to eye
Co-authored-by: Lauris BH <[email protected]>