Code search

Helix TeamHub supports code searching for Git repositories. The code is indexed from each repository's default branch. You can configure the default branch for each repository from the repository settings view.

Code search can be performed on the following levels:

Enabling code search

Only user with company administrator privileges can enable code search.

Note: on-premise customers will first need to setup and configure Elasticsearch to their Helix TeamHub instance. Refer to the administrator's guide on how to achieve this. If you require further assistance, please don't hesitate to contact support.

To enable code search:

  1. Access the Company Settings view using the user dropdown list in the header or from the My Dashboard tab.

    Avatar dropdown

  2. In the Features tab, turn on Code Search and click Save.

    Company settings

Once code search is enabled, TeamHub indexes all Git repositories within the company. Depending on the amount of data to process, the indexing operation might take a while. You can monitor the current progress on the My Dashboard tab. When done, the indicator on the right displays Indexing complete.

Company stats


You can begin a code search from any view. To search the code:

  1. Click the search icon in the site header.
  2. In the search field, enter your search term and press Enter.

    Search bar

    TeamHub displays the search results in a separate view.

    Search results

    By default, TeamHub displays only the matching code lines.

    Search controls

  3. To view the full search context, click the arrow icon beneath the result.

  4. To see more results, use the pagination controls at the bottom of the page.


You can narrow down search results by specifying which projects and repositories to include.

Helix TeamHub applies the following filters automatically based on the view from which you invoke the search:

You can clear these filters in the results view.

Invoking a search from the company scope does not set any filters. Instead, TeamHub searches within all projects and repositories to which you have access.

Search filters

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

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

If you have multiple repositories with the same name in several projects, you can narrow down the search using the following syntax: project:repository. For example, to search repositories starting with bat in a project called Amazing, enter the following string in the search field: amazing:bat

Searching repositories inside a project

To view a project's identifier, go to the Projects tab or move your pointer over the project name.

Updated on: 19 December 2017