rhbz1110627 zanata init

https://bugzilla.redhat.com/show_bug.cgi?id=1110627
and https://bugzilla.redhat.com/show_bug.cgi?id=1038852

Depends on https://github.com/zanata/zanata-api/pull/15 and https://github.com/zanata/zanata-server/pull/520
This one is used by other classes. It fits better in a utility class but I wanted to leave it like this for now. Eventually this code will be replaced/refactored when we apply similar code construct (color output and console prompt etc) to other commands. Right now is a bit of a mix. 

----- Original Message -----

> From: "David Mason" <notifications@github.com>
> To: "zanata/zanata-client" <zanata-client@noreply.github.com>
> Cc: "Patrick Huang" <pahuang@redhat.com>
> Sent: Tuesday, July 29, 2014 1:32:31 PM
> Subject: Re: [zanata-client] rhbz1110627 zanata init (#27)

> In
> zanata-client-commands/src/main/java/org/zanata/client/commands/init/InitCommand.java:
> > +                        .getProjectVersion());
> > +    }
> > +
> > +    private boolean isInvokedByMaven() {
> > +        return
> > getOpts().getClass().getPackage().getName().contains("maven");
> > +    }
> > +
> > +    private static String getProjectIterationUrl(URL server, String
> > projectSlug,
> > +            String iterationSlug) {
> > +        return String.format(ITERATION_URL, server,
> > +                projectSlug, iterationSlug);
> > +    }
> > +
> > +
> > +    public static void offerRetryOnServerError(ClientResponse response,
> > +            ConsoleInteractor consoleInteractor) {

> Another one that could be non-static and use the console field.

> —
> Reply to this email directly or view it on GitHub .