Gitlab hero border pattern left svg Gitlab hero border pattern right svg

Searching The GitLab Website like a pro

Challenge

At GitLab, we're prolific at documenting what we do in the handbook, the website, and in GitLab documentation. This may make it difficult to find specific pieces of content.

Basic solution — "search site:"

Google already indexes all our public facing pages and there is a search modifier Google offers that will help.

Search for a specific site
Put "site:" in front of a site or domain. For example, site:youtube.com.

If you are looking for information on the GitLab "team", then simply type this into the Google search:

team site:about.gitlab.com

The Google search results will be only from about.gitlab.com.

Similarly, if you're looking for "permissions" in GitLab product documentation, then simply type this into search:

permissions site:docs.gitlab.com

The Google search results will be only be documentation from docs.gitlab.com.

This also works for specific subdirectories. For example, if you only want to search in the handbook for "values" you can type

site:about.gitlab.com/handbook/values

Advanced solution

The site: technique is incredibly powerful. But, if you use it often, you end up typing the URL all the time — not very efficient. If you use Chrome, there is a simple trick to use Chrome's search engine configuration to eliminate having to type site:about.gitlab.com every time. You only have to type 3 characters. Here's how.

NOTE: If you are using Firefox, you can use the "Add custom search engine extension" to do this. Instructions below.

First: Configure a new Search Engine shortcut in Chrome

Step Image
1. Right click on the URL field in Chrome and select "Edit Search Engines Edit search engine
2. In the Dialog, click Add Add search engine
3. There are THREE fields in the Edit search engine dialog.
a. In the Search Engine field Enter GitLab
b. In the Keyword field, enter gl
c. In the URL field enter http://www.google.com/search?q=%s%20site:about.gitlab.com
d. Click Save.
Enter search engine details

Then Go to a new Chrome tab and test it.

Step Image
1. In the Chrome URL/search field type gl Use Keyword to search
2. AND then press space. Notice how the field changes to indicate the selected search engine. Press space key
3. Now, your new GitLab search engine will search using the site:about.gitlab.com modifier. Search results from Gitlab

What about GitLab documentation?

Simple. Create another search engine.

Search GitLab Documentation Image
1. In the Edit search engine dialog.
2. In the Search Engine field Enter GitLab docs
3. In the Keyword field, enter gd
4. In the URL field enter
http://www.google.com/search?q=%s%20site:docs.gitlab.com
Settings for docs.gitlab.com

What about finding GitLab Issues?

Yep, create another search engine shortcut — this one will search for Issues in gitlab.com

Search GitLab Issues Image
1. In the Edit search engine dialog.
2. In the Search Engine field Enter GitLab.com issues
3. In the Keyword field, enter gg
4. In the URL field enter
https://gitlab.com/search?search=%s&project_id=&group_id=6543&scope=issues (Note this restricts the search to the gitlab.com group)
Settings for docs.gitlab.com

What about finding files in Google Docs?

You guessed it. Simply create another search engine shortcut — this one will search for documents in Google Docs

Search Google Docs Image
1. In the Edit search engine dialog.
2. In the Search Engine field Enter Google Drive
3. In the Keyword field, enter dv
4. In the URL field enter
https://drive.google.com/drive/search?q=%s
Settings for docs.gitlab.com

Other advanced search configurations

Below you will find a few more examples of search engine shortcuts you may find useful. These examples are using the domain gitlab.com and the gitlab-org project. These values can be modified to work on your instance URL.

Search dotcom-internal issues

Search Engine dotcom-internal issues
Keyword ggi
Url https://gitlab.com/gitlab-com/support/dotcom/dotcom-internal/issues?scope=all&utf8=%E2%9C%93&state=all&search=%s
Usage ggi keyword/s

Search open merge requests by author

Search Engine MR Author
Keyword mr
Url https://gitlab.com/dashboard/merge_requests?scope=all&utf8=%E2%9C%93&state=opened&author_username=%s
Usage mr username

Search open issues by author

Search Engine Issue Author
Keyword author
Url https://gitlab.com/dashboard/issues?scope=all&utf8=%E2%9C%93&state=opened&author_username=%s
Usage author username
Search Engine GitLab Epic
Keyword epic
Url https://gitlab.com/groups/gitlab-org/-/epics/%s
Usage epic 954
Search Engine GitLab Issue
Keyword Issue
Url https://gitlab.com/gitlab-org/gitlab/issues/%s
Usage issue 31034

Firefox -

Firefox Bookmarks

In Firefox, it is possible to have the same functionality. The only challenge is in getting to the Firefox settings where you can setup the keywords for searching.

Firefox Setup View
The settings are controlled from the Firefox Bookmark Menu Firefox Searching
1. Click on the Library Menu icon Firefox Searching
2. Click on Show all Bookmarks at the bottom Firefox Searching
3. Select the Bookmarks Menu item Firefox Searching
4. This is where your search shortcuts live Firefox Searching
5. To ADD a new shortcut - Click on the Gear icon and select New Bookmark Firefox Searching
7. Give your bookmark/search shortcut a name (any name will do) Firefox Searching
8. Fill in the details with the URL in the Location field and keyword shortcut in the keyword field Firefox Searching
9. Use your shortcut, in this case "gg" and a space Firefox Searching
Which took me here Firefox Searching

Firefox Import Custom searches

We can import most of the custom and advanced search we have seen here by doing a direct import, this way we won't have to manually each each one of them.

To do this first we will need the file with the custom search as bookmarks, you can download it from here, download that file, and we will use it to load the bookmarks.

With the file download from the previous tip, complete step 2 and continue with the following steps.

Step Image
Click on the import bookmarks from HTML. Firefox Import Bookmark

When the file selection dialog open select the file you downloaded earlier and import it to add the following custom search

Search Keyword Description
GitLab Handbook gl Handbook search
GitLab Documentation gd GitLab documentation [ docs.gitlab.com]
Issues by author author Search for issues open by given author (username) in all projects
Merge Requests by author mr Search for merge requests by given author (username) in all projects
Google Drive search dv Simple google drive search

Similarly to the Chrome instructions above, you can add a custom search engine into Firefox to allow you to search the handbook (or issues etc) from the address bar.

First: Install the "Add custom search engine extension".

Second: Configure a new Search Engine shortcut in Firefox

Step Image
1. Click the addon icon in the toolbar or click "Preferences" from the addon manager Add custom search engine extension
2. Enter the details for your new search engine
a. Enter a useful name
b. For the Search URL field, enter http://www.google.com/search?q=%s%20site:about.gitlab.com
c. For the Icon field, you can use the GitLab favicon: https://about.gitlab.com/ico/favicon.ico
Search engine form
3. Click Add custom search engine  
4. Optionally, configure a keyword shortcut by editing the list in about:preferences#search  

Then: Go to a new tab, and you will now see an icon for your new search engine at the bottom of the suggestions bar when you enter text in the address bar.

Using Alfred on macOS

Alfred for macOS

Using Alfred and Firefox

GitLab team member Simon M. recorded the video above to walk through the process of searching GitLab like a pro using Alfred (a productivity application for macOS) and the Firefox web browser.

Import these custom searches to Alfred

You can click on each of these URLs and Alfred will ask if you want to import them to your custom searches. Add custom search to Alfred

Keyword
gl
gd
gg
mr
author
issue

Add the GitLab icon

You can drag and drop the favicon favicon to the Alfred custom search