[
https://issues.apache.org/jira/browse/AVRO-3330?focusedWorklogId=717194&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-717194
]
ASF GitHub Bot logged work on AVRO-3330:
----------------------------------------
Author: ASF GitHub Bot
Created on: 28/Jan/22 18:22
Start Date: 28/Jan/22 18:22
Worklog Time Spent: 10m
Work Description: zcsizmadia commented on a change in pull request #1481:
URL: https://github.com/apache/avro/pull/1481#discussion_r794752294
##########
File path: lang/csharp/src/apache/codegen/AvroGen.cs
##########
@@ -29,7 +29,8 @@ static int Main(string[] args)
if (args.Length == 0 || args[0] == "-h" || args[0] == "--help")
{
Usage();
- return 1;
+ // Return success if help requested
+ return args.Length == 0 ? 1 : 0;
Review comment:
I am not sure I agree with that statement: double the code for a very
simple condition. However I modded the PR
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 717194)
Time Spent: 1h 10m (was: 1h)
> Avrogen avsc compiler should return 0 exit code if help requested
> -----------------------------------------------------------------
>
> Key: AVRO-3330
> URL: https://issues.apache.org/jira/browse/AVRO-3330
> Project: Apache Avro
> Issue Type: Improvement
> Components: c++, csharp
> Reporter: Zoltan Csizmadia
> Priority: Minor
> Labels: pull-request-available
> Fix For: 1.11.1
>
> Original Estimate: 1h
> Time Spent: 1h 10m
> Remaining Estimate: 0h
>
> It is a standard behaviour that if a help requested from a tool by (-h,
> –help), the return code is 0. If ana rgument is needed, but the tool was
> executed without arguments, the return code is non zero (1).
> E.g. this feature can be used to check if the tool is available, by running
> requesting its help. Without using OS specific "which" (Linux) or "where"
> (Windows).
>
--
This message was sent by Atlassian Jira
(v8.20.1#820001)