summaryrefslogtreecommitdiffstats
path: root/bin/egencache
Commit message (Collapse)AuthorAgeFilesLines
* egencache: unicode_literals for TextIOWrapperZac Medico2013-01-181-16/+14
|
* Add portage._internal_caller var, and use it.Zac Medico2013-01-031-1/+2
|
* Use run_main_scheduler where possible.Zac Medico2012-12-281-55/+7
|
* egencache: fix --strict-manifests=nZac Medico2012-12-281-1/+1
|
* strip trailing whitespaceMike Frysinger2012-11-221-1/+1
| | | | | | No functional changes here. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
* egencache --update-manifests: re-sign when neededZac Medico2012-10-151-0/+4
| | | | | | If the Manifest is signed with a different key from the one specified by --gpg-key or PORTAGE_GPG_KEY, strip the existing signature and re-sign the Manifest.
* MetadataRegen: inherit AsyncSchedulerZac Medico2012-10-061-2/+3
|
* egencache: add --update-manifests, bug #436918Zac Medico2012-10-031-3/+157
| | | | | | | | | | Update manifest files, and sign them if signing is enabled. This supports parallelization if enabled via the --jobs option. The --thin-manifests and --sign-manifests options may be used to manually override layout.conf settings. There's also a new --strict-manifests option that may be used to manually override the "strict" FEATURES setting, a --gpg-key option to override PORTAGE_GPG_KEY, and a --gpg-dir option to override PORTAGE_GPG_DIR.
* egencache: skip auxdb write if not metadata-transZac Medico2012-09-151-1/+3
|
* egencache: encode unicode file paths safelyZac Medico2012-09-111-1/+2
| | | | | This will fix cases similar to the one fixed in commit f01d7a8ca158ec60df76a3e8ae5b80ac3f62429e for bug #310789.
* egencache: tweak metadata-transfer logicv2.2.0_alpha125Zac Medico2012-09-081-10/+4
| | | | Now is won't force metadata-transfer unless it's absolutely necessary.
* egencache: skip metadata-transfer more oftenZac Medico2012-09-081-3/+4
|
* egencache: skip metadata-transfer if possibleZac Medico2012-09-071-13/+29
| | | | | If there is an existing metadata/md5-cache directory, then it's not necessary to forcibly enable metadata-transfer.
* Unconditionally insert our pym dir in sys.path.Zac Medico2012-09-021-7/+4
| | | | | This is especially necessary when running in prefix mode, since sys.path may contain the path for a different version of portage.
* egencache: add a standard -j flags for --jobsMike Frysinger2012-08-161-1/+1
| | | | Signed-off-by: Mike Frysinger <vapier@gentoo.org>
* egencache: prune empty cache directoriesv2.2.0_alpha114Zac Medico2012-06-271-0/+3
|
* egencache: use vercmp instead of pkgcmpZac Medico2012-05-131-3/+3
|
* Don't write or trust cache for unsupported EAPIs.Zac Medico2012-05-101-2/+7
| | | | | | Since we're supposed to be able to efficiently obtain the EAPI from _parse_eapi_ebuild_head, we don't need to write or trust cache entries for unsupported EAPIs.
* egencache: escape newline instead of lstripZac Medico2012-01-141-4/+4
|
* egencache: use textwrap.dedentZac Medico2012-01-141-10/+10
|
* Remove redundant eprefix in config constructors.Zac Medico2011-12-101-4/+2
| | | | | Since commit 11a7448f1d5a0bfb38f8de9d66a8fa8d7118c877, the config constructor uses portage.const.EPREFIX by default.
* config: make eprefix constructor parameter publicZac Medico2011-12-091-2/+2
|
* Use portage.const.EPREFIX more.Zac Medico2011-12-091-1/+1
|
* Delete portage.dbapi.porttree._repo_info class and _repo_info attribute ofArfrever Frehtes Taifersar Arahesis2011-12-091-1/+1
| | | | | portage.dbapi.porttree.portdbapi objects. Migrate consumers to repositories attribute of portage.dbapi.porttree.portdbapi objects.
* Fix typos in comments.Arfrever Frehtes Taifersar Arahesis2011-10-301-3/+3
|
* egencache: tweak redundant write check conditionZac Medico2011-10-291-17/+16
| | | | | We can use the raise_stat_collision attribute to determine when it is necessary to check for redundant writes.
* Use dbapi._known_keys more.Zac Medico2011-10-291-1/+1
|
* egencache: avoid redundant md5-dict writesZac Medico2011-10-291-13/+45
| | | | | The pms cache already does this automatically, since __setitem__ calls are used to detect stat collisions in order to solve bug #139134.
* egencache: ensure correct porttreesZac Medico2011-10-291-0/+2
| | | | | | | The GenCache class assumes that portdb.porttrees[0] is the desired tree, so assert that it is true. The behavior should have already been correct, since PORTDIR_OVERLAY was already set to an empty string when necessary.
* egencache: fix StatCollision handling breakageZac Medico2011-10-291-3/+3
| | | | | This has been broken since the _eclasses_ structure changed in commit 2ed1cb53cc4158af08c22d466b15b9a9a7767212.
* egencache: update ebuild_hash.mtime after utimeZac Medico2011-10-291-0/+1
|
* egencache: multiple cache-formats supportZac Medico2011-10-291-14/+26
| | | | | If layout.conf contains "cache-formats = md5-dict pms", egencache will now write both formats.
* layout.conf: rename cache_format to cache_formatsZac Medico2011-10-251-1/+2
| | | | | | We read layout.conf cache-formats from left to right and use the first supported type that's found. This will allow support for multiple formats in parallel, providing for smooth transitions between formats.
* egencache: remove unused importZac Medico2011-10-151-1/+0
|
* egencache: add _mtime_ to metadataZac Medico2011-10-151-2/+1
| | | | | | | This fixes a regression in FEATURES=parse-eapi-ebuild-head support for egencache since commit 2ed1cb53cc4158af08c22d466b15b9a9a7767212. If the metadata does not contain _mtime_ here, then _setitem from cache.metadata.database will raise KeyError.
* cache: rewrite to support arbitrary validation methodBrian Harring2011-10-141-4/+10
| | | | | | | | | | Specifically, the cache can use any portage supported checksum method, or use the standard mtime approach. In addition, support controlling whether or not paths are stored, and generally try to restore some of the centralization/encapsulation that was in place originally. (cherry picked from commit bc1aed614fb588f0ade5bcb5d1265a8db0f8d247) Change-Id: Ic38057e7dbb15063c64a93c99e66e113a7d4c70e
* layout.conf: make the pregenerated cache format controllableBrian Harring2011-10-131-2/+2
| | | | | | | | | | | Controllable via 'cache-format', currently it supports only one cache; 'pms', and defaults to it. If an unsupported cache-format is specified, the cache is disabled. If pms is specified and metadata/cache directory doesn't exist, the cache is disabled. Finally, this rips out the best module support for locally overriding the cache format used for pregenerated caches; this functionality made zero sense (upstream determines the format, we use what is available).
* egencache: tweak cache dir write access checkZac Medico2011-09-071-5/+9
|
* egencache: remove metadata-transfer warningZac Medico2011-09-071-3/+0
| | | | | | It should be enough that the automatic use of metadata-transfer is documented in the man page, and allows us to avoid showing a useless warning in common usage scenarios.
* egencache: validate cache dir moreZac Medico2011-09-071-3/+19
|
* tests/emerge: test egencacheZac Medico2011-09-051-7/+4
| | | | | This tests --update in any case, and --update-use-local-desc only if python xml support is detected.
* egencache: don't require xml in global scopeZac Medico2011-08-271-8/+8
|
* egencache: implement XMLParser.doctype()Zac Medico2011-08-271-1/+11
| | | | | | | This is prevents "DeprecationWarning: This method of XMLParser is deprecated. Define doctype() method on the TreeBuilder target." warnings. The code is copied from repoman, commit 5a5e51a2737a0855bb562683f50c57cc31587460.
* egencache: add --portdir-overlay optionZac Medico2011-08-131-0/+9
| | | | This will fix bug #353648.
* Migrate from codecs.open() to io.open().Zac Medico2011-07-101-18/+23
| | | | | | | | | | | | | | | | | The io.open() function is the same as the built-in open() function in python3, and its implementation is optimized in python-2.7 and later. In addition to the possible performance improvement, this also allows us to avoid any future compatibility issues with codecs.open() that may arise if it is delegated to the built-in open() function as discussed in PEP 400. The main caveat involved with io.open() is that TextIOWrapper.write() raises TypeError if given raw bytes, unlike the streams returned from codecs.open(). This is mainly an issue for python2 since literal strings are raw bytes. We handle this by wrapping TextIOWrapper.write() arguments with our _unicode_decode() function. Also, the atomic_ofstream class overrides the write() method in python2 so that it performs automatic coercion to unicode when necessary.
* egencache: fix cmp_func for python3Zac Medico2011-02-181-0/+8
|
* egencache: --preserve-comments allow missing fileZac Medico2011-02-131-4/+26
| | | | This will fix bug #354687.
* egencache: don't ignore as much with --tolerantZac Medico2011-02-131-3/+4
| | | | | | Errors returned from --update-use-local-desc and --update-changelogs are no longer ignored with --tolerant. This will fix part of bug #354687.
* Tweak PollScheduler signal handling.Zac Medico2011-01-151-3/+7
|
* Add PollScheduler.terminate() for interruption.Zac Medico2011-01-151-1/+24
| | | | | This allows PollScheduler instances to do basic cleanup and terminate gracefully when SIGINT or SIGTERM signals are received.