diff options
author | Elena Vilchik <elena.vilchik@sonarsource.com> | 2019-06-03 13:52:05 +0200 |
---|---|---|
committer | SonarTech <sonartech@sonarsource.com> | 2019-06-03 20:21:17 +0200 |
commit | 3719149e27fe217939d27cd0995535a4324a8f5f (patch) | |
tree | debdad0b791b1b00661995c425a5bf31e4ef71ac /server/sonar-docs/src/pages/analysis/languages/go.md | |
parent | c1c4796d937a9b4307d71519024dcfc46ef082f3 (diff) | |
download | sonarqube-3719149e27fe217939d27cd0995535a4324a8f5f.tar.gz sonarqube-3719149e27fe217939d27cd0995535a4324a8f5f.zip |
SONAR-12168 Define embedded documentation for languages (#1592)
Diffstat (limited to 'server/sonar-docs/src/pages/analysis/languages/go.md')
-rw-r--r-- | server/sonar-docs/src/pages/analysis/languages/go.md | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/server/sonar-docs/src/pages/analysis/languages/go.md b/server/sonar-docs/src/pages/analysis/languages/go.md new file mode 100644 index 00000000000..293625200f3 --- /dev/null +++ b/server/sonar-docs/src/pages/analysis/languages/go.md @@ -0,0 +1,41 @@ +--- +title: Go +url: /analysis/languages/go/ +--- + +<!-- static --> +[[info]] +| <iframe src="http://update.sonarsource.org/plugins/go-confluence-include.html" height="125px">Your browser does not support iframes.</iframe> +<!-- /static --> + + + +## Prerequisites + +* SonarQube Scanner should run on a x86-64 Windows, macOS or Linux 64bits machine +* You need the [Go](https://golang.org/) installation on the scan machine only if you want to import coverage data + +## Language-Specific Properties + +You can discover and update the Go-specific [properties](/analysis/analysis-parameters/) in: <!-- sonarcloud -->Project <!-- /sonarcloud -->**[Administration > General Settings > Go](/#sonarqube-admin#/admin/settings?category=go)** + +## "sonar-project.properties" Sample + +Here is a good first version of a `sonar-project.properties`, correctly excluding "vendor" directories and categorizing files as "main" or "test": + +``` + sonar.projectKey=com.company.projectkey1 + sonar.projectName=My Project Name + + sonar.sources=. + sonar.exclusions=**/*_test.go,**/vendor/** + + sonar.tests=. + sonar.test.inclusions=**/*_test.go + sonar.test.exclusions=**/vendor/** +``` + +## Related Pages + +* [Test Coverage & Execution](/analysis/coverage/) +* [Importing External Issues](/analysis/external-issues/) (GoVet, GoLint, GoMetaLinter) |