Skip to content

Commit

Permalink
Use Python whitespace conventions
Browse files Browse the repository at this point in the history
  • Loading branch information
strugee committed Apr 8, 2019
1 parent ce70209 commit 529f5a1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions qubes-rpc/qubes.repos.Disable
Original file line number Diff line number Diff line change
Expand Up @@ -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))
4 changes: 2 additions & 2 deletions qubes-rpc/qubes.repos.Enable
Original file line number Diff line number Diff line change
Expand Up @@ -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))
4 changes: 2 additions & 2 deletions qubes-rpc/qubes.repos.List
Original file line number Diff line number Diff line change
Expand Up @@ -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))

0 comments on commit 529f5a1

Please sign in to comment.