diff options
author | 2022-05-30 19:06:54 -0700 | |
---|---|---|
committer | 2022-05-30 19:22:29 -0700 | |
commit | 738c6f83b48c9f33ae17551b725756a1e94437fb (patch) | |
tree | a3a3548257d2935ee311c93347ae5bb6a3604900 | |
parent | selectors.py: Bug 800149. Add general exception for any other server error (diff) | |
download | mirrorselect-738c6f83b48c9f33ae17551b725756a1e94437fb.tar.gz mirrorselect-738c6f83b48c9f33ae17551b725756a1e94437fb.tar.bz2 mirrorselect-738c6f83b48c9f33ae17551b725756a1e94437fb.zip |
main.py: Fix bug 600572 Remove SYNC variable usage
Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
-rwxr-xr-x | mirrorselect/main.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/mirrorselect/main.py b/mirrorselect/main.py index b0a68cc..9cad25b 100755 --- a/mirrorselect/main.py +++ b/mirrorselect/main.py @@ -343,12 +343,12 @@ class MirrorSelect(object): @rtype: string ''' if rsync: - # startwith repos.conf + # repos.conf config_path = EPREFIX + '/etc/portage/repos.conf/gentoo.conf' if not os.access(config_path, os.F_OK): self.output.write("Failed access to gentoo.conf: " "%s\n" % os.access(config_path, os.F_OK), 2) - return get_make_conf_path(EPREFIX) + config_path = None return config_path return get_make_conf_path(EPREFIX) @@ -363,12 +363,12 @@ class MirrorSelect(object): self.output.verbosity = options.verbosity self.output.write("main(); config_path = %s\n" % config_path, 2) - # reset config_path to find repos.conf/gentoo.conf if it exists + # reset config_path to find repos.conf/gentoo.conf if options.rsync: config_path = self.get_conf_path(options.rsync) self.output.write("main(); reset config_path = %s\n" % config_path, 2) - else: - self.output.write("main(); rsync = %s\n" % str(options.rsync),2) + if not config_path: + self.output.print_err("main(); Exiting due to missing repos.conf/gentoo.conf file\n") fsmirrors = get_filesystem_mirrors(self.output, config_path, options.rsync) |