]> SALOME platform Git repositories - tools/configuration.git/commitdiff
Salome HOME
At least 1 FILE is required
authorGilles DAVID <gilles-g.david@edf.fr>
Fri, 22 Sep 2017 15:45:05 +0000 (17:45 +0200)
committerGilles DAVID <gilles-g.david@edf.fr>
Fri, 22 Sep 2017 15:45:05 +0000 (17:45 +0200)
copyright/insert_copyright

index 87a44b2cca775698c1a26b508ad0aa6225b90f27..6f70a366c250f9a6462e8969b032b4eb1bd0a80d 100755 (executable)
@@ -327,7 +327,7 @@ def main():
                         dest="format", default=file_format,
                         help=help_string.format(file_format=file_format,
                                                 choices="|".join(formats())))
-    parser.add_argument('files', nargs='*')
+    parser.add_argument('files', nargs='+', metavar='FILE')
 
     args = parser.parse_args(sys.argv[1:])
 
@@ -336,9 +336,6 @@ def main():
     file_format = args.format
     files = args.files
 
-    if not files:
-        error_exit('file is not specified')
-
     for filename in files:
         insert_copyright(filename, owner, year, file_format)