├── .editorconfig ├── .github └── workflows │ ├── black.yml │ ├── ci.yml │ └── flake.yml ├── .gitignore ├── .gitignorerevs ├── CONTRIBUTING.md ├── COPYING ├── CREDITS ├── DEVELOPING ├── NEWS ├── README.md ├── THANKS ├── bin ├── ebump ├── eclean ├── eclean-dist ├── eclean-pkg ├── ekeyword ├── enalyze ├── epkginfo ├── equery ├── eread ├── eshowkw ├── euse ├── imlate ├── merge-driver-ekeyword ├── meson.build ├── revdep-rebuild └── revdep-rebuild.sh ├── cmdtests ├── README.txt ├── cmds.txt └── runtests.sh ├── data ├── 99gentoolkit-env ├── eclean │ ├── distfiles.exclude │ └── packages.exclude ├── meson.build ├── revdep-rebuild │ └── 99revdep-rebuild └── tmpfiles.d │ └── revdep-rebuild.conf ├── man ├── ebump.1 ├── eclean.1 ├── enalyze.1 ├── epkginfo.1 ├── equery.1 ├── eread.1 ├── eshowkw.1 ├── euse.1 ├── imlate.1 ├── meson.build └── revdep-rebuild.1 ├── meson.build ├── meson_options.txt ├── pym ├── gentoolkit │ ├── __init__.py │ ├── atom.py │ ├── base.py │ ├── cpv.py │ ├── dbapi.py │ ├── dependencies.py │ ├── eclean │ │ ├── __init__.py │ │ ├── clean.py │ │ ├── cli.py │ │ ├── exclude.py │ │ ├── meson.build │ │ ├── output.py │ │ └── search.py │ ├── ekeyword │ │ ├── README │ │ ├── __init__.py │ │ ├── ekeyword.py │ │ ├── meson.build │ │ ├── pytest.ini │ │ ├── test_ekeyword.py │ │ └── tests │ │ │ ├── meson.build │ │ │ ├── process-1.ebuild │ │ │ └── profiles │ │ │ ├── arch-only │ │ │ └── profiles │ │ │ │ └── arch.list │ │ │ ├── arches-desc │ │ │ └── profiles │ │ │ │ ├── arch.list │ │ │ │ ├── arches.desc │ │ │ │ └── profiles.desc │ │ │ ├── both │ │ │ └── profiles │ │ │ │ ├── arch.list │ │ │ │ └── profiles.desc │ │ │ ├── none │ │ │ └── profiles │ │ │ │ └── .keep │ │ │ └── profiles-only │ │ │ └── profiles │ │ │ └── profiles.desc │ ├── enalyze │ │ ├── __init__.py │ │ ├── analyze.py │ │ ├── lib.py │ │ ├── meson.build │ │ ├── output.py │ │ └── rebuild.py │ ├── eprefix.py │ ├── equery │ │ ├── __init__.py │ │ ├── belongs.py │ │ ├── check.py │ │ ├── depends.py │ │ ├── depgraph.py │ │ ├── files.py │ │ ├── has.py │ │ ├── hasuse.py │ │ ├── keywords.py │ │ ├── list_.py │ │ ├── meson.build │ │ ├── meta.py │ │ ├── size.py │ │ ├── uses.py │ │ └── which.py │ ├── errors.py │ ├── eshowkw │ │ ├── __init__.py │ │ ├── display_pretty.py │ │ ├── keywords_content.py │ │ ├── keywords_header.py │ │ └── meson.build │ ├── flag.py │ ├── formatters.py │ ├── helpers.py │ ├── imlate │ │ ├── __init__.py │ │ ├── imlate.py │ │ └── meson.build │ ├── keyword.py │ ├── merge_driver_ekeyword │ │ ├── __init__.py │ │ ├── merge_driver_ekeyword.py │ │ ├── meson.build │ │ ├── pytest.ini │ │ ├── test_merge_driver_ekeyword.py │ │ └── tests │ │ │ ├── Makefile │ │ │ ├── conflict-near-KEYWORDS │ │ │ ├── A.ebuild │ │ │ ├── B.ebuild │ │ │ ├── common-ancestor.ebuild │ │ │ └── expected.ebuild │ │ │ ├── meson.build │ │ │ ├── multiple-KEYWORDS-conflict │ │ │ ├── A.ebuild │ │ │ ├── B.ebuild │ │ │ ├── common-ancestor.ebuild │ │ │ └── expected.ebuild │ │ │ ├── non-KEYWORDS-conflict │ │ │ ├── A.ebuild │ │ │ ├── B.ebuild │ │ │ └── common-ancestor.ebuild │ │ │ └── single-KEYWORDS-conflict │ │ │ ├── A.ebuild │ │ │ ├── B.ebuild │ │ │ ├── common-ancestor.ebuild │ │ │ └── expected.ebuild │ ├── meson.build │ ├── module_base.py │ ├── package.py │ ├── pprinter.py │ ├── profile.py │ ├── query.py │ ├── revdep_rebuild │ │ ├── __init__.py │ │ ├── analyse.py │ │ ├── assign.py │ │ ├── cache.py │ │ ├── collect.py │ │ ├── meson.build │ │ ├── rebuild.py │ │ ├── runner.py │ │ ├── settings.py │ │ └── stuff.py │ ├── sets.py │ ├── test │ │ ├── __init__.py │ │ ├── eclean │ │ │ ├── Packages │ │ │ ├── __init__.py │ │ │ ├── creator.py │ │ │ ├── distfiles.exclude │ │ │ ├── distsupport.py │ │ │ ├── meson.build │ │ │ ├── test_clean.py │ │ │ ├── test_search.py │ │ │ └── testdistfiles.tar.gz │ │ ├── equery │ │ │ ├── __init__.py │ │ │ ├── meson.build │ │ │ └── test_init.py │ │ ├── meson.build │ │ ├── test_atom.py │ │ ├── test_cpv.py │ │ ├── test_dependencies.py │ │ ├── test_helpers.py │ │ ├── test_keyword.py │ │ ├── test_profile.py │ │ ├── test_query.py │ │ └── test_syntax.py │ ├── textwrap_.py │ └── versionmatch.py └── meson.build ├── pyproject.toml └── tox.ini /.editorconfig: -------------------------------------------------------------------------------- 1 | # Copyright 2017-2020 Gentoo Authors 2 | 3 | root = true 4 | 5 | [*] 6 | charset = utf-8 7 | end_of_line = lf 8 | indent_style = tab 9 | indent_size = 4 10 | tab_width = 4 11 | insert_final_newline = true 12 | trim_trailing_whitespace = true 13 | 14 | [*.{py,yaml,yml}] 15 | indent_style = space 16 | 17 | [pylintrc] 18 | indent_style = space 19 | 20 | [*.py] 21 | profile = black 22 | -------------------------------------------------------------------------------- /.github/workflows/black.yml: -------------------------------------------------------------------------------- 1 | name: Lint 2 | 3 | on: [push, pull_request] 4 | 5 | jobs: 6 | lint: 7 | runs-on: ubuntu-latest 8 | steps: 9 | - uses: actions/checkout@v2 10 | - uses: psf/black@stable 11 | -------------------------------------------------------------------------------- /.github/workflows/ci.yml: -------------------------------------------------------------------------------- 1 | name: Unit tests 2 | 3 | on: [push, pull_request] 4 | 5 | jobs: 6 | build: 7 | 8 | runs-on: ubuntu-latest 9 | strategy: 10 | matrix: 11 | python-version: 12 | - '3.9' 13 | - '3.10' 14 | - '3.11' 15 | - '3.12-dev' 16 | - 'pypy-3.9' 17 | - 'pypy-3.10' 18 | 19 | env: 20 | # TODO: get this dynamically 21 | PORTAGE_VERSION: "3.0.57" 22 | 23 | steps: 24 | - uses: actions/checkout@v2 25 | - name: Set up Python ${{ matrix.python-version }} 26 | uses: actions/setup-python@v2 27 | with: 28 | python-version: ${{ matrix.python-version }} 29 | - name: Install dependencies 30 | run: | 31 | set -xe 32 | python -VV 33 | python -m site 34 | python -m pip install --upgrade pip 35 | # setuptools needed for 3.12+ because of https://github.com/mesonbuild/meson/issues/7702. 36 | python -m pip install meson ninja setuptools pytest 37 | - name: Install portage 38 | run: | 39 | mkdir portage 40 | wget -qO - "https://github.com/gentoo/portage/archive/portage-${PORTAGE_VERSION}.tar.gz" | tar xz -C portage --strip-components=1 41 | sudo groupadd -g 250 portage 42 | sudo useradd -g portage -d /var/tmp/portage -s /bin/false -u 250 portage 43 | - name: Setup gentoo env (required by portage) 44 | run: | 45 | sudo mkdir -p /var/db/repos/gentoo /etc/portage /var/cache/distfiles 46 | wget -qO - "https://github.com/gentoo-mirror/gentoo/archive/master.tar.gz" | sudo tar xz -C /var/db/repos/gentoo --strip-components=1 47 | sudo wget "https://www.gentoo.org/dtd/metadata.dtd" -O /var/cache/distfiles/metadata.dtd 48 | sudo wget "https://gitweb.gentoo.org/proj/portage.git/plain/cnf/repos.conf" -O /etc/portage/repos.conf 49 | sudo ln -s /var/db/repos/gentoo/profiles/default/linux/amd64/17.1/systemd /etc/portage/make.profile 50 | - name: Test meson install --destdir /tmp/install-root 51 | run: | 52 | echo -e "[binaries]\npython = '$(command -v python)'" > /tmp/native.ini 53 | meson setup -Dtests=true --native-file /tmp/native.ini /tmp/build . 54 | meson install -C /tmp/build --destdir /tmp/install-root 55 | - name: Run tests for ${{ matrix.python-version }} 56 | run: | 57 | export PYTHONPATH="${PWD}/portage/lib"${PYTHONPATH:+:}${PYTHONPATH} 58 | export PATH="${PWD}/portage/bin":${PATH} 59 | meson test -C /tmp/build --verbose 60 | -------------------------------------------------------------------------------- /.github/workflows/flake.yml: -------------------------------------------------------------------------------- 1 | name: Code Quality 2 | 3 | on: [push, pull_request] 4 | 5 | jobs: 6 | build: 7 | 8 | runs-on: ubuntu-latest 9 | 10 | steps: 11 | - uses: actions/checkout@v2 12 | - name: Set up Python 13 | uses: actions/setup-python@v2 14 | - name: Install flake 15 | run: | 16 | python -m pip install --upgrade pip 17 | pip install flake8 18 | - name: Run flake 19 | run: | 20 | flake8 pym 21 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | build 2 | __pycache__ 3 | *.py[c,o] 4 | dist 5 | /.tox 6 | -------------------------------------------------------------------------------- /.gitignorerevs: -------------------------------------------------------------------------------- 1 | # Run entire repository through black. Also, change tabs to spaces 2 | bbcd72b5fe85fe9bbca1913f8aa22077d94e75d0 3 | # Reformat with black 22.1.0 4 | 76c188b5189375b3b3b7c92f31491990e29a1669 5 | # */*: Reformat with newer Black 6 | 5318fb2032cf24beafdda843af83c0a56d6c9dfe 7 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | Contributing 2 | ============ 3 | Gentoo Developers have full priviledges to the gentoolkit repository and 4 | any Gentoo developer can do work on the gentoolkit source. We only ask that you 5 | keep the following in mind: 6 | 7 | - If you want to do a major change (i.e rewrite/refactor something), please talk 8 | to us before pushing any commits. If you break something, please fix it. 9 | - All members of the Portage or Portage Tools projects are authorized to create 10 | a new release of gentoolkit or gentoolkit-dev. 11 | - All other Gentoo Developers are authorized to create a new release if it is 12 | coordinated with fuzzyray and/or dolsen. 13 | - If you create a release and it breaks, please fix it. 14 | 15 | Any non Gentoo developers who wish to contribute, the best way to get 16 | started is by cloning a copy of the repository and submitting patches to 17 | bugzilla. Additionally, we can be found in the #gentoo-portage IRC 18 | channel. 19 | 20 | Formatting 21 | ========== 22 | We use [black](https://pypi.org/project/black/) to format the code 23 | base. Please make sure you run it against any PRs prior to submitting 24 | (otherwise we'll probably reject it). 25 | 26 | There are [ways to integrate](https://black.readthedocs.io/en/stable/integrations/editors.html) 27 | black into your text editor and/or IDE. 28 | 29 | You can also set up a git hook to check your commits, in case you don't want 30 | editor integration. Something like this: 31 | 32 | ```sh 33 | # .git/hooks/pre-commit (don't forget to chmod +x) 34 | 35 | #!/bin/bash 36 | black --check --diff . 37 | ``` 38 | 39 | To ignore reformatting commits (which are listed in `.gitignorerevs`) you can do 40 | the following: 41 | 42 | ```sh 43 | git config blame.ignoreRevsFile .gitignorerevs 44 | ``` 45 | 46 | Adding or modifying code 47 | ======================== 48 | - If you add new code, best practice is to write a test for it. 49 | - If you're modifying code that doesn't have a test and you can write a test 50 | for it, please do. 51 | - Before committing your changes, run "tox" to ensure that you didn't break 52 | tests or introduced a flake8 error. 53 | - If flake8 raises a warning or error that you don't agree with, it's probably 54 | better to just change your code. If you're sure you have a good reason for 55 | doing what you're doing, you can add "# noqa" at the end of the line to 56 | silence it. 57 | 58 | Creating a release 59 | ================== 60 | Note: We are using VERSION="0.3.0" simply as an example. 61 | 62 | ```sh 63 | # Run Gentoolkit's test suite, make sure it passes: 64 | # Note: requires dev-python/snakeoil 65 | ./setup.py test 66 | 67 | # Create a source distribution (you need to add VERSION here): 68 | VERSION="0.3.0" ./setup.py sdist 69 | # Transfer dist/gentoolkit-0.3.0.tar.gz to dev.gentoo.org:/space/distfiles-local 70 | # scp dist/gentoolkit-0.3.0.tar.gz username@dev.gentoo.org:/space/distfiles-local 71 | 72 | # Clean up temporary files: 73 | ./setup.py clean -a 74 | git status 75 | # rm or mv any untracked files/directories 76 | 77 | # Create a tag for the release 78 | git tag gentoolkit-0.3.0 79 | git push origin gentoolkit-0.3.0 80 | ``` 81 | -------------------------------------------------------------------------------- /CREDITS: -------------------------------------------------------------------------------- 1 | 2 | This is an incomplete list of people who have contributed non- 3 | trivial patches to gentoolkit-0.3.0 and later, in the spirit of 4 | the Linux kernel CREDITS file. It is sorted alphabetically by 5 | name (N). Other fields are email (E) and description (D). 6 | We'd like to thank: 7 | 8 | ------------------------------------------------------------------------------- 9 | 10 | N: Brian Dolbec 11 | E: dol-sen@users.sourceforge.net 12 | D: Separating dependency gathering functionality from output in depends.py. 13 | 14 | 15 | 16 | # vim: set ts=8 sw=8 tw=80: 17 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | [![Unit tests](https://github.com/gentoo/gentoolkit/actions/workflows/ci.yml/badge.svg)](https://github.com/gentoo/gentoolkit/actions/workflows/ci.yml) 2 | 3 | MOTIVATION 4 | ========== 5 | 6 | The gentoolkit package contains a collection of useful administration scripts 7 | particular to the Gentoo Linux distribution. It contains rough drafts and 8 | implementations of features that may in time make it into Portage, or into 9 | full-fledged tools in their own right. 10 | 11 | CONTENTS 12 | ======== 13 | 14 | gentoolkit 15 | ---------- 16 | - ebump - Ebuild revision bumper 17 | - eclean - tool to clean up outdated distfiles and packages 18 | - ekeyword - modify package KEYWORDS 19 | - enalyze - Analyze all installed pkgs or rebuild package.* files 20 | - epkginfo - wrapper to equery: Display metadata about a given package. 21 | - equery - replacement for etcat and qpkg 22 | - eread - script to read portage log items from einfo, ewarn etc. 23 | - eshowkw - Display keywords for specified package(s) 24 | - euse - tool to manage USE flags 25 | - imlate - Displays candidates for keywords for an architecture... 26 | - qpkg - convient package query tool (deprecated) 27 | - revdep-rebuild - scans/fixes broken shared libs and binaries 28 | 29 | IMPROVEMENTS 30 | ============ 31 | 32 | Any suggestions for improvements should be sent to tools-portage@gentoo.org, or 33 | added as a bug assigned to us. 34 | 35 | We only accept new contributions if they are written in Bash or Python. 36 | -------------------------------------------------------------------------------- /THANKS: -------------------------------------------------------------------------------- 1 | * eclean 2 | The starting point ideas were found here: 3 | http://forums.gentoo.org/viewtopic.php?t=3011 4 | 5 | Thanks to eswanson and far for their contributions, and to wolf31o2 for his 6 | support. Thanks also to karltk, some of this code was at some point inspired 7 | by his "equery" tool. And thanks to people who had a look on bug #33877: 8 | Benjamin Braatz, fuzzyray, genone, etc. 9 | -------------------------------------------------------------------------------- /bin/eclean: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | 3 | """Copyright 2003-2010 Gentoo Foundation 4 | Distributed under the terms of the GNU General Public License v2 5 | """ 6 | 7 | # Meta: 8 | __author__ = "Thomas de Grenier de Latour (tgl), " + \ 9 | "modular re-write by: Brian Dolbec (dol-sen)" 10 | __email__ = "degrenier@easyconnect.fr, " + \ 11 | "brian.dolbec@gmail.com" 12 | __version__ = "git" 13 | __productname__ = "eclean" 14 | __description__ = "A cleaning tool for Gentoo distfiles and binaries." 15 | 16 | 17 | import sys 18 | 19 | # This block ensures that ^C interrupts are handled quietly. 20 | try: 21 | import signal 22 | 23 | def exithandler(signum, frame): 24 | signal.signal(signal.SIGINT, signal.SIG_IGN) 25 | signal.signal(signal.SIGTERM, signal.SIG_IGN) 26 | print() 27 | sys.exit(1) 28 | 29 | signal.signal(signal.SIGINT, exithandler) 30 | signal.signal(signal.SIGTERM, exithandler) 31 | signal.signal(signal.SIGPIPE, signal.SIG_DFL) 32 | 33 | except KeyboardInterrupt: 34 | print() 35 | sys.exit(1) 36 | 37 | 38 | from gentoolkit.eclean.cli import main 39 | 40 | try: 41 | main() 42 | except KeyboardInterrupt: 43 | print("Aborted.") 44 | sys.exit(130) 45 | sys.exit(0) 46 | -------------------------------------------------------------------------------- /bin/eclean-dist: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | 3 | """Copyright 2003-2010 Gentoo Foundation 4 | Distributed under the terms of the GNU General Public License v2 5 | """ 6 | 7 | # Meta: 8 | __author__ = "Thomas de Grenier de Latour (tgl), " + \ 9 | "modular re-write by: Brian Dolbec (dol-sen)" 10 | __email__ = "degrenier@easyconnect.fr, " + \ 11 | "brian.dolbec@gmail.com" 12 | __version__ = "git" 13 | __productname__ = "eclean" 14 | __description__ = "A cleaning tool for Gentoo distfiles and binaries." 15 | 16 | 17 | import sys 18 | 19 | # This block ensures that ^C interrupts are handled quietly. 20 | try: 21 | import signal 22 | 23 | def exithandler(signum, frame): 24 | signal.signal(signal.SIGINT, signal.SIG_IGN) 25 | signal.signal(signal.SIGTERM, signal.SIG_IGN) 26 | print() 27 | sys.exit(1) 28 | 29 | signal.signal(signal.SIGINT, exithandler) 30 | signal.signal(signal.SIGTERM, exithandler) 31 | signal.signal(signal.SIGPIPE, signal.SIG_DFL) 32 | 33 | except KeyboardInterrupt: 34 | print() 35 | sys.exit(1) 36 | 37 | 38 | from gentoolkit.eclean.cli import main 39 | 40 | try: 41 | main() 42 | except KeyboardInterrupt: 43 | print("Aborted.") 44 | sys.exit(130) 45 | sys.exit(0) 46 | -------------------------------------------------------------------------------- /bin/eclean-pkg: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | 3 | """Copyright 2003-2010 Gentoo Foundation 4 | Distributed under the terms of the GNU General Public License v2 5 | """ 6 | 7 | # Meta: 8 | __author__ = "Thomas de Grenier de Latour (tgl), " + \ 9 | "modular re-write by: Brian Dolbec (dol-sen)" 10 | __email__ = "degrenier@easyconnect.fr, " + \ 11 | "brian.dolbec@gmail.com" 12 | __version__ = "git" 13 | __productname__ = "eclean" 14 | __description__ = "A cleaning tool for Gentoo distfiles and binaries." 15 | 16 | 17 | import sys 18 | 19 | # This block ensures that ^C interrupts are handled quietly. 20 | try: 21 | import signal 22 | 23 | def exithandler(signum, frame): 24 | signal.signal(signal.SIGINT, signal.SIG_IGN) 25 | signal.signal(signal.SIGTERM, signal.SIG_IGN) 26 | print() 27 | sys.exit(1) 28 | 29 | signal.signal(signal.SIGINT, exithandler) 30 | signal.signal(signal.SIGTERM, exithandler) 31 | signal.signal(signal.SIGPIPE, signal.SIG_DFL) 32 | 33 | except KeyboardInterrupt: 34 | print() 35 | sys.exit(1) 36 | 37 | 38 | from gentoolkit.eclean.cli import main 39 | 40 | try: 41 | main() 42 | except KeyboardInterrupt: 43 | print("Aborted.") 44 | sys.exit(130) 45 | sys.exit(0) 46 | -------------------------------------------------------------------------------- /bin/ekeyword: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # 3 | # Copyright 2002-2017 Gentoo Foundation 4 | # Distributed under the terms of the GNU General Public License v2 or later 5 | 6 | """Manage KEYWORDS in ebuilds easily. 7 | 8 | This tool provides a simple way to add or update KEYWORDS in a set of ebuilds. 9 | Each command-line argument is processed in order, so that keywords are added to 10 | the current list as they appear, and ebuilds are processed as they appear. 11 | 12 | """ 13 | 14 | import os 15 | import sys 16 | # This block ensures that ^C interrupts are handled quietly. 17 | try: 18 | import signal 19 | 20 | def exithandler(signum, frame): 21 | signal.signal(signal.SIGINT, signal.SIG_IGN) 22 | signal.signal(signal.SIGTERM, signal.SIG_IGN) 23 | print() 24 | sys.exit(1) 25 | 26 | signal.signal(signal.SIGINT, exithandler) 27 | signal.signal(signal.SIGTERM, exithandler) 28 | signal.signal(signal.SIGPIPE, signal.SIG_DFL) 29 | 30 | except KeyboardInterrupt: 31 | print() 32 | sys.exit(1) 33 | 34 | from gentoolkit.ekeyword import ekeyword 35 | 36 | try: 37 | ekeyword.main(sys.argv[1:]) 38 | except KeyboardInterrupt: 39 | print("Aborted.") 40 | sys.exit(130) 41 | sys.exit(0) 42 | -------------------------------------------------------------------------------- /bin/enalyze: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # 3 | # Copyright 2010 Brian Dolbec 4 | # Copyright 2002-2010 Gentoo Foundation 5 | # Distributed under the terms of the GNU General Public License v2 or later 6 | 7 | """'enalyze' is a flexible utility for Gentoo linux which can display various 8 | information about installed packages, such as the USE flags used and the 9 | packages that use them. It can also be used to help rebuild /etc/portage/package.* 10 | files in the event of corruption, and possibly more. 11 | """ 12 | 13 | import sys 14 | # This block ensures that ^C interrupts are handled quietly. 15 | try: 16 | import signal 17 | 18 | def exithandler(signum, frame): 19 | signal.signal(signal.SIGINT, signal.SIG_IGN) 20 | signal.signal(signal.SIGTERM, signal.SIG_IGN) 21 | print() 22 | sys.exit(1) 23 | 24 | signal.signal(signal.SIGINT, exithandler) 25 | signal.signal(signal.SIGTERM, exithandler) 26 | signal.signal(signal.SIGPIPE, signal.SIG_DFL) 27 | 28 | except KeyboardInterrupt: 29 | print() 30 | sys.exit(1) 31 | 32 | from gentoolkit import enalyze, errors 33 | 34 | try: 35 | enalyze.main() 36 | except errors.GentoolkitException as err: 37 | if '--debug' in sys.argv: 38 | raise 39 | else: 40 | from gentoolkit import pprinter as pp 41 | sys.stderr.write(pp.error(str(err))) 42 | print() 43 | print("Add '--debug' to global options for traceback.") 44 | sys.exit(1) 45 | -------------------------------------------------------------------------------- /bin/epkginfo: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # 3 | # Copyright 2009 Gentoo Foundation 4 | # Distributed under the terms of the GNU General Public License v2 or later 5 | 6 | """Shortcut to equery meta""" 7 | 8 | __authors__ = ( 9 | 'Douglas Anderson : equery meta', 10 | 'Ned Ludd : first full implimentation' 11 | 'Eldad Zack : earch', 12 | 'Eric Olinger : metadata' 13 | ) 14 | 15 | import sys 16 | 17 | from gentoolkit import equery, errors 18 | from gentoolkit.equery import mod_usage 19 | from gentoolkit.equery.meta import main, print_help 20 | from portage.exception import AmbiguousPackageName 21 | 22 | 23 | def print_epkginfo_help(): 24 | print(mod_usage(mod_name="epkginfo")) 25 | print() 26 | print_help(with_usage=False) 27 | 28 | 29 | equery.initialize_configuration() 30 | args = sys.argv[1:] 31 | if not args or {'-h', '--help'}.intersection(args): 32 | print_epkginfo_help() 33 | else: 34 | try: 35 | main(args) 36 | except AmbiguousPackageName as e: 37 | pkgs = e.args[0] 38 | for candidate in pkgs: 39 | print(candidate) 40 | 41 | from gentoolkit import pprinter as pp 42 | from os.path import basename # To get the short name 43 | 44 | print(file=sys.stderr) 45 | print(pp.error("The short ebuild name '%s' is ambiguous. Please specify" % basename(pkgs[0])), 46 | file=sys.stderr, end="") 47 | pp.die(1, "one of the above fully-qualified ebuild names instead.") 48 | except errors.GentoolkitException as err: 49 | from gentoolkit import pprinter as pp 50 | pp.die(1, str(err)) 51 | 52 | # vim: set ts=4 sw=4 tw=79: 53 | -------------------------------------------------------------------------------- /bin/equery: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # 3 | # Copyright 2002-2009 Gentoo Foundation 4 | # Distributed under the terms of the GNU General Public License v2 or later 5 | 6 | """equery is a flexible utility for Gentoo linux which can display various 7 | information about packages, such as the files they own, their USE flags, 8 | the MD5 sum of each file owned by a given package, and many other things. 9 | """ 10 | 11 | import os 12 | import sys 13 | # This block ensures that ^C interrupts are handled quietly. 14 | try: 15 | import signal 16 | 17 | def exithandler(signum, frame): 18 | signal.signal(signal.SIGINT, signal.SIG_IGN) 19 | signal.signal(signal.SIGTERM, signal.SIG_IGN) 20 | print() 21 | sys.exit(1) 22 | 23 | signal.signal(signal.SIGINT, exithandler) 24 | signal.signal(signal.SIGTERM, exithandler) 25 | signal.signal(signal.SIGPIPE, signal.SIG_DFL) 26 | 27 | except KeyboardInterrupt: 28 | print() 29 | sys.exit(1) 30 | 31 | from gentoolkit import equery, errors 32 | import warnings 33 | 34 | 35 | def formatwarning(message, category, filename, llineno, line=None): 36 | from gentoolkit import pprinter as pp 37 | return pp.warn(str(message)) 38 | 39 | 40 | if '--debug' not in sys.argv and not bool(os.getenv('DEBUG', False)): 41 | warnings.formatwarning = formatwarning 42 | 43 | try: 44 | equery.main(sys.argv) 45 | except errors.GentoolkitNonZeroExit as err: 46 | sys.exit(err.return_code) 47 | except errors.GentoolkitException as err: 48 | if '--debug' in sys.argv or bool(os.getenv('DEBUG', False)): 49 | raise 50 | else: 51 | from gentoolkit import pprinter as pp 52 | sys.stderr.write(pp.error(str(err))) 53 | if err.is_serious: 54 | print() 55 | print("Add '--debug' to global options for traceback.") 56 | sys.exit(1) 57 | -------------------------------------------------------------------------------- /bin/eread: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # This is a script to read portage log items from einfo, ewarn etc, new in the 4 | # portage-2.1 series. 5 | # 6 | # Author: Donnie Berkholz 7 | # Updated by: Uwe Klosa 8 | # Updated by: Slawomir Nizio 9 | 10 | # Get prefix 11 | EPREFIX=${EPREFIX:-$(portageq envvar EPREFIX)} 12 | 13 | # set decent PATH for bug 172969 14 | 15 | PATH=${EPREFIX}/usr/bin:${EPREFIX}/bin:${PATH} 16 | 17 | # Set ELOGDIR 18 | PORT_LOGDIR="$(portageq envvar PORT_LOGDIR)" 19 | [ "$PORT_LOGDIR" = "" ] && PORT_LOGDIR="${EPREFIX}/var/log/portage" 20 | ELOGDIR="$PORT_LOGDIR/elog" 21 | 22 | # Verify that ELOGDIR exists 23 | if [ ! -d "$ELOGDIR" ]; then 24 | echo "ELOG directory: $ELOGDIR does not exist!" 25 | exit 1 26 | fi 27 | 28 | # Use the pager from the users environment 29 | [ -z "$PAGER" ] && PAGER="less" 30 | 31 | # Set up select prompt 32 | PS3="Choice? " 33 | 34 | SORT=${EREAD_SORT_ORDER} 35 | 36 | find_unsorted() { 37 | find . -name '*:*:*.log*' | sed -e "s:\./::g" 38 | } 39 | find_by_name() { 40 | find . -name '*:*:*.log*' | sort | sed -e "s:\./::g" 41 | } 42 | find_by_time() { 43 | find . -name '*:*:*.log*' | sort -k 3 -t : | sed -e "s:\./::g" 44 | } 45 | find_files() { 46 | case ${SORT} in 47 | alphabet) 48 | find_by_name 49 | ;; 50 | time) 51 | find_by_time 52 | ;; 53 | *) 54 | find_unsorted 55 | ;; 56 | esac 57 | } 58 | 59 | select_loop() { 60 | until [[ -n ${QUIT} ]]; do 61 | ANY_FILES=$(find_files) 62 | 63 | if [[ -z ${ANY_FILES} ]]; then 64 | echo "No log items to read" 65 | break 66 | fi 67 | 68 | echo 69 | echo "This is a list of portage log items. Choose a number to view that file or type q to quit." 70 | echo 71 | 72 | # Pick which file to read 73 | select FILE in ${ANY_FILES}; do 74 | case ${REPLY} in 75 | q) 76 | echo "Quitting" 77 | QUIT="yes" 78 | break 79 | ;; 80 | a) 81 | SORT="alphabet" 82 | ;; 83 | t) 84 | SORT="time" 85 | ;; 86 | *) 87 | if [ -f "$FILE" ]; then 88 | ${PAGER} ${FILE} 89 | read -p "Delete file? [y/N] " DELETE 90 | case ${DELETE} in 91 | q) 92 | echo "Quitting" 93 | QUIT="yes" 94 | break 95 | ;; 96 | y|Y) 97 | rm -f ${FILE} 98 | SUCCESS=$? 99 | if [[ ${SUCCESS} = 0 ]]; then 100 | echo "Deleted ${FILE}" 101 | else 102 | echo "Unable to delete ${FILE}" 103 | fi 104 | ;; 105 | # Empty string defaults to N (save file) 106 | n|N|"") 107 | echo "Saving ${FILE}" 108 | ;; 109 | *) 110 | echo "Invalid response. Saving ${FILE}" 111 | ;; 112 | esac 113 | else 114 | echo 115 | echo "Invalid response." 116 | fi 117 | ;; 118 | esac 119 | break 120 | done 121 | done 122 | } 123 | 124 | pushd ${ELOGDIR} > /dev/null 125 | 126 | select_loop 127 | 128 | popd > /dev/null 129 | -------------------------------------------------------------------------------- /bin/eshowkw: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # Copyright 2010 Gentoo Foundation 3 | # Distributed under the terms of the GNU General Public License v2 4 | 5 | import sys 6 | from gentoolkit.eshowkw import main as emain 7 | 8 | sys.exit(emain(sys.argv[1:])) 9 | -------------------------------------------------------------------------------- /bin/imlate: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # 3 | # Copyright 2002-2017 Gentoo Foundation 4 | # Distributed under the terms of the GNU General Public License v2 or later 5 | 6 | """Manage KEYWORDS in ebuilds easily. 7 | 8 | This tool provides a simple way to add or update KEYWORDS in a set of ebuilds. 9 | Each command-line argument is processed in order, so that keywords are added to 10 | the current list as they appear, and ebuilds are processed as they appear. 11 | 12 | """ 13 | 14 | import os 15 | import sys 16 | # This block ensures that ^C interrupts are handled quietly. 17 | try: 18 | import signal 19 | 20 | def exithandler(signum, frame): 21 | signal.signal(signal.SIGINT, signal.SIG_IGN) 22 | signal.signal(signal.SIGTERM, signal.SIG_IGN) 23 | print() 24 | sys.exit(1) 25 | 26 | signal.signal(signal.SIGINT, exithandler) 27 | signal.signal(signal.SIGTERM, exithandler) 28 | signal.signal(signal.SIGPIPE, signal.SIG_DFL) 29 | 30 | except KeyboardInterrupt: 31 | print() 32 | sys.exit(1) 33 | 34 | from gentoolkit.imlate import imlate 35 | 36 | try: 37 | imlate.main() 38 | except KeyboardInterrupt: 39 | print("Aborted.") 40 | sys.exit(130) 41 | sys.exit(0) 42 | -------------------------------------------------------------------------------- /bin/merge-driver-ekeyword: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | # 3 | # Copyright 2020-2024 Gentoo Authors 4 | # Distributed under the terms of the GNU General Public License v2 or later 5 | 6 | import sys 7 | 8 | from gentoolkit.merge_driver_ekeyword import merge_driver_ekeyword 9 | 10 | 11 | sys.exit(merge_driver_ekeyword.main(sys.argv[1:])) 12 | -------------------------------------------------------------------------------- /bin/meson.build: -------------------------------------------------------------------------------- 1 | py_bins = [ 2 | 'eclean', 3 | 'eclean-dist', 4 | 'eclean-pkg', 5 | 'ekeyword', 6 | 'enalyze', 7 | 'epkginfo', 8 | 'equery', 9 | 'eread', 10 | 'eshowkw', 11 | 'imlate', 12 | 'merge-driver-ekeyword', 13 | 'revdep-rebuild', 14 | ] 15 | 16 | ebump = configure_file( 17 | input : 'ebump', 18 | output : 'ebump', 19 | configuration : conf_data 20 | ) 21 | 22 | euse = configure_file( 23 | input : 'euse', 24 | output : 'euse', 25 | configuration : conf_data 26 | ) 27 | 28 | revdep_rebuild_sh = configure_file( 29 | input : 'revdep-rebuild.sh', 30 | output : 'revdep-rebuild.sh', 31 | configuration : conf_data 32 | ) 33 | 34 | other_bins = [ 35 | ebump, 36 | euse, 37 | revdep_rebuild_sh, 38 | ] 39 | 40 | # It might seem sensible to use py.install_sources() to install the Python 41 | # scripts, but it's really just a wrapper around install_data that forces the 42 | # install_dir. Meson 1.2.0 and later also optimize to bytecode, but Gentoo does 43 | # this in the ebuild. 44 | 45 | install_data( 46 | py_bins, 47 | install_dir : get_option('bindir'), 48 | install_mode : 'rwxr-xr-x', 49 | ) 50 | 51 | install_data( 52 | other_bins, 53 | install_dir : get_option('bindir'), 54 | install_mode : 'rwxr-xr-x', 55 | ) 56 | -------------------------------------------------------------------------------- /bin/revdep-rebuild: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # 3 | # Copyright 2010 Brian Dolbec 4 | # Copyright 2002-2010 Gentoo Foundation 5 | # Distributed under the terms of the GNU General Public License v2 or later 6 | 7 | """'revdep-rebuild' scans libraries and binaries for missing shared library dependencies and attempts to fix them by re-emerging 8 | those broken binaries and shared libraries. It is useful when an upgraded package breaks other software packages that are 9 | dependent upon the upgraded package. 10 | """ 11 | 12 | import sys 13 | # This block ensures that ^C interrupts are handled quietly. 14 | try: 15 | import signal 16 | 17 | def exithandler(signum, frame): 18 | signal.signal(signal.SIGINT, signal.SIG_IGN) 19 | signal.signal(signal.SIGTERM, signal.SIG_IGN) 20 | print() 21 | sys.exit(1) 22 | 23 | signal.signal(signal.SIGINT, exithandler) 24 | signal.signal(signal.SIGTERM, exithandler) 25 | signal.signal(signal.SIGPIPE, signal.SIG_DFL) 26 | 27 | 28 | except KeyboardInterrupt: 29 | print() 30 | sys.exit(1) 31 | 32 | from gentoolkit import errors 33 | from gentoolkit.revdep_rebuild import rebuild 34 | 35 | try: 36 | success = rebuild.main(rebuild.parse_options()) 37 | sys.exit(success) 38 | except errors.GentoolkitException as err: 39 | if '--debug' in sys.argv: 40 | raise 41 | else: 42 | from gentoolkit import pprinter as pp 43 | sys.stderr.write(pp.error(str(err))) 44 | print() 45 | print("Add '--debug' to global options for traceback.") 46 | sys.exit(1) 47 | -------------------------------------------------------------------------------- /cmdtests/README.txt: -------------------------------------------------------------------------------- 1 | Use the "runtests.sh" script to test the output of all commands in "cmds.txt" 2 | against the output that the version of gentoolkit installed on the system 3 | yields. 4 | 5 | It's a great way to verify that a refactoring didn't affect output. 6 | 7 | Usage: 8 | 9 | $ cd cmdtests 10 | $ ./runtests.sh 11 | 12 | You can also test against a specific version of gentoolkit instead. Clone a 13 | copy of gentoolkit to test against and then do: 14 | 15 | $ cd cmdtests 16 | $ ./runtests.sh /path/to/othergentoolkit/pym 17 | -------------------------------------------------------------------------------- /cmdtests/cmds.txt: -------------------------------------------------------------------------------- 1 | equery meta dev-lang/python 2 | equery d -a llvm 3 | equery l "vim*" 4 | -------------------------------------------------------------------------------- /cmdtests/runtests.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | TEST_AGAINST_PYTHON_PATH=$1 4 | 5 | while read -r line; do 6 | echo "Running $line > before" 7 | PYTHONPATH="${TEST_AGAINST_PYTHON_PATH}" 8 | eval "$line" > before || exit 1 9 | echo "Running $line > after" 10 | PYTHONPATH="../pym" 11 | eval "$line" > after || exit 1 12 | DIFF=$(diff -u before after) 13 | if [[ -n $DIFF ]]; then 14 | echo "Different!" 15 | echo "$DIFF" 16 | exit 1 17 | fi 18 | done < cmds.txt 19 | 20 | rm before after 21 | echo "All commands output the exact same thing!" 22 | -------------------------------------------------------------------------------- /data/99gentoolkit-env: -------------------------------------------------------------------------------- 1 | CONFIG_PROTECT_MASK="/etc/revdep-rebuild" 2 | -------------------------------------------------------------------------------- /data/eclean/distfiles.exclude: -------------------------------------------------------------------------------- 1 | # /etc/eclean/distfiles.exclude 2 | # In this file you can list some categories or cat/pkg-name for which you want 3 | # to protect distfiles from "ecleaning". You can also name some specific files. 4 | # See `man eclean` for syntax details. 5 | .layout.conf* 6 | .mirror-cache.json 7 | layout.conf 8 | metadata.dtd 9 | metadata.xsd 10 | portage-\d\d\d\d\d\d\d\d\.tar\.bz2 11 | -------------------------------------------------------------------------------- /data/eclean/packages.exclude: -------------------------------------------------------------------------------- 1 | # /etc/eclean/packages.exclude 2 | # In this file you can list some categories or cat/pkg-name for which you want 3 | # to protect binary packages from "ecleaning". 4 | # See `man eclean` for syntax details. 5 | -------------------------------------------------------------------------------- /data/meson.build: -------------------------------------------------------------------------------- 1 | install_data( 2 | [ 3 | '99gentoolkit-env', 4 | ], 5 | install_dir : sysconfdir / 'env.d' 6 | ) 7 | 8 | install_data( 9 | [ 10 | 'eclean/packages.exclude', 11 | 'eclean/distfiles.exclude', 12 | 'revdep-rebuild/99revdep-rebuild', 13 | ], 14 | install_dir: sysconfdir, 15 | preserve_path: true 16 | ) 17 | 18 | if not system_wide 19 | subdir_done() 20 | endif 21 | -------------------------------------------------------------------------------- /data/revdep-rebuild/99revdep-rebuild: -------------------------------------------------------------------------------- 1 | # Default revdep-rebuild configuration file 2 | # 3 | # revdep-rebuild no longer uses hardcoded paths. To change the default 4 | # behavior the following variables can be changed: 5 | # 6 | # LD_LIBRARY_MASK - Mask of specially evaluated libraries 7 | # 8 | # SEARCH_DIRS - List of directories to search for executables and libraries 9 | # Use this for directories that are not included in PATH or ld.so.conf. 10 | # An application should normally not have to set this variable 11 | # 12 | # SEARCH_DIRS_MASK - List of directories to not search 13 | # Use this for directories that should not be searched by revdep-rebuild 14 | # This is normally used by binary packages such as openoffice-bin 15 | # 16 | # Note: This file is sourced using bash by the revdep-rebuild script 17 | 18 | LD_LIBRARY_MASK="libodbcinst.so libodbc.so libjava.so libjvm.so" 19 | SEARCH_DIRS="/bin /sbin /usr/bin /usr/sbin /lib* /usr/lib*" 20 | SEARCH_DIRS_MASK="/lib*/modules" 21 | 22 | -------------------------------------------------------------------------------- /data/tmpfiles.d/revdep-rebuild.conf: -------------------------------------------------------------------------------- 1 | d /var/cache/revdep-rebuild 0700 0 0 2 | -------------------------------------------------------------------------------- /man/ebump.1: -------------------------------------------------------------------------------- 1 | .TH "EBUMP" "1" "March 2017" "GENTOOLKIT" "Gentoo Administration" 2 | .SH "NAME" 3 | .LP 4 | ebump \- Gentoo: Ebuild revision bumper 5 | .SH "SYNTAX" 6 | .LP 7 | ebump [\fIoption\fP] <\fIpackage-name[-version]\fP> 8 | 9 | .SH "DESCRIPTION" 10 | 11 | .LP 12 | \fIebump\fR bumps the revision of a particular ebuild, and all auxiliary 13 | files in the files/ directory that have a matching version suffix. 14 | 15 | .LP 16 | By default, the all new revision files will be added to the VCS. 17 | 18 | .LP 19 | You must stand in the directory of the ebuild to be bumped. 20 | 21 | .SH "OPTIONS" 22 | .LP 23 | \fB\-C\fR 24 | .br 25 | \fB--no-vcs\fB 26 | .IP 27 | Do not add new files to VCS. 28 | 29 | .LP 30 | \fB\-V\fR 31 | .br 32 | \fB--version\fB 33 | .IP 34 | Display version information and exit. 35 | 36 | .LP 37 | \fB\-v\fR 38 | .br 39 | \fB--verbose\fB 40 | .IP 41 | Increase verbosity level. May be used more than once. 42 | 43 | .LP 44 | \fB\-q\fR 45 | .br 46 | \fB--quiet\fB 47 | .IP 48 | Do not output any non-essential information. 49 | 50 | .LP 51 | \fB\-a\fR 52 | .br 53 | \fB--no-auxfiles\fB 54 | .IP 55 | don't bump auxfiles (files/*) 56 | 57 | .LP 58 | \fB\-d\fR 59 | .br 60 | \fB\--delete-old\fR 61 | .IP 62 | Delete old revision and old auxiliary files from VCS. This is 63 | \fIdangerous\fR and should only be used if you know exactly what you are 64 | doing, because 65 | .br 66 | 1) the old revision may be stable on a different architecture than the one you 67 | are working on. 68 | .br 69 | 2) the auxiliary files may be required by other versions of the ebuild. 70 | .br 71 | 3) the new revision should usually undergo a period of testing before being marked stable. 72 | 73 | .SH "CONFIGURATION" 74 | 75 | .LP 76 | \fB/etc/gentoolkit/ebump.conf\fR 77 | .br 78 | \fB~/.gentoo/ebump.conf\fR 79 | .IP 80 | From these files, \fIebump\fR will load the settings 81 | .br 82 | \fBopt_verbosity\fR (default \fI1\fR) - verbosity level 0-10 83 | .br 84 | \fBopt_add_vcs\fR (default \fIy\fR) - add new files to VCS 85 | .br 86 | \fBopt_bump_auxfiles\fR (default \fIy\fR) - bump auxiliary files in files/ 87 | .br 88 | \fBopt_delete_old\fR (default \fIn\fR) - delete old revision (DANGEROUS!) 89 | 90 | .SH "SEE ALSO" 91 | .LP 92 | The rest of the utilities in \fIapp-portage/gentoolkit-dev\fR, such as 93 | \fIekeyword(1)\fR. 94 | 95 | .SH "AUTHORS" 96 | .LP 97 | Karl Trygve Kalleberg 98 | .br 99 | Christian Ruppert 100 | -------------------------------------------------------------------------------- /man/epkginfo.1: -------------------------------------------------------------------------------- 1 | .TH "EPKGINFO" "1" "August 2009" "GENTOOLKIT" "" 2 | .SH "NAME" 3 | epkginfo \- Displays metadata information from packages in portage 4 | 5 | .SH "SYNOPSIS" 6 | .BI "epkginfo " "[options] " "package name or atom" 7 | 8 | .SH "DESCRIPTION" 9 | .B Epkginfo 10 | is a shortcut to \fBequery meta\fP. For all available options and more 11 | examples, see \fBman equery\fP. 12 | 13 | .SH "EXAMPLES" 14 | .nf 15 | * app\-portage/gentoolkit [gentoo] 16 | Maintainer: tools\-portage@gentoo.org (Gentoo Portage tools team) 17 | Upstream: None specified 18 | Homepage: https://wiki.gentoo.org/wiki/Project:Portage\-Tools 19 | Location: /var/db/repos/gentoo/app\-portage/gentoolkit 20 | Keywords: 0.5.0\-r3:0: 21 | Keywords: 0.5.1\-r1:0: amd64 arm arm64 hppa ppc ppc64 sparc x86 22 | ~alpha ~amd64\-linux ~ia64 ~m68k ~mips 23 | ~ppc\-macos ~riscv ~s390 ~sparc\-solaris 24 | ~sparc64\-solaris ~x64\-cygwin ~x64\-macos 25 | ~x64\-solaris ~x86\-linux ~x86\-solaris 26 | Keywords: 9999:0: 27 | License: GPL\-2 28 | .fi 29 | 30 | .SH "AUTHORS" 31 | .LP 32 | Douglas Anderson 33 | .SH "BUGS" 34 | Please report any bugs to https://bugs.gentoo.org 35 | -------------------------------------------------------------------------------- /man/eread.1: -------------------------------------------------------------------------------- 1 | .TH "EREAD" "1" "1.0" "Donnie Berkholz" "gentoolkit" 2 | .SH "NAME" 3 | .LP 4 | eread \- Gentoo: Tool to display and manage ELOG files from portage 5 | .SH "SYNTAX" 6 | .LP 7 | eread 8 | .SH "DESCRIPTION" 9 | .LP 10 | This tool is used to display and manage ELOG files produced by portage version 2.1 and higher. 11 | .SH "USAGE" 12 | .LP 13 | You can use the following commands: 14 | .TP 15 | .B "q" 16 | Quit 17 | .TP 18 | .B "a" 19 | Sort alphabetically 20 | .TP 21 | .B "t" 22 | Sort by time 23 | .SH "ENVIRONMENT VARIABLES" 24 | The eread utility uses the PAGER environment variable to display the ELOG files. If the variable is not set, it defaults to /usr/bin/less. 25 | Another environment variable is EREAD_SORT_ORDER which can be set to specify default sort order of ELOG files. Values \fBalphabet\fP and \fBtime\fP are recognized. If EREAD_SORT_ORDER is not set or has another value, the output is unsorted. 26 | -------------------------------------------------------------------------------- /man/eshowkw.1: -------------------------------------------------------------------------------- 1 | .TH "ESHOWKW" "1" "git" "Tomáš Chvátal" "" 2 | .SH "NAME" 3 | .LP 4 | eshowkw \- Gentoo: Tool to package keywords 5 | .SH "SYNOPSIS" 6 | .B eshowkw 7 | [OPTIONS] [\-\-] [package [package ...]] 8 | .SH "DESCRIPTION" 9 | Display keywords for specified package(s) or for package that is in the current working directory. 10 | 11 | .SH "OPTIONS" 12 | .TP 13 | .B package 14 | The packages to check. (The default is to read ebuilds in the current directory) 15 | .TP 16 | .B \-h | \-\-help 17 | Print usage. 18 | .TP 19 | .B \-v | \-\-version 20 | Show version and exit. 21 | .TP 22 | .B \-a=ARCH[,ARCH ...] | \-\-arch=ARCH[,ARCH ...] 23 | Display only specified architectures. 24 | .TP 25 | .B \-A {top,bottom} | \-\-align {top,bottom} 26 | Specify alignment for descriptions. (default: bottom) 27 | .TP 28 | .B \-T {archlist,versionlist} | \-\-top\-position {archlist,versionlist} 29 | Specify which fields we want to have in top listing. (default: archlist) 30 | .TP 31 | .B \-B | \-\-bold 32 | Print out each other column in bold for easier visual separation. (default: False) 33 | .TP 34 | .B \-C | \-\-color 35 | Force colored output (default: False) 36 | .TP 37 | .B \-O | \-\-overlays 38 | Search overlays (default: False) 39 | .TP 40 | .B \-P | \-\-prefix 41 | Display prefix keywords in output. (default: False) 42 | .TP 43 | .B \-S | \-\-ignore\-slot 44 | Treat slots as irrelevant during detection of redundant packages. (default: False) 45 | .SH "BUGS" 46 | .LP 47 | Report bugs to . 48 | -------------------------------------------------------------------------------- /man/euse.1: -------------------------------------------------------------------------------- 1 | .TH "EUSE" "1" "2004-10-17" "Gentoo Linux" "Gentoo Toolkit" 2 | .SH "NAME" 3 | euse \- Gentoo: command line USE flag editor 4 | .SH "SYNOPSIS" 5 | .B euse 6 | \fI