Skip to content

Published :tada:

Latest
Compare
Choose a tag to compare
@bannzai bannzai released this 01 Feb 16:31
· 16 commits to master since this release
a8879f6

What

$ switchecker --help

Usage of switchecker:
  -source string
        Source go files are containing enum definition. Multiple specifications can be specified separated by ,. e.g) *.go,pkg/**/*.go  (default "*.go")
  -target string
        Target go files are containing to use enum. Multiple specifications can be specified separated by ,. e.g) *.go,pkg/**/*.go  (default "*.go")
  -verbose
        Enabled verbose log

switcher is tool of checking for missing case about go enum(Actually, this is not enum. It is constant value) in go file.
It can be take safety when using switch word in go source code.
It is not ignore for dirty case (e.g case 5, case "strings").
So, switcher only support to check the missing case.