Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions docs/admin/webhooks/incoming.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -249,17 +249,17 @@ Done! Sourcegraph will now receive webhook events to sync data with lower latenc

1. On Azure DevOps, go to each project, and then **Project settings > General > Service hooks**.
2. Click **Create subscription**.
![](https://storage.googleapis.com/sourcegraph-assets/docs/images/admin/config/webhook-step-2.png)
![Azure DevOps Create subscription button](https://storage.googleapis.com/sourcegraph-assets/docs/images/admin/config/webhook-step-2.png)
3. Select **Web Hooks** and click **Next** .
![](https://storage.googleapis.com/sourcegraph-assets/docs/images/admin/config/webhook-step-3.png)
![Azure DevOps Web Hooks selection](https://storage.googleapis.com/sourcegraph-assets/docs/images/admin/config/webhook-step-3.png)
4. From the **Trigger on this type of event** drop-down, choose:
- **For repo changes**:
- _Not supported_
- **For Batch Changes**:
- `Pull request updated`
- **For repository permissions**:
- _Not supported_
![](https://storage.googleapis.com/sourcegraph-assets/docs/images/admin/config/webhook-step-4.png)
![Azure DevOps event type selection](https://storage.googleapis.com/sourcegraph-assets/docs/images/admin/config/webhook-step-4.png)
5. Set the filters how you like, or leave them at the default: **[Any]** and click **Next**.
6. Fill in the webhook form:
- **URL**: The URL found after creating an incoming webhook.
Expand Down
2 changes: 1 addition & 1 deletion docs/batch-changes/design.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Kubernetes is a distributed system with an API that many people are familiar wit
| | **[Kubernetes Deployment](https://kubernetes.io/docs/concepts/workloads/controllers/deployment/)** | **Sourcegraph Batch Changes** |
| ------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| What underlying thing does this API manage? | Pods running on many (possibly unreliable) nodes | Branches and changesets on many repositories that can be rate-limited and externally modified (and our authorization can change) |
| Spec YAML | ![](https://storage.googleapis.com/sourcegraph-assets/Docs/batch-changes-code-kub.png) | ![](https://storage.googleapis.com/sourcegraph-assets/Docs/sg-batch-changes.png) |
| Spec YAML | ![Kubernetes Deployment spec YAML](https://storage.googleapis.com/sourcegraph-assets/Docs/batch-changes-code-kub.png) | ![Sourcegraph Batch Changes spec YAML](https://storage.googleapis.com/sourcegraph-assets/Docs/sg-batch-changes.png) |
| How desired state is computed | <ul><li>Evaluate `replicas`, etc. to determine pod count and other template inputs</li><li>Instantiate `template` once for each pod to produce PodSpecs</li></ul> | <ul><li>Evaluate `on`, `steps` to determine list of patches</li><li>Instantiate `changesetTemplate` once for each patch to produce ChangesetSpecs</li></ul> |
| Desired state consists of... | <ul><li>DeploymentSpec file (the YAML above)</li><li>List of PodSpecs (template instantiations)</li></ul> | <ul><li>batch spec file (the YAML above)</li><li>List of ChangesetSpecs (template instantiations)</li></ul> |
| Where is the desired state computed? | The deployment controller (part of the Kubernetes cluster) consults the DeploymentSpec and continuously computes the desired state. | <ul><li>The [Sourcegraph CLI](https://github.com/sourcegraph/src-cli) (running on your local machine, not on the Sourcegraph server) consults the batch spec and computes the desired state when you invoke `src batch apply`.</li><li>**Difference vs. Kubernetes**: A batch change's desired state is computed locally, not on the server. It requires executing arbitrary commands, which is not yet supported by the Sourcegraph server.</li></ul> |
Expand Down
2 changes: 1 addition & 1 deletion docs/code-insights/language-insight-quickstart.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ In this guide, you'll create a Sourcegraph language code insight that shows the

For more information about Code Insights see the [Code Insights](/code-insights/) documentation.

![](https://sourcegraphstatic.com/docs/images/code_insights/language_quickstart_insight_dark.png)
![Language usage pie chart showing code distribution](https://sourcegraphstatic.com/docs/images/code_insights/language_quickstart_insight_dark.png)

### 1. Visit your Sourcegraph instance /Insights page and select "+ Create new insight"

Expand Down
2 changes: 1 addition & 1 deletion docs/code-insights/quickstart.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ In this guide, you'll create a Sourcegraph code insight that tracks the number o

For more information about Code Insights see the [Code Insights](/code-insights/) documentation.

![](https://sourcegraphstatic.com/docs/images/code_insights/quickstart_TODOs_insight_dark.png)
![Code insight tracking TODOs count over time](https://sourcegraphstatic.com/docs/images/code_insights/quickstart_TODOs_insight_dark.png)

## Requirements

Expand Down
6 changes: 3 additions & 3 deletions docs/cody/clients/install-vscode.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,11 @@ Sourcegraph Enterprise users should connect Cody to their Enterprise instance by

You'll be prompted to choose how to sign-in, Enter the URL of your Enterprise instance. If you are unsure, please contact your administrator.

![](https://storage.googleapis.com/sourcegraph-assets/Docs/vscode-cody-enterprise-login.png)
![VS Code Cody extension enterprise login prompt](https://storage.googleapis.com/sourcegraph-assets/Docs/vscode-cody-enterprise-login.png)

A pop-up will ask if you want to Open the URL in a new window. Click **Open** to open the URL in a new window. Next, sign in to your instance. If you do not yet have a login, please contact your administrator.

![](https://storage.googleapis.com/sourcegraph-assets/Docs/sign-in-to-sourcegraph-2025.jpg)
![Sign in to Sourcegraph instance page](https://storage.googleapis.com/sourcegraph-assets/Docs/sign-in-to-sourcegraph-2025.jpg)

Create an access token from Account Settings - Access Tokens. Click **+ Generate new token**

Expand All @@ -69,7 +69,7 @@ Copy the token and return to VS Code.

Again, click **Sign In to Your Enterprise Instance** and choose **Sign In to Sourcegraph Instances v5.1 and above**. Enter the URL of your instance.

You should now be prompted to authorize Sourcegraph to connect to your VS Code extension using the token you created. Click **Authorize**. Finally, you will be asked to allow the extension access. CLick **Open**. VS Code should now display the Cody panel and you're ready to go.
You should now be prompted to authorize Sourcegraph to connect to your VS Code extension using the token you created. Click **Authorize**. Finally, you will be asked to allow the extension access. Click **Open**. VS Code should now display the Cody panel and you're ready to go.

## Verifying the installation

Expand Down
10 changes: 5 additions & 5 deletions docs/cody/troubleshooting.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ If you're experiencing issues with Cody's responses or completions being too slo

- Ensure you have the latest version of the [Cody VS Code extension](https://marketplace.visualstudio.com/items?itemName=sourcegraph.cody-ai). Use the VS Code command `Extensions: Check for Extension Updates` to verify
- Enable verbose logging, restart the extension and reproduce the issue seen again (see below `Access Cody logs` for how to do this)
- Send information to the our Support Team at support@sourcegraph.com
- Send information to our Support Team at support@sourcegraph.com

Some additional information that will be valuable:

Expand Down Expand Up @@ -155,19 +155,19 @@ Note that you may need to quit VSCode first, then run that command to re-launch

- After VS Code is started, head over to Chrome and go to `chrome://inspect`, which takes you to the following:

![](https://gist.github.com/assets/458591/0a17881b-5449-48d5-a53e-5556f4f2dedd)
![Chrome inspect page showing DevTools for Node](https://gist.github.com/assets/458591/0a17881b-5449-48d5-a53e-5556f4f2dedd)

- Configure the inspect server you started on port `9333` from here. To do so, click on **Open dedicated DevTools for Node**, then go to the **Connection** tab, and make sure to add `localhost:9333` to the list

![](https://gist.github.com/assets/458591/972ce113-88f0-482a-99b7-5e51957981ef)
![DevTools Connection tab with localhost:9333 configured](https://gist.github.com/assets/458591/972ce113-88f0-482a-99b7-5e51957981ef)

- Now head back to the `chrome://inspect` tab, and you should see a new remote target that you can inspect

![](https://gist.github.com/assets/458591/06b2e293-aea7-42e8-a9cc-592863b6fb07)
![Remote target appearing in chrome://inspect](https://gist.github.com/assets/458591/06b2e293-aea7-42e8-a9cc-592863b6fb07)

- Clicking this will open a (somewhat reduced) DevTools view. Great! We've almost got it. From here you can go to the **Performance** tab to record a trace. And finally, swap tabs to the VS Code window and interact with the extension. Come back later to stop the recording and export it.

![](https://gist.github.com/assets/458591/d590636b-31e5-4436-8039-ee62b7a8e59f)
![DevTools Performance tab for recording traces](https://gist.github.com/assets/458591/d590636b-31e5-4436-8039-ee62b7a8e59f)

### Record a CPU profile for Cody in VSCode

Expand Down
8 changes: 4 additions & 4 deletions docs/cody/use-cases/vsc-tutorial.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ This tutorial gives you a quick walkthrough of leveraging Cody for autocompletio

## Code Autocomplete

![](https://storage.googleapis.com/sourcegraph-assets/blog/vs-code-onboarding-walkthrough-dec-2023-cody-autocomplete-tsx.gif)
![Cody autocomplete suggesting code in a TSX file](https://storage.googleapis.com/sourcegraph-assets/blog/vs-code-onboarding-walkthrough-dec-2023-cody-autocomplete-tsx.gif)

Start writing code and Cody will complete the line (or the entire function) for you. Press **Tab** to accept the suggestion.

Expand All @@ -16,7 +16,7 @@ Start writing code and Cody will complete the line (or the entire function) for

## Chat

![](https://storage.googleapis.com/sourcegraph-assets/blog/blog-vscode-v018-release/blog-v018-context-controls-002.gif)
![Cody chat with context controls for files and symbols](https://storage.googleapis.com/sourcegraph-assets/blog/blog-vscode-v018-release/blog-v018-context-controls-002.gif)

Answer questions about general programming topics, or specific to your codebase, with Cody chat. You can choose between LLMs, @-mentions files and symbols, and enable enhanced repository-wide code context.

Expand All @@ -29,7 +29,7 @@ You can start a chat at any time using the default keyboard shortcut of `Opt+L`/

## Cody Commands

![](https://storage.googleapis.com/sourcegraph-assets/blog/vs-code-onboarding-walkthrough-dec-2023-explain.gif)
![Using Cody Explain Code command on selected code](https://storage.googleapis.com/sourcegraph-assets/blog/vs-code-onboarding-walkthrough-dec-2023-explain.gif)

Cody has a range of commands for explaining code, generating unit tests, adding documentation, and more.

Expand Down Expand Up @@ -77,7 +77,7 @@ You can also run this command from the [Cody: Commands Menu](command:cody.menu.c

## Fix Code

![](https://storage.googleapis.com/sourcegraph-assets/blog/vs-code-onboarding-walkthrough-dec-2023-ask-to-fix.gif)
![Using Cody Ask to Fix command on code with errors](https://storage.googleapis.com/sourcegraph-assets/blog/vs-code-onboarding-walkthrough-dec-2023-ask-to-fix.gif)

Something wrong with your code? Use Cody’s "Ask Cody to Fix" command to fix it, or explain the problem.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

You can add Sourcegraph as a browser search engine to quickly search Sourcegraph from your browser's location bar when you type a special shortcut, such as `src`. This is one of the most common ways to initiate a search on Sourcegraph.

![](https://sourcegraphstatic.com/SearchShortcut2.gif)
![Using browser search shortcut to search Sourcegraph](https://sourcegraphstatic.com/SearchShortcut2.gif)

---

Expand All @@ -18,18 +18,18 @@ The easiest way is to install the [Sourcegraph browser extension](/integration/b
1. Copy the URL of the search results page.
1. Go to `chrome://settings`. Under **Search engine**, click **Manage search engines**. Next to **Other search engines**, click **ADD**.

![](https://storage.googleapis.com/sourcegraph-assets/Docs/AddButton.png)
![Chrome settings Add button for search engines](https://storage.googleapis.com/sourcegraph-assets/Docs/AddButton.png)

1. In the **Add search engine** form, paste the URL you copied (in step 1) in the **URL with %s in place of query** field. Insert the string `%s` into the URL's `?q=` query parameter (and remove any parts of the query that you don't want to keep).
2. Fill in the keyword field with the keyboard shortcut you want for searching on Sourcegraph. In this example, it's set to <kbd>s</kbd>.

![](https://storage.googleapis.com/sourcegraph-assets/Docs/Replace.png)
![Chrome Add search engine form with URL configuration](https://storage.googleapis.com/sourcegraph-assets/Docs/Replace.png)

5.Click **ADD**.
5. Click **ADD**.

To use the shortcut, focus in the browser address bar, type in the keyword you chose (such as <kbd>src</kbd>), and press <kbd>Tab</kbd>. Now type your Sourcegraph code search query and hit enter. You'll be taken to the search results page on your Sourcegraph instance.

![](https://storage.googleapis.com/sourcegraph-assets/Docs/KeyboardShortcut.png)
![Using keyboard shortcut in browser address bar](https://storage.googleapis.com/sourcegraph-assets/Docs/KeyboardShortcut.png)

For more information on setting Chrome search engines, [see Chrome's help page](https://support.google.com/chrome/answer/95426?co=GENIE.Platform%3DDesktop&hl=en).

Expand Down
6 changes: 3 additions & 3 deletions docs/self-hosted/deploy/docker-compose/digitalocean.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ This guide will take you through how to deploy a Sourcegraph instance to a singl

1. Select **Ubuntu 18.04** under _Distributions_

![](https://user-images.githubusercontent.com/68532117/188502550-bbab20a0-df2d-4e45-a484-628e022505c9.png)
![DigitalOcean Ubuntu image selection](https://user-images.githubusercontent.com/68532117/188502550-bbab20a0-df2d-4e45-a484-628e022505c9.png)

#### Choose a plan

Expand All @@ -29,14 +29,14 @@ This guide will take you through how to deploy a Sourcegraph instance to a singl

3. Under **Choose configuration options**, select "Manually Format and Mount"

![](https://user-images.githubusercontent.com/68532117/188502606-66bc1301-edbb-493d-b64d-f4a3e6dd0487.png)
![DigitalOcean block storage configuration](https://user-images.githubusercontent.com/68532117/188502606-66bc1301-edbb-493d-b64d-f4a3e6dd0487.png)

#### Authentication

1. <span class="badge badge-note">RECOMMENDED</span> Select **SSH keys** to create
a **New SSH Key** for convenient access to the droplet

![](https://user-images.githubusercontent.com/68532117/188502682-37667333-75d0-4bd9-8fa8-3b92924c9755.png)
![DigitalOcean SSH key authentication setup](https://user-images.githubusercontent.com/68532117/188502682-37667333-75d0-4bd9-8fa8-3b92924c9755.png)

#### Authentication > Enable backups

Expand Down
6 changes: 3 additions & 3 deletions docs/self-hosted/deploy/kubernetes/troubleshoot.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -110,13 +110,13 @@ Known issues when using a service mesh (e.g. Istio, Linkerd, etc.)

#### Error message: `Git command [git rev-parse HEAD] failed (stderr: ""): strconv.Atoi: parsing "": invalid syntax`

![](https://user-images.githubusercontent.com/68532117/178506378-3d047bc5-d672-487a-920f-8f228ae5cb27.png)
![Git command error in service mesh environment](https://user-images.githubusercontent.com/68532117/178506378-3d047bc5-d672-487a-920f-8f228ae5cb27.png)

This error occurs because Envoy, the proxy used by Istio, [drops proxied trailers for the requests made over HTTP/1.1 protocol by default](https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/core/v3/protocol.proto#config-core-v3-http1protocoloptions). To resolve this issue, enable trailers in your instance following the examples provided for [Kubernetes](https://github.com/sourcegraph/deploy-sourcegraph/tree/master/overlays) and [Kubernetes with Helm](https://github.com/sourcegraph/deploy-sourcegraph-helm/tree/main/charts/sourcegraph/examples).

#### Symbols sidebar and hovers are not working

![](https://user-images.githubusercontent.com/68532117/212372086-4c53e817-be3d-46b6-9cc1-fc34e695d30c.png)
![Symbols sidebar not working error](https://user-images.githubusercontent.com/68532117/212372086-4c53e817-be3d-46b6-9cc1-fc34e695d30c.png)

In a service mesh like Istio, communication between services is secured using a feature called mutual Transport Layer Security (mTLS). mTLS relies on services communicating with each other using DNS names, rather than IP addresses, to identify the specific services or pods that the communication is intended for.

Expand Down Expand Up @@ -151,7 +151,7 @@ SEARCHER_URL=http:searcher:3184

#### Squirrel.LocalCodeIntel http status 502

![](https://user-images.githubusercontent.com/68532117/212374098-dc2dfe69-4d26-4f5e-a78b-37a53c19ef22.png)
![Squirrel LocalCodeIntel 502 error](https://user-images.githubusercontent.com/68532117/212374098-dc2dfe69-4d26-4f5e-a78b-37a53c19ef22.png)
The issue described is related to the Code Intel hover feature, where it may get
stuck in a loading state or return a 502 error with the message `Squirrel.LocalCodeIntel
http status 502`. This is caused by the same issue described in [Symbols sidebar
Expand Down
Loading