Preparing report...

Report for gitlab.com/xiayesuifeng/v2rayxplus

A    Great!    Found 43 issues across 46 files

Tweet

gofmt100%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command

No problems detected. Good job!


go_vet100%

go vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string.

No problems detected. Good job!


gocyclo95%

Gocyclo calculates cyclomatic complexities of functions in Go source code. The cyclomatic complexity of a function is calculated according to the following rules: 1 is the base complexity of a function +1 for each 'if', 'for', 'case', '&&' or '||' Go Report Card warns on functions with cyclomatic complexity > 15.


golint6%

Golint is a linter for Go source code.

    • /gitlab.com/xiayesuifeng/v2rayxplus/core/utils.go
    • Line 15: warning: exported function CopyFile should have comment or be unexported (golint)
    • Line 36: warning: exported function GetConfigName should have comment or be unexported (golint)
    • Line 50: warning: exported function GetSu should have comment or be unexported (golint)
    • Line 62: warning: exported function GetTargetConfig should have comment or be unexported (golint)
    • Line 87: warning: exported function CopyConfigToEtc should have comment or be unexported (golint)
    • Line 109: warning: exported function StartV2rayXPlusSerive should have comment or be unexported (golint)
    • Line 122: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 129: warning: exported function RestartV2rayXPlusSerive should have comment or be unexported (golint)
    • Line 142: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 149: warning: exported function StatusV2rayXPlusSerive should have comment or be unexported (golint)
    • Line 153: warning: exported function StopV2rayXPlusSerive should have comment or be unexported (golint)
    • Line 156: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 162: warning: exported function StartService should have comment or be unexported (golint)
    • Line 170: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 175: warning: exported function RestartService should have comment or be unexported (golint)
    • Line 183: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 188: warning: exported function StopService should have comment or be unexported (golint)
    • Line 196: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 201: warning: exported function StatusService should have comment or be unexported (golint)
    • Line 225: warning: exported function InitIpTables should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/conf/router.go
    • Line 3: warning: exported type RouterRule should have comment or be unexported (golint)
    • Line 8: warning: exported type RouterFieldRule should have comment or be unexported (golint)
    • Line 13: warning: exported type RouterRulesConfig should have comment or be unexported (golint)
    • Line 18: warning: exported type RouterConfig should have comment or be unexported (golint)
    • Line 22: warning: exported type RuleConfig should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/conf/streamSetting.go
    • Line 5: warning: exported type StreamConfig should have comment or be unexported (golint)
    • Line 18: warning: exported type HeaderConfig should have comment or be unexported (golint)
    • Line 22: warning: exported type XtlsConfig should have comment or be unexported (golint)
    • Line 26: warning: exported type KcpConfig should have comment or be unexported (golint)
    • Line 38: warning: exported type WebSocketConfig should have comment or be unexported (golint)
    • Line 43: warning: exported type HttpConfig should have comment or be unexported (golint)
    • Line 48: warning: exported type DomainSocketConfig should have comment or be unexported (golint)
    • Line 52: warning: exported type QuicConfig should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/subscription/subscription.go
    • Line 18: warning: exported type Adapter should have comment or be unexported (golint)
    • Line 23: warning: exported function InitAdapter should have comment or be unexported (golint)
    • Line 30: warning: exported function GetAdapterNames should have comment or be unexported (golint)
    • Line 38: warning: exported function UpdateSubscription should have comment or be unexported (golint)
    • Line 103: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/styles/styles.go
    • Line 5: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 12: warning: exported const SettingButton should have comment or be unexported (golint)
    • Line 33: warning: exported const EditButton should have comment or be unexported (golint)
    • Line 54: warning: exported const RemoveButton should have comment or be unexported (golint)
    • Line 75: warning: exported const SaveButton should have comment or be unexported (golint)
    • Line 101: warning: exported const CancelButton should have comment or be unexported (golint)
    • Line 126: warning: exported const ConfigListItem should have comment or be unexported (golint)
    • Line 148: warning: exported const StartButton should have comment or be unexported (golint)
    • Line 171: warning: exported const StopButton should have comment or be unexported (golint)
    • Line 194: warning: exported const AddButton should have comment or be unexported (golint)
    • Line 219: warning: exported function GetStyleSheet should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/ui/configEdit/vmessConfig.go
    • Line 1: warning: don't use MixedCaps in package name; configEdit should be configedit (golint)
    • Line 10: warning: exported type VmessConfig should have comment or be unexported (golint)
    • Line 19: warning: exported function NewVmessConfig should have comment or be unexported (golint)
    • Line 41: warning: exported method VmessConfig.ParseConf should have comment or be unexported (golint)
    • Line 49: warning: exported method VmessConfig.SaveConf should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/conf/v2ray.go
    • Line 8: warning: exported type OutboundConfig should have comment or be unexported (golint)
    • Line 16: warning: exported type InboundConfig should have comment or be unexported (golint)
    • Line 26: warning: exported type SniffingConfig should have comment or be unexported (golint)
    • Line 31: warning: exported type SocketConfig should have comment or be unexported (golint)
    • Line 37: warning: exported type MuxConfig should have comment or be unexported (golint)
    • Line 42: warning: exported type V2rayConfig should have comment or be unexported (golint)
    • Line 51: warning: exported function ParseV2ray should have comment or be unexported (golint)
    • Line 65: warning: exported method V2rayConfig.Save should have comment or be unexported (golint)
    • Line 74: warning: exported function NewV2rayConfig should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/conf/vless.go
    • Line 5: warning: exported type VlessAccount should have comment or be unexported (golint)
    • Line 12: warning: exported type VlessOutboundTarget should have comment or be unexported (golint)
    • Line 18: warning: exported type VlessOutboundConfig should have comment or be unexported (golint)
    • Line 22: warning: exported function NewVlessOutboundConfig should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/conf/vmess.go
    • Line 5: warning: exported type VMessAccount should have comment or be unexported (golint)
    • Line 11: warning: exported type VMessOutboundTarget should have comment or be unexported (golint)
    • Line 17: warning: exported type VMessOutboundConfig should have comment or be unexported (golint)
    • Line 21: warning: exported function NewVMessOutboundConfig should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/ui/configEdit/streamConfig/streamConfigWidget.go
    • Line 1: warning: don't use MixedCaps in package name; streamConfig should be streamconfig (golint)
    • Line 10: warning: exported type StreamConfigWidget should have comment or be unexported (golint)
    • Line 30: warning: exported function NewStreamConfigWidget should have comment or be unexported (golint)
    • Line 87: warning: exported method StreamConfigWidget.ParseConfig should have comment or be unexported (golint)
    • Line 137: warning: exported method StreamConfigWidget.SaveConfig should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/helper/client.go
    • Line 7: warning: exported type Client should have comment or be unexported (golint)
    • Line 12: warning: exported function NewClient should have comment or be unexported (golint)
    • Line 24: warning: exported method Client.StartService should have comment or be unexported (golint)
    • Line 28: warning: exported method Client.RestartService should have comment or be unexported (golint)
    • Line 32: warning: exported method Client.StopService should have comment or be unexported (golint)
    • Line 36: warning: exported method Client.StopHelper should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/ui/configEdit/vlessConfig.go
    • Line 1: warning: don't use MixedCaps in package name; configEdit should be configedit (golint)
    • Line 10: warning: exported type VlessConfig should have comment or be unexported (golint)
    • Line 21: warning: exported function NewVlessConfig should have comment or be unexported (golint)
    • Line 49: warning: exported method VlessConfig.ParseConf should have comment or be unexported (golint)
    • Line 60: warning: exported method VlessConfig.SaveConf should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/conf/config.go
    • Line 9: warning: exported var ConfigPath should have comment or be unexported (golint)
    • Line 10: warning: exported var V2rayConfigPath should have comment or be unexported (golint)
    • Line 11: warning: exported var V2rayDefaultConfigPath should have comment or be unexported (golint)
    • Line 13: warning: exported var Conf should have comment or be unexported (golint)
    • Line 14: warning: exported var HelperClient should have comment or be unexported (golint)
    • Line 16: warning: exported type Config should have comment or be unexported (golint)
    • Line 35: warning: exported type Subscription should have comment or be unexported (golint)
    • Line 42: warning: exported type V2rayXPlusConfig should have comment or be unexported (golint)
    • Line 49: warning: exported method Config.SaveConf should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/conf/dns.go
    • Line 8: warning: exported type DnsConfig should have comment or be unexported (golint)
    • Line 13: warning: exported type DnsServer should have comment or be unexported (golint)
    • Line 21: warning: exported function NewDnsServerForAddress should have comment or be unexported (golint)
    • Line 26: warning: exported method DnsServer.MarshalJSON should have comment or be unexported (golint)
    • Line 29: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 42: warning: exported method DnsServer.UnmarshalJSON should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/conf/socks.go
    • Line 5: warning: exported type SocksAccount should have comment or be unexported (golint)
    • Line 10: warning: exported type SocksServerConfig should have comment or be unexported (golint)
    • Line 19: warning: exported type SocksRemoteConfig should have comment or be unexported (golint)
    • Line 24: warning: exported type SocksClientConfig should have comment or be unexported (golint)
    • Line 28: warning: exported function NewSocksClientConfig should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/ui/configEdit/configEdit.go
    • Line 1: warning: don't use MixedCaps in package name; configEdit should be configedit (golint)
    • Line 13: warning: exported type ConfigEdit should have comment or be unexported (golint)
    • Line 31: warning: exported function NewConfigEdit should have comment or be unexported (golint)
    • Line 112: warning: exported method ConfigEdit.ConfigChange should have comment or be unexported (golint)
    • Line 118: warning: exported method ConfigEdit.EditChange should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/ui/configEdit/muxConfigWidget.go
    • Line 1: warning: don't use MixedCaps in package name; configEdit should be configedit (golint)
    • Line 9: warning: exported type MuxConfigWidget should have comment or be unexported (golint)
    • Line 18: warning: exported function NewMuxConfigWidget should have comment or be unexported (golint)
    • Line 64: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/ui/configEdit/socksConfig.go
    • Line 1: warning: don't use MixedCaps in package name; configEdit should be configedit (golint)
    • Line 9: warning: exported type SocksConfig should have comment or be unexported (golint)
    • Line 19: warning: exported function NewSocksConfig should have comment or be unexported (golint)
    • Line 46: warning: exported method SocksConfig.ParseConf should have comment or be unexported (golint)
    • Line 53: warning: exported method SocksConfig.SaveConf should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/ui/configEdit/shadowsocksConfig.go
    • Line 1: warning: don't use MixedCaps in package name; configEdit should be configedit (golint)
    • Line 9: warning: exported type ShadowsocsConfig should have comment or be unexported (golint)
    • Line 22: warning: exported function NewShadowsocsConfig should have comment or be unexported (golint)
    • Line 54: warning: exported method ShadowsocsConfig.ParseConf should have comment or be unexported (golint)
    • Line 61: warning: exported method ShadowsocsConfig.SaveConf should have comment or be unexported (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/ui/configEdit/streamConfig/kcpConfig.go
    • Line 1: warning: don't use MixedCaps in package name; streamConfig should be streamconfig (golint)
    • Line 12: warning: exported type KcpConfig should have comment or be unexported (golint)
    • Line 28: warning: exported function NewKcpConfig should have comment or be unexported (golint)
    • Line 114: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • /gitlab.com/xiayesuifeng/v2rayxplus/helper/helper.go
    • Line 10: warning: exported var InterfaceName should have comment or be unexported (golint)
    • Line 12: warning: exported type Helper should have comment or be unexported (golint)
    • Line 18: warning: exported function NewHelper should have comment or be unexported (golint)
    • Line 27: warning: exported method Helper.StartService should have comment or be unexported (golint)
    • Line 30: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 43: warning: exported method Helper.RestartService should have comment or be unexported (golint)
    • Line 46: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 59: warning: exported method Helper.StopService should have comment or be unexported (golint)
    • Line 62: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 71: warning: exported method Helper.StopHelper should have comment or be unexported (golint)
    • Line 74: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • Line 89: warning: if block ends with a return statement, so drop this else and outdent its block (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!