Minor -u fixes

This commit is contained in:
Peter Dimov
2019-12-15 17:20:35 +02:00
parent df1259dec1
commit 4de55f0b23

View File

@@ -226,7 +226,7 @@ if( __name__ == "__main__" ):
parser.add_argument( '-N', '--ignore', help="exclude top-level dependency even when found in scan; can be repeated", metavar='LIB', action='append', default=[] )
parser.add_argument( '-I', '--include', help="additional subdirectory to scan; can be repeated", metavar='DIR', action='append', default=[] )
parser.add_argument( '-g', '--git_args', help="additional arguments to `git submodule update`", default='', action='store' )
parser.add_argument( '-u', '--update', help='update library argument as well', action='store_true' )
parser.add_argument( '-u', '--update', help='update <library> before scanning', action='store_true' )
parser.add_argument( 'library', help="name of library to scan ('libs/' will be prepended)" )
args = parser.parse_args()
@@ -247,16 +247,15 @@ if( __name__ == "__main__" ):
essentials = [ e for e in essentials if os.path.exists( 'libs/' + e ) ]
if args.update:
essentials.append( args.library )
install_modules( essentials, args.git_args )
m = args.library
deps = { m : 1 }
if args.update:
vprint( 1, 'Update submodule:', m )
install_modules( [m], args.git_args )
dirs = [ 'include', 'src', 'test' ]
for dir in args.exclude: