upstream_sync
                                
                                 upstream_sync copied to clipboard
                                
                                    upstream_sync copied to clipboard
                            
                            
                            
                        Group data (using comps.xml) should be used when showing the command with -c
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.
I plan to make this change at some point but wanted to document it here to have something to work with.
Generally I think this is a good idea. However, this could be a bit tricky to implement.
- /repo/path/comps.xmlwon't exist before a sync
- there is no way to know if the source (rsync, reposync) will have comps.xml
- if comps.xmlexists before sync, there is no guarantee it will exist after a sync (deleted from remote server)
What does createrepo do if comps.xmldoesn't exist? Does it fail?
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