aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Harder <radhermit@gmail.com>2016-02-28 12:37:45 -0500
committerTim Harder <radhermit@gmail.com>2016-02-28 12:38:24 -0500
commit8267e3566b8eb5e0da4091e449c853ee7794b6af (patch)
tree553781c42e9ed5c4a02a47edf0f50fccbfcbacb1
parentshell: extract caller info into its own method (diff)
downloadpkgcore-8267e3566b8eb5e0da4091e449c853ee7794b6af.tar.gz
pkgcore-8267e3566b8eb5e0da4091e449c853ee7794b6af.tar.bz2
pkgcore-8267e3566b8eb5e0da4091e449c853ee7794b6af.zip
binpkg/remote: remove old, unused write_index() method
-rw-r--r--pkgcore/binpkg/remote.py20
1 files changed, 1 insertions, 19 deletions
diff --git a/pkgcore/binpkg/remote.py b/pkgcore/binpkg/remote.py
index ba4d52e34..ac58e9efa 100644
--- a/pkgcore/binpkg/remote.py
+++ b/pkgcore/binpkg/remote.py
@@ -8,7 +8,7 @@ Currently this primarily just holds the Packages cache used for remote, and
local binpkg repositories
"""
-__all__ = ("PackagesCacheV0", "PackagesCacheV1", "write_index")
+__all__ = ("PackagesCacheV0", "PackagesCacheV1")
from itertools import izip
import os
@@ -311,21 +311,3 @@ def get_cache_kls(version):
elif version in ('1', '-1'):
return PackagesCacheV1
raise KeyError("cache version %s unsupported" % (version,))
-
-
-def write_index(filepath, repo, version=-1):
- """
- given a repository, serialize its packages contents to a PackagesCache backend.
-
- :param filepath: path to write the cache to
- :param repo: Repository instance to serialize
- :param version: if set, this is the format version to use. Defaults to the
- most recent (currently v1)
- """
- if version == -1:
- version = 1
- try:
- cls = globals()['PackagesCacheV%i' % version]
- except KeyError:
- raise ValueError("unknown version")
- return cls.write_repo(filepath, repo)