Use Python whitespace conventions
This commit is contained in:
parent
ce70209310
commit
529f5a1cd0
@ -16,9 +16,9 @@ repo = base.repos[reponame]
|
||||
# Loosely based on write_raw_configfile() from DNF source code,
|
||||
# because that method was introduced in DNF 2.0 but Qubes dom0 has DNF 1.x.
|
||||
with open(repo.repofile) as fp:
|
||||
ini = iniparse.INIConfig(fp)
|
||||
ini = iniparse.INIConfig(fp)
|
||||
|
||||
ini[reponame]['enabled'] = 0
|
||||
|
||||
with open(repo.repofile, 'w') as fp:
|
||||
fp.write(str(ini))
|
||||
fp.write(str(ini))
|
||||
|
@ -16,9 +16,9 @@ repo = base.repos[reponame]
|
||||
# Loosely based on write_raw_configfile() from DNF source code,
|
||||
# because that method was introduced in DNF 2.0 but Qubes dom0 has DNF 1.x.
|
||||
with open(repo.repofile) as fp:
|
||||
ini = iniparse.INIConfig(fp)
|
||||
ini = iniparse.INIConfig(fp)
|
||||
|
||||
ini[reponame]['enabled'] = 1
|
||||
|
||||
with open(repo.repofile, 'w') as fp:
|
||||
fp.write(str(ini))
|
||||
fp.write(str(ini))
|
||||
|
@ -7,5 +7,5 @@ base = dnf.Base()
|
||||
base.read_all_repos()
|
||||
|
||||
for repo in base.repos.all():
|
||||
l = [repo.id, repo.name, 'enabled' if repo.enabled else 'disabled']
|
||||
print('\0'.join(l))
|
||||
l = [repo.id, repo.name, 'enabled' if repo.enabled else 'disabled']
|
||||
print('\0'.join(l))
|
||||
|
Loading…
Reference in New Issue
Block a user