Commit Graph
100 Commits
Author SHA1 Message Date
Valery Sizov 94af78ac4a Faster snippet search 2016-02-05 18:20:29 +02:00
Dmitriy Zaporozhets 406c912496 Merge branch 'fix-error-500-mr-search' into 'master'
Fix Error 500 when doing a search for merge requests

Potential fix for #11547

See merge request !2525
2016-01-22 18:14:10 +00:00
Douwe Maan 21facf5353 Use consistent markup and styling for highlighting across blobs, diffs, blame and snippets 2016-01-21 14:23:53 +01:00
Stan Hu f121d2d8f8 Fix Error 500 when doing a search for merge requests
Potential fix for #11547
2016-01-20 23:48:56 -08:00
Dmitriy Zaporozhets 3238b0bc9f Replace nav-tabs with nav-links
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2016-01-13 17:13:36 +01:00
Stan Hu 4949f40ac4 Fix Error 500 when doing a search in dashboard before visiting any project
If a search turned up an issue, under certain conditions you would see this error:

```
ActionView::Template::Error (undefined method `path_with_namespace' for nil:NilClass):
     6:   - if issue.description.present?
     7:     .description.term
     8:       = preserve do
     9:         = search_md_sanitize(markdown(issue.description))
    10:   %span.light
    11:     #{issue.project.name_with_namespace}
    12:   - if issue.closed?
  lib/gitlab/markdown/upload_link_filter.rb:36:in `build_url'
  lib/gitlab/markdown/upload_link_filter.rb:31:in `process_link_attr'
  lib/gitlab/markdown/upload_link_filter.rb:18:in `block in call'
  lib/gitlab/markdown/upload_link_filter.rb:17:in `call'
  lib/gitlab/markdown.rb:127:in `gfm'
  lib/gitlab/markdown.rb:24:in `render'
  app/helpers/gitlab_markdown_helper.rb:61:in `markdown'
  app/views/search/results/_issue.html.haml:9:in `block in _app_views_search_results__issue_html_haml__4127460390996300432_59973760'
  app/views/search/results/_issue.html.haml:8:in `_app_views_search_results__issue_html_haml__4127460390996300432_59973760'
  app/views/search/_results.html.haml:20:in `_app_views_search__results_html_haml__589475855773452465_61761440'
  app/views/search/show.html.haml:5:in `_app_views_search_show_html_haml___1852335078065998536_69780120'
```
2015-12-22 11:13:09 -08:00
Dmitriy Zaporozhets d23ffc832c Fix code that depends on incorrect inflector behavior
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-11-03 12:00:27 +01:00
Dmitriy Zaporozhets 810c91fe35 Refactor search by commits message
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-11-02 16:39:24 +01:00
Jonathan SchoefflingandMichael Chmielewski 5a5069969c Add support for searching commit log messages
Include the log messages of recent commits in project-level search
results, providing functionality similar to 'git log --grep'.

Update repository model rspec tests to validate the output of
Repository#commits_with_log_matching.
2015-10-28 22:34:39 -04:00
Valery Sizov d805c5dbb3 Add spellcheck=false to certain input fields 2015-10-12 12:54:54 +03:00
Douwe Maan 30555c1d24 Merge branch 'rs-remove-user-color-scheme-class' into 'master'
Apply syntax highlighting to fenced code blocks client-side

Instead of applying the syntax highlighting scheme class to these blocks
server-side, we use Javascript and Gon to apply the user's color scheme
(or the default) client-side.

This will make it easier to cache these blocks in the future because
they're no longer state-dependent.

See merge request !1203
2015-08-27 16:24:51 +00:00
Dmitriy Zaporozhets e06fe6b7e1 Make search bar on search page more noticeable
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-08-27 00:50:17 +02:00
Dmitriy Zaporozhets dcdf214fd1 More compact search page
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-08-27 00:22:36 +02:00
Dmitriy Zaporozhets b54358b457 Refactor project list rendering
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-08-26 22:44:02 +02:00
Robert Speicher ce0a0feff4 Make snippet_blob highlight server-side as well 2015-08-26 11:43:25 -07:00
Robert Speicher 2c3e42e4a4 Remove user_color_scheme_class
Instead of rendering this value server-side, we use Javascript and Gon
to apply the user's color scheme (or the default) to any syntax
highlighted code blocks.

This will make it easier to cache these blocks in the future because
they're no longer state-dependent.
2015-08-25 15:32:38 -07:00
Valery Sizov 56527b63e8 Ability to search milestones 2015-08-24 13:59:01 +03:00
Dmitriy Zaporozhets 9ab12e099d Fix search blobs for wiki
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-07-12 14:01:06 +02:00
Dmitriy Zaporozhets f6609c9882 Implement search of code via git grep
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-07-10 17:50:50 +02:00
Dmitriy Zaporozhets 7524d7c082 Revert merge request states renaming
Replaced:
* "Accepted" with "Merged"
* "Rejected" with "Closed"

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-06-19 17:09:50 +02:00
Dmitriy Zaporozhets 8641cda4a5 Dont use fixed pixel size if form controls - its bad for mobile devices
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-06-08 16:34:58 +02:00
Douwe Maan ebe9c89082 Consistently refer to MRs as either Accepted or Rejected. 2015-05-25 17:01:14 +02:00
Jakub Jirutka b0659c1b07 Simplify and unify helpers for rendering markup 2015-05-18 22:52:13 +02:00
Douwe Maan 26ad250989 Add a page title to every page. 2015-04-30 19:12:15 +02:00
Dmitriy Zaporozhets 24037e7e63 Move search categories (projects, issues etc) below search field. Instead use sidebar for dashbaord nav
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-04-29 12:19:54 +03:00
Dmitriy Zaporozhets 1ff01d26e1 Continue refactoring and restyle of search layout
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-04-28 22:04:19 +03:00
Dmitriy Zaporozhets d5fe1e57d5 Draft improvements to search layout
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2015-04-28 12:48:42 +03:00
Dmitriy Zaporozhets 30ca451fd4 Refactor buttons 2015-03-14 00:29:32 -07:00
Dmitriy Zaporozhets 2da2720584 Improve css for file actions 2015-03-13 19:20:25 -07:00
Dmitriy Zaporozhets 519ca7bae9 Merge branch 'link-to-button' of https://github.com/cirosantilli/gitlabhq into cirosantilli-link-to-button
Conflicts:
	app/views/shared/_issuable_filter.html.haml
2015-03-02 15:28:22 -08:00
Vinnie Okada 83e2a1ca12 Update path helper references
Use the path helpers for nested project resources, for Rails 4.1.9
compatibility.
2015-02-19 21:25:28 -07:00
Vinnie Okada 76aad9b76e Upgrade to Rails 4.1.9
Make the following changes to deal with new behavior in Rails 4.1.2:

* Use nested resources to avoid slashes in arguments to path helpers.
2015-02-14 11:09:23 -07:00
Ciro Santilli 55d9809055 Convert Javascript links to buttons. 2015-01-17 19:50:41 +01:00
Stefan Tatschner bf079c24af Replace highlight.js with rouge-fork rugments
I decided to create a fork of rouge as rouge lacks a HTML formatter with
the required options such as wrapping a line with <span> tags.
Furthermore I was not really convinced about the clarity of rouge's
source code.

Rugments 1.0.0beta3 for now only includes some basic linting and a new
HTML formatter. Everything else should behave the same.
2015-01-15 13:41:11 +01:00
Dmitriy Zaporozhets 5f15ed04fc Respect current controller scope when using search from project area
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-12-02 22:38:45 +02:00
Dmitriy Zaporozhets b23b78ada1 Merge pull request #7866 from cirosantilli/input-button-to-tag
Use button type=submit instead of input.
2014-10-28 12:11:15 +02:00
Dmitriy Zaporozhets 0189be0831 Use short_id instead of [0..N] for short version of commit sha
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-10-10 15:39:48 +03:00
Sullivan SENECHAL 5d8be4438a Upgrade to Font Awesome v4.2 2014-10-03 12:19:24 +02:00
Ciro Santilli 6294033024 Use button type=submit instead of input. 2014-10-01 11:12:56 +02:00
Dmitriy Zaporozhets 0e78d00bcb Merge pull request #7695 from coverer/search_wiki
Added search wiki feature
2014-09-09 16:50:43 +03:00
Charles Bushong 858dbd0842 Updating to persist a params snippets variable 2014-09-05 13:30:55 -04:00
Ralf Seidler d93b046c4c Added search wiki feature 2014-09-05 13:36:43 +02:00
Charles Bushong b1411e90f8 Changing some formatting for the Hound, modifying some UI text 2014-09-02 08:33:23 -04:00
Charles Bushong 4cca1b050a Adding in snippet search functionality
http://feedback.gitlab.com/forums/176466-general/suggestions/5529795-search-though-snippets
2014-08-29 15:32:07 -04:00
Dmitriy Zaporozhets 1056d91c67 Improve search results output. Fixes some markup issues
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-08-28 11:06:19 +03:00
Dmitriy Zaporozhets 7f4b993793 Forgot to save file :)
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-08-27 12:54:18 +03:00
Dmitriy Zaporozhets 043f275900 Skip description if not exist
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-08-27 12:49:45 +03:00
Dmitriy Zaporozhets 8b00d01c67 Search by issue/mr title and description
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-08-27 12:47:30 +03:00
Dmitriy Zaporozhets 7e59a8fee8 Improve comment search results
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-08-27 12:37:31 +03:00
Dmitriy Zaporozhets 13f6dc1a94 Save search options when switch between filter
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-08-27 11:55:42 +03:00