pyther / upstream_sync

script to help mirror upstream repositories
MIT License
47 stars 16 forks source link

Group data (using comps.xml) should be used when showing the command with -c #8

Open rothgar opened 8 years ago

rothgar commented 8 years ago

If you run upstream_sync with --command it shows the command but the actual code will check if a comps.xml file exists and if it does it will append -g /repo/path/comps.xml The file should be checked for even when only viewing the reposync and createrepo command.

rothgar commented 8 years ago

I plan to make this change at some point but wanted to document it here to have something to work with.

pyther commented 8 years ago

Generally I think this is a good idea. However, this could be a bit tricky to implement.

What does createrepo do if comps.xmldoesn't exist? Does it fail?

rothgar commented 8 years ago

The code currently just looks for the file and uses it if it exists. I would use the same code block for showing the command too.

https://github.com/pyther/upstream_sync/blob/master/upstream_sync.py#L403-L406