'portage.dep:dep_getkey,match_from_list,paren_reduce,use_reduce',
'portage.env.loaders:KeyValuePairFileLoader',
'portage.util:ensure_dirs,writemsg,writemsg_level',
- 'portage.versions:best,catpkgsplit,pkgsplit,ver_regexp',
+ 'portage.versions:best,catpkgsplit,_pkgsplit@pkgsplit,ver_regexp',
)
from portage.cache.cache_errors import CacheError
'portage.util:apply_secpass_permissions,ConfigProtect,ensure_dirs,' + \
'writemsg,writemsg_level,write_atomic,atomic_ofstream,writedict,' + \
'grabfile,grabdict,normalize_path,new_protect_filename,getlibpaths',
- 'portage.versions:best,catpkgsplit,catsplit,pkgcmp,pkgsplit',
+ 'portage.versions:best,catpkgsplit,catsplit,pkgcmp,_pkgsplit@pkgsplit',
)
from portage.const import CACHE_PATH, CONFIG_MEMORY_FILE, \
_pv_re = re.compile('^' + _pv + '$', re.VERBOSE)
def _pkgsplit(mypkg):
-
+ """
+ @param mypkg: pv
+ @return:
+ 1. None if input is invalid.
+ 2. (pn, ver, rev) if input is pv
+ """
m = _pv_re.match(mypkg)
if m is None:
return None