|
2 | 2 | >[!NOTE] |
3 | 3 | > Building from source is only required if you'd like to contribute. The recommended way to use Sourcebot is to use the [pre-built docker image](https://github.com/sourcebot-dev/sourcebot/pkgs/container/sourcebot). |
4 | 4 |
|
5 | | -1. Install <a href="https://go.dev/doc/install"><img src="https://go.dev/favicon.ico" width="16" height="16"> go</a>, and <a href="https://nodejs.org/"><img src="https://nodejs.org/favicon.ico" width="16" height="16"> NodeJS</a>. Note that a NodeJS version of at least `21.1.0` is required. |
| 5 | +1. Install <a href="https://go.dev/doc/install"><img src="https://go.dev/favicon.ico" width="16" height="16"> go</a>, <a href="https://docs.docker.com/get-started/get-docker/"><img src="https://www.docker.com/favicon.ico" width="16" height="16"> docker</a>, and <a href="https://nodejs.org/"><img src="https://nodejs.org/favicon.ico" width="16" height="16"> NodeJS</a>. Note that a NodeJS version of at least `21.1.0` is required. |
6 | 6 |
|
7 | 7 | 2. Install [ctags](https://github.com/universal-ctags/ctags) (required by zoekt) |
8 | 8 | ```sh |
|
13 | 13 | snap install universal-ctags |
14 | 14 | ``` |
15 | 15 |
|
16 | | -3. Install <a href="https://docs.docker.com/get-started/get-docker/"><img src="https://www.docker.com/favicon.ico" width="16" height="16"> docker</a> and start the development Docker containers for PostgreSQL and Redis. |
17 | | - |
| 16 | +3. Install `yarn`: |
18 | 17 | ```sh |
19 | | - docker compose -f docker-compose-dev.yml up -d |
| 18 | + npm install --global yarn |
20 | 19 | ``` |
21 | 20 |
|
22 | | -4. Clone the repository with submodules: |
| 21 | +3. Clone the repository with submodules: |
23 | 22 | ```sh |
24 | 23 | git clone --recurse-submodules https://github.com/sourcebot-dev/sourcebot.git |
25 | 24 | ``` |
26 | | - |
27 | | -5. Run `make` to build zoekt and install dependencies: |
| 25 | +4. Run `make` to build zoekt and install dependencies: |
28 | 26 | ```sh |
29 | 27 | cd sourcebot |
30 | 28 | make |
31 | 29 | ``` |
32 | 30 |
|
33 | 31 | The zoekt binaries and web dependencies are placed into `bin` and `node_modules` respectively. |
34 | 32 |
|
| 33 | +5. Start the development Docker containers for PostgreSQL and Redis. |
| 34 | + |
| 35 | + ```sh |
| 36 | + docker compose -f docker-compose-dev.yml up -d |
| 37 | + ``` |
| 38 | + |
35 | 39 | 6. Create a copy of `.env.development` and name it `.env.development.local`. Update the required environment variables. |
36 | 40 |
|
37 | | -7. If you're using a declerative configuration file (the default behavior if you didn't enable auth), create a configuration file and update the `CONFIG_PATH` environment variable in your `.env.development.local` file. |
| 41 | +7. If you're using a declerative configuration file, create a configuration file and update the `CONFIG_PATH` environment variable in your `.env.development.local` file. |
38 | 42 |
|
39 | 43 | 8. Start Sourcebot with the command: |
40 | 44 | ```sh |
|
0 commit comments