diff --git a/.travis.yml b/.travis.yml index 7993474..6dcb9f0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,6 +5,7 @@ language: go go: - 1.6.x - 1.7.x + - 1.8.x - tip os: @@ -21,9 +22,8 @@ matrix: - go: tip before_install: - - go get -v pkg.re/essentialkaos/ek.v6 - - go get -v pkg.re/essentialkaos/go-simpleyaml.v1 + - make deps script: - - go build yo.go + - make all - .travis/script.sh diff --git a/.travis/script.sh b/.travis/script.sh index f322a42..63e73f9 100755 --- a/.travis/script.sh +++ b/.travis/script.sh @@ -38,6 +38,15 @@ has_errors="" ################################################################################ main() { + if [[ ! -e $BINARY ]] ; then + echo -e "${CL_RED}Can't find yo binary${CL_NORM}" + exit 1 + fi + + runTest +} + +runTest() { header "Basic selectors" check ".name" "John Doe" diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..24967f2 --- /dev/null +++ b/Makefile @@ -0,0 +1,23 @@ +######################################################################################## + +.PHONY = fmt all clean deps + +######################################################################################## + +all: yo + +yo: + go build yo.go + +deps: + go get -v pkg.re/essentialkaos/ek.v7 + go get -v pkg.re/essentialkaos/go-simpleyaml.v1 + +fmt: + find . -name "*.go" -exec gofmt -s -w {} \; + +clean: + rm -f yo + +######################################################################################## + diff --git a/common/yo.spec b/common/yo.spec index 2506648..02a1738 100644 --- a/common/yo.spec +++ b/common/yo.spec @@ -44,7 +44,7 @@ Summary: Command-line YAML processor Name: yo -Version: 0.0.2 +Version: 0.1.0 Release: 0%{?dist} Group: Applications/System License: EKOL @@ -92,6 +92,9 @@ rm -rf %{buildroot} ############################################################################### %changelog +* Wed Mar 08 2017 Anton Novojilov - 0.1.0-0 +- ek package updated to v7 + * Tue Feb 14 2017 Anton Novojilov - 0.0.2-0 - Fixed output for arrays with maps and sub arrays diff --git a/yo.go b/yo.go index d57fc6b..4b6f78c 100644 --- a/yo.go +++ b/yo.go @@ -15,11 +15,11 @@ import ( "strconv" "strings" - "pkg.re/essentialkaos/ek.v6/arg" - "pkg.re/essentialkaos/ek.v6/env" - "pkg.re/essentialkaos/ek.v6/fmtc" - "pkg.re/essentialkaos/ek.v6/fsutil" - "pkg.re/essentialkaos/ek.v6/usage" + "pkg.re/essentialkaos/ek.v7/arg" + "pkg.re/essentialkaos/ek.v7/env" + "pkg.re/essentialkaos/ek.v7/fmtc" + "pkg.re/essentialkaos/ek.v7/fsutil" + "pkg.re/essentialkaos/ek.v7/usage" "pkg.re/essentialkaos/go-simpleyaml.v1" ) @@ -28,7 +28,7 @@ import ( const ( APP = "Yo" - VER = "0.0.2" + VER = "0.1.0" DESC = "Command-line YAML processor" ) @@ -537,8 +537,6 @@ func (t Token) IsArrayToken() bool { // ////////////////////////////////////////////////////////////////////////////////// // func showUsage() { - usage.Breadcrumbs = true - info := usage.NewInfo("", "query") info.AddOption(ARG_FROM_FILE, "Read data from file", "filename")