File tree Expand file tree Collapse file tree 2 files changed +8
-6
lines changed
csharp/Platform.Data.Doublets.Json Expand file tree Collapse file tree 2 files changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -17,10 +17,11 @@ public class JsonExporterCli<TLink>
17
17
{
18
18
public void Run ( params string [ ] args )
19
19
{
20
- var linksFilePath = ConsoleHelpers . GetOrReadArgument ( 0 , "Links file path" , args ) ;
21
- var jsonFilePath = ConsoleHelpers . GetOrReadArgument ( 1 , "JSON file path" , args ) ;
20
+ var argumentIndex = 0 ;
21
+ var linksFilePath = ConsoleHelpers . GetOrReadArgument ( argumentIndex ++ , "Links file path" , args ) ;
22
+ var jsonFilePath = ConsoleHelpers . GetOrReadArgument ( argumentIndex ++ , "JSON file path" , args ) ;
22
23
var defaultDocumentName = Path . GetFileNameWithoutExtension ( jsonFilePath ) ;
23
- var documentName = ConsoleHelpers . GetOrReadArgument ( 2 , $ "Document name (default: { defaultDocumentName } )", args ) ;
24
+ var documentName = ConsoleHelpers . GetOrReadArgument ( argumentIndex , $ "Document name (default: { defaultDocumentName } )", args ) ;
24
25
if ( string . IsNullOrWhiteSpace ( documentName ) )
25
26
{
26
27
documentName = defaultDocumentName ;
Original file line number Diff line number Diff line change @@ -17,10 +17,11 @@ public class JsonImporterCli<TLink>
17
17
{
18
18
public void Run ( params string [ ] args )
19
19
{
20
- var jsonFilePath = ConsoleHelpers . GetOrReadArgument ( 0 , "JSON file path" , args ) ;
21
- var linksFilePath = ConsoleHelpers . GetOrReadArgument ( 1 , "Links file path" , args ) ;
20
+ var argumentIndex = 0 ;
21
+ var jsonFilePath = ConsoleHelpers . GetOrReadArgument ( argumentIndex ++ , "JSON file path" , args ) ;
22
+ var linksFilePath = ConsoleHelpers . GetOrReadArgument ( argumentIndex ++ , "Links file path" , args ) ;
22
23
var defaultDocumentName = Path . GetFileNameWithoutExtension ( jsonFilePath ) ;
23
- var documentName = ConsoleHelpers . GetOrReadArgument ( 2 , $ "Document name (default: { defaultDocumentName } )", args ) ;
24
+ var documentName = ConsoleHelpers . GetOrReadArgument ( argumentIndex , $ "Document name (default: { defaultDocumentName } )", args ) ;
24
25
if ( string . IsNullOrWhiteSpace ( documentName ) )
25
26
{
26
27
documentName = defaultDocumentName ;
You can’t perform that action at this time.
0 commit comments