Skip to content

Add checkbox to search for all the branches by commit message #813

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 5, 2017

Conversation

gzsombor
Copy link
Contributor

@gzsombor gzsombor commented Feb 1, 2017

This patch adds the ability to search for all the commits containing the entered text in their commit message, not only in the current branch

Copy link
Contributor

@andreynering andreynering left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's working, but need few changes.

@@ -513,6 +513,7 @@ editor.upload_files_to_dir = Upload files to '%s'

commits.commits = Commits
commits.search = Search commits
commits.searchAll = All
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use snake_case:

searchAll -> search_all

func (c *Commit) SearchCommits(keyword string) (*list.List, error) {
return c.repo.searchCommits(c.ID, keyword)
func (c *Commit) SearchCommits(keyword string, all bool) (*list.List, error) {
return c.repo.searchCommits(c.ID, keyword, all)
Copy link
Contributor

@andreynering andreynering Feb 4, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should not change this package directly in the vendor folder.

You should send PR to https://github.com/go-gitea/git first, and after aproved use govendor to update the changes here.

@@ -6,6 +6,7 @@
<div class="ui tiny search input">
<input name="q" placeholder="{{.i18n.Tr "repo.commits.search"}}" value="{{.Keyword}}" autofocus>
</div>
<input type="checkbox" name="all" id="all" value="true" {{.All}}><label for="all">{{.i18n.Tr "repo.commits.searchAll"}}</label>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here, too:

searchAll -> search_all

@andreynering andreynering added the type/feature Completely new functionality. Can only be merged if feature freeze is not active. label Feb 4, 2017
@andreynering andreynering added this to the 1.x.x milestone Feb 4, 2017
@gzsombor
Copy link
Contributor Author

gzsombor commented Feb 5, 2017

Hope, I've done it correctly, I've never used go before :)

@tboerger tboerger added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Feb 5, 2017
@appleboy
Copy link
Member

appleboy commented Feb 5, 2017

LGTM

@tboerger tboerger added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Feb 5, 2017
@lunny
Copy link
Member

lunny commented Feb 5, 2017

@andreynering please confirm.

@andreynering
Copy link
Contributor

@lunny Approved

@gzsombor Thank you for your PRs and fast changes.

@lunny
Copy link
Member

lunny commented Feb 5, 2017

@andreynering then change this to v1.1 or wait to v1.2?

@andreynering
Copy link
Contributor

@lunny I think this change is simple enough and can be merged now.

@andreynering
Copy link
Contributor

LGTM

@tboerger tboerger added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Feb 5, 2017
@lunny lunny modified the milestones: 1.1.0, 1.x.x Feb 5, 2017
@lunny lunny merged commit e388db3 into go-gitea:master Feb 5, 2017
@go-gitea go-gitea locked and limited conversation to collaborators Nov 23, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. type/feature Completely new functionality. Can only be merged if feature freeze is not active.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants