Bug 1038449

Summary: RFE: integrate client with command-line tools (command hook in zanata.xml)
Product: [Retired] Zanata Reporter: Ding-Yi Chen <dchen>
Component: Component-MavenAssignee: David Mason <damason>
Status: CLOSED CURRENTRELEASE QA Contact: Zanata-QA Mailling List <zanata-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: ankit, damason, dchen, djansen, petersen, pschiffe, rlandman, sflaniga, tagoh, zanata-bugs
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Fixed In Version: zanata-maven-plugin:3.3.0-SNAPSHOT Doc Type: Bug Fix
Doc Text:
Story Points: 5
Clone Of: Environment:
Last Closed: 2014-03-20 05:47:13 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Ding-Yi Chen 2013-12-05 06:59:14 UTC
Some items to test:

1. Output from hook commands is shown by default.
2. Output from hook commands can be hidden if the attribute "quiet" is true.
3. "After" hooks can be run unconditionally if the attribute "always" is true, if a push/pull fails, or if a preceding hook fails.
4. Child process is terminated if the zanata client process is interrupted (eg Ctrl-C).

--- Additional comment from Ding-Yi Chen on 2013-12-05 10:59:55 EST ---

Help Documentation should be located in zanata,org and under the section that explain how to use client.

--- Additional comment from David Mason on 2013-12-05 11:23:34 EST ---

Added link from zanata.org client configuration instructions to command hook instructions on the Zanata wiki.

See paragraph near the end of http://zanata.org/help/cli/cli-configuration/

Comment 1 Ding-Yi Chen 2013-12-05 08:15:51 UTC
The advantages of this approach over shell script or make are:

1. Suitable for maven prior 2.0.9, which returned correct return codes (i.e. always returning 0, see http://jira.codehaus.org/browse/MNG-3651 for detail).

2. Works regardless your are using zanata maven plugin or zanata-client.

Comment 2 David Mason 2013-12-05 23:33:54 UTC
(In reply to Ding-Yi Chen from comment #0)

> 3. "After" hooks can be run unconditionally if the attribute "always" is
> true, if a push/pull fails, or if a preceding hook fails.

This is not included in the provided implementation. I have created a separate bug for the addition of this feature. See: https://bugzilla.redhat.com/show_bug.cgi?id=1038844

Comment 3 Ding-Yi Chen 2013-12-06 06:12:57 UTC
Scope changed:
Attributes in <before> and <after> tag are not covered thus will not be tested with this bug.

Comment 4 Ding-Yi Chen 2013-12-06 06:16:35 UTC
VERIFIED with zanata-maven-plugin:3.3.0-SNAPSHOT
Server Zanata version 3.3.0-SNAPSHOT (20131206-0037)

Comment 6 Sean Flanigan 2014-03-20 05:47:13 UTC
Closing VERIFIED bugs for Zanata server 3.3.2.