mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-23 18:52:09 +01:00
glib-mkenums: require at least one input file
Previously, the behaviour if you supplied no input files was to crash: Traceback (most recent call last): File "/usr/bin/glib-mkenums", line 420, in <module> base = os.path.basename(options.args[0]) IndexError: list index out of range While in theory you might want to supply no input files, it is much more likely to be a misconfiguration of the build process. Since this has never worked, let's make that explicit: glib-mkenums: error: the following arguments are required: args
This commit is contained in:
parent
a93ecc2004
commit
4cf60ececf
@ -325,7 +325,7 @@ parser.add_argument('--template', default='', dest='template',
|
||||
parser.add_argument('--output', default=None, dest='output')
|
||||
parser.add_argument('--version', '-v', default=False, action='store_true', dest='version',
|
||||
help='Print version informations')
|
||||
parser.add_argument('args', nargs='*')
|
||||
parser.add_argument('args', nargs='+')
|
||||
|
||||
options = parser.parse_args()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user