Global Code Search in Deveo

Global Code Search in Deveo

We are excited to announce a brand new feature in Deveo that helps you find code across the entire company. As of Deveo 3.20, you can now enable code search per company basis.

This blog post will provide an introduction to the feature, as well as cover the basic usage of code search.

Global code search

The first iteration of code search supports searching code in Git repositories. The code is indexed from the repository's default branch. You can configure the default branch for each repository from the repository's settings view.

Code searching can be performed on several levels:

  • Company level (all repositories within the company)
  • Project level (all repositories within one or multiple projects)
  • Repository level (one or multiple repositories)

Enabling code search

Before being able to search code, you will need to enable the feature. If you are a Deveo Cloud customer, enabling code search is trivial. Simply navigate to the Company Settings view, enable the feature from the "Features" tab, and click "Save".

Company features

On-premise customers will first need to setup and configure Elasticsearch to their Deveo instance. Please refer to the administrator's guide on how to achieve this. If you need additional help, don't hesitate to email us at support@deveo.com.

Once the code search feature is enabled, the repositories will be indexed. Please note that this operation might take a while depending on the amount of data inside the company. You can see the current progress by visiting the Company Overview view. The indicator will display "Indexing complete" once everything is ready.

Company stats

Then it's time to search!

Searching

You can invoke a code search from any view by clicking on the search icon in the site header, typing in your search term and hitting enter.

Search input

The results will be listed in a separate view.

Search results

By default, only the matching code lines are displayed. To view the full context, click on the arrow icon beneath the result. You can browse results using the pagination controls at the bottom.

Search controls

Filtering

You can narrow down the results by specifying the projects and repositories to include search results from. Deveo applies some filters automatically based on the view you invoked the search from:

  • Browsing a project will set the current project as the filter
  • Browsing repository views or the project's wiki will set the repository as the filter

Invoking a search from the company scope will not set any filters. This means that code is searched from all projects and repositories.

In addition to the project and repository filters, you can define whether to include or omit results from forked repositories.

The numbers next to the filters indicate the number of results for each project and repository. Please note that by selecting a project, you are effectively searching from all repositories within that project. To restrict the search to specific repositories, remove the project filter first.

Pro-tip: bookmark the page to quickly search with the same options later on

In case you have multiple repositories with the same name in several projects, you can narrow down the search using a special syntax: project:repository.

Filtering repositories per project

In the above example, only repositories belonging to the "Amazing" project and starting with "bat" are listed. The project's identifier can be seen from the "Projects" tab, or by hovering over the project's name.

More to come

This was only the first iteration of the search feature. In the future, we have plans to add support for defining more fine-grained filters, as well as being able to search anything in Deveo - enabling a universal global search.

Conclusion

We hope you enjoy the new code search feature! Let us know about any related features or improvements you'd like to see implemented by commenting below, or by sharing your idea on http://support.deveo.com. You can also always drop us an email at support@deveo.com.

Seamless software development.

Code management and collaboration platform with Git, Subversion, and Mercurial.

Sign up for free
comments powered by Disqus