Smartling / smartling-cli

Smartling-cli is a library and CLI tool for managing Smartling projects. See the project's Wiki for user documentation.
https://github.com/Smartling/smartling-cli/wiki
MIT License
16 stars 9 forks source link

Project info doesn't work without optional parameter #14

Closed dimitrystd closed 7 years ago

dimitrystd commented 7 years ago

According to documentation below the projects list command doesn't have mandatory params

cli.exe projects
Usage:
  smartling [options] [-v]... init [--dry-run]
  smartling [options] [-v]... projects list [-s]
  smartling [options] [-v]... projects info [-p=]
...

but i got this

cli.exe projects info
panic: interface conversion: interface {} is nil, not string

goroutine 1 [running]:
main.doProjectsInfo(0xc0421c2b10, 0xc0423cafe0, 0x1e, 0xc04200c640, 0x37, 0xc042238448, 0x5, 0xc042238470, 0x9, 0x4, ...)
        /go/src/cli/do_projects_info.go:16 +0x860
main.doProjects(0xc0423cafe0, 0x1e, 0xc04200c640, 0x37, 0xc042238448, 0x5, 0xc042238470, 0x9, 0x4, 0xc0421c28a0, ...)
        /go/src/cli/main.go:293 +0x364
main.main()
        /go/src/cli/main.go:174 +0x47e

Of course project is configured in yml One more attempt

cli.exe projects info -p=2f23eaae9
unable to get project "=2f23eaae9" details
└─ failed to get project details: unable to decode JSON response: EOF

Character = is present in documentation and i thought i have to add it Finally this one works

cli.exe projects info -p 2f23eaae9

DoD:

seletskiy commented 7 years ago

@dimitrystd: panic should be already fixed in latest commit.