Merge pull request #43452 from kponichtera/43451-contribution-guide-set-up-ide
Extended contribution guide with how to make IDEs recognize Moby’s repository as a Go project
This commit is contained in:
commit
b963ba4a1e
7 changed files with 45 additions and 4 deletions
|
@ -3,6 +3,7 @@
|
||||||
* [README first](who-written-for.md)
|
* [README first](who-written-for.md)
|
||||||
* [Get the required software](software-required.md)
|
* [Get the required software](software-required.md)
|
||||||
* [Set up for development on Windows](software-req-win.md)
|
* [Set up for development on Windows](software-req-win.md)
|
||||||
|
* (Optional) [Configure project for IDE](set-up-ide.md)
|
||||||
* [Configure Git for contributing](set-up-git.md)
|
* [Configure Git for contributing](set-up-git.md)
|
||||||
* [Work with a development container](set-up-dev-env.md)
|
* [Work with a development container](set-up-dev-env.md)
|
||||||
* [Run tests and test documentation](test.md)
|
* [Run tests and test documentation](test.md)
|
||||||
|
|
BIN
docs/contributing/images/ide_custom_gopath.png
Normal file
BIN
docs/contributing/images/ide_custom_gopath.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 66 KiB |
BIN
docs/contributing/images/ide_go_modules_integration.png
Normal file
BIN
docs/contributing/images/ide_go_modules_integration.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 60 KiB |
BIN
docs/contributing/images/ide_system_environment_gopath.png
Normal file
BIN
docs/contributing/images/ide_system_environment_gopath.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 66 KiB |
36
docs/contributing/set-up-ide.md
Normal file
36
docs/contributing/set-up-ide.md
Normal file
|
@ -0,0 +1,36 @@
|
||||||
|
### Configure project for IDE (optional)
|
||||||
|
|
||||||
|
In this section you will configure the project in order to make use of [GoLand](https://www.jetbrains.com/go)
|
||||||
|
integrated development environment's (IDE) features like syntax highlighting and code completion.
|
||||||
|
|
||||||
|
## 1. Place repository to the GOPATH
|
||||||
|
|
||||||
|
The repository has to be placed under `src` directory in GOPATH.
|
||||||
|
The default location for Linux and macOS users is `~/go`, while for Windows it is `%USERPROFILE%\go`.
|
||||||
|
|
||||||
|
Move the previously cloned repository or clone it again to the `<GOPATH>/src/github.com/docker/docker` directory.
|
||||||
|
|
||||||
|
## 2. Configure IDE
|
||||||
|
|
||||||
|
Open the `<GOPATH>/src/github.com/docker/docker` directory in GoLand.
|
||||||
|
Then open the settings (Ctrl+Alt+S) and change two settings:
|
||||||
|
|
||||||
|
1. Disable Go modules integration
|
||||||
|
|
||||||
|
![Disabling Go modules integration](images/ide_go_modules_integration.png)
|
||||||
|
|
||||||
|
3. Disable using system environment's GOPATH
|
||||||
|
|
||||||
|
![Disabling using system environment's GOPATH](images/ide_system_environment_gopath.png)
|
||||||
|
|
||||||
|
### Custom GOPATH
|
||||||
|
|
||||||
|
In case the custom GOPATH is used (for example to have multiple copies of the cloned repository),
|
||||||
|
it has to be configured in the settings as well:
|
||||||
|
|
||||||
|
![Configuring custom GOPATH](images/ide_custom_gopath.png)
|
||||||
|
|
||||||
|
## Where to go next
|
||||||
|
|
||||||
|
Congratulations, you have finished configuring project to work with the IDE.
|
||||||
|
In the next section you'll [learn how to set up and work in a Moby development container](set-up-dev-env.md).
|
|
@ -173,5 +173,7 @@ https://github.com/kevpar/docker-w2wCIScripts/blob/master/runCI/Invoke-DockerCI.
|
||||||
|
|
||||||
## Where to go next
|
## Where to go next
|
||||||
|
|
||||||
In the next section, you'll [learn how to set up and configure Git for
|
In the next section, you'll [configure the project to be properly recognized by the IDE](set-up-ide.md).
|
||||||
contributing to Moby](set-up-git.md).
|
|
||||||
|
If you don't want to use IDE, you can proceed to the next step
|
||||||
|
and [learn how to set up and configure Git for contributing to Moby](set-up-git.md).
|
||||||
|
|
|
@ -90,5 +90,7 @@ You must log out and log back in for this modification to take effect.
|
||||||
|
|
||||||
## Where to go next
|
## Where to go next
|
||||||
|
|
||||||
In the next section, you'll [learn how to set up and configure Git for
|
In the next section, you'll [configure the project to be properly recognized by the IDE](set-up-ide.md).
|
||||||
contributing to Moby](set-up-git.md).
|
|
||||||
|
If you don't want to use IDE, you can proceed to the next step
|
||||||
|
and [learn how to set up and configure Git for contributing to Moby](set-up-git.md).
|
Loading…
Reference in a new issue