mirror of
https://github.com/zerwes/ansible-fqcn-converter.git
synced 2024-11-23 09:16:38 -06:00
give precedence to ansible.builtins
This commit is contained in:
parent
2dd84ffbeb
commit
e59b131e12
@ -222,7 +222,13 @@ if not fqcnmapfile or args.updatefqcnmapfile:
|
||||
if nonfqcn not in fqcndict.keys():
|
||||
fqcndict[nonfqcn] = []
|
||||
if fqcn not in fqcndict[nonfqcn]:
|
||||
fqcndict[nonfqcn].append(fqcn)
|
||||
# this defines the precedence of the replacements made
|
||||
if fqcn.startswith('ansible.builtin.'):
|
||||
fqcndict[nonfqcn].insert(0, fqcn)
|
||||
elif fqcn.startswith('ansible.'):
|
||||
fqcndict[nonfqcn].insert(0, fqcn)
|
||||
else:
|
||||
fqcndict[nonfqcn].append(fqcn)
|
||||
print('%s : %s -> %s' % (modname, nonfqcn, fqcn))
|
||||
with open(args.fqcnmapfile, "w", encoding="utf-8") as fqcnmapfile:
|
||||
fqcnmapfile.write(
|
||||
|
Loading…
Reference in New Issue
Block a user