mirror of
https://codeberg.org/scip/tablizer.git
synced 2025-12-17 04:30:56 +01:00
fix linter errors
This commit is contained in:
10
cmd/root.go
10
cmd/root.go
@@ -105,11 +105,11 @@ func Execute() {
|
||||
rootCmd.PersistentFlags().BoolVarP(&modeflag.S, "shell", "S", false, "Enable shell mode output")
|
||||
rootCmd.PersistentFlags().BoolVarP(&modeflag.Y, "yaml", "Y", false, "Enable yaml output")
|
||||
rootCmd.MarkFlagsMutuallyExclusive("extended", "markdown", "orgtbl", "shell", "yaml")
|
||||
rootCmd.Flags().MarkHidden("extended")
|
||||
rootCmd.Flags().MarkHidden("orgtbl")
|
||||
rootCmd.Flags().MarkHidden("markdown")
|
||||
rootCmd.Flags().MarkHidden("shell")
|
||||
rootCmd.Flags().MarkHidden("yaml")
|
||||
_ = rootCmd.Flags().MarkHidden("extended")
|
||||
_ = rootCmd.Flags().MarkHidden("orgtbl")
|
||||
_ = rootCmd.Flags().MarkHidden("markdown")
|
||||
_ = rootCmd.Flags().MarkHidden("shell")
|
||||
_ = rootCmd.Flags().MarkHidden("yaml")
|
||||
|
||||
// same thing but more common, takes precedence over above group
|
||||
rootCmd.PersistentFlags().StringVarP(&Outputmode, "output", "o", "ascii", "Output mode - one of: orgtbl, markdown, extended, shell, ascii(default)")
|
||||
|
||||
@@ -24,7 +24,7 @@ import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
func Testcontains(t *testing.T) {
|
||||
func TestContains(t *testing.T) {
|
||||
var tests = []struct {
|
||||
list []int
|
||||
search int
|
||||
|
||||
@@ -90,8 +90,8 @@ func printOrgmodeData(w io.Writer, c cfg.Config, data *Tabdata) {
|
||||
| cell | cell |
|
||||
|------+------|
|
||||
*/
|
||||
leftR := regexp.MustCompile("(?m)^\\+")
|
||||
rightR := regexp.MustCompile("\\+(?m)$")
|
||||
leftR := regexp.MustCompile(`(?m)^\\+`)
|
||||
rightR := regexp.MustCompile(`\\+(?m)$`)
|
||||
|
||||
output(w, color.Sprint(
|
||||
colorizeData(c,
|
||||
|
||||
Reference in New Issue
Block a user