func IsSecretFile(filename string) bool {
	base := filepath.Base(filename)
	return !strings.HasPrefix(base, ".") && yamlExtRegexp.MatchString(filepath.Ext(base))
}
IsSecretFile returns whether the given file is secret file or not
package util
import (
	"bufio"
	"io"
	"io/ioutil"
	"os"
	"path/filepath"
	"regexp"
	"sort"
	"strings"
	"github.com/Songmu/prompter"
	"github.com/pkg/errors"
)
var (
	separatorRegExp = regexp.MustCompile(`^#+\s*[-=]{3,}`)
	yamlExtRegexp   = regexp.MustCompile(`\.[yY][aA]?[mM][lL]$`)
)
func CompareStrings(src, dst []string) ([]string, []string) {
	added, deleted := []string{}, []string{}
	ss := map[string]int{}
	for _, s := range src {
		ss[s] = 1
	}
	for _, s := range dst {
		ss[s] += 2
	}
	for k, v := range ss {
		switch v {
		case 1:
			deleted = append(deleted, k)
		case 2:
			added = append(added, k)
		}
	}
	sort.Strings(added)
	sort.Strings(deleted)
	return added, deleted
}
func IsExist(name string) bool {
	_, err := os.Stat(name)
	return err == nil || os.IsExist(err)
}