add more option comments

This commit is contained in:
Jeff
2019-09-12 15:21:47 +08:00
committed by zryfish
parent 66af315a85
commit 5dde737e6c
10 changed files with 98 additions and 41 deletions

View File

@@ -33,16 +33,13 @@ func (s *SonarQubeOptions) ApplyTo(options *SonarQubeOptions) {
if s.Host != "" {
options.Host = s.Host
}
if s.Token != "" {
options.Token = s.Token
}
}
func (s *SonarQubeOptions) AddFlags(fs *pflag.FlagSet) {
fs.StringVar(&s.Host, "sonarqube-host", s.Host, ""+
"Sonarqube service address if enabled.")
"Sonarqube service address, if left empty, following sonarqube options will be ignored.")
fs.StringVar(&s.Token, "sonarqube-token", s.Token, ""+
"Sonarqube service access token.")