Supplements to the repo script
Project description
Repo Find Orphans
This is a small tool that complements Google's repo
project
repository management tool. The problem it tries to solve is that
developers occasionally add subprojects to the repository without
first registering them in the repo manifest. This is not a recommended
activity in the repo workflow, but it happens frequently in large
teams. These unregistered directories become orphans, which means
the repo tool ignores them during synchronization and updates. This
tool addresses this issue by identifying these orphan directories,
which developers can choose to include in the project manifest for
tracking in the future.
Installation
There are two ways to install this tool:
- Using pip: this will install the tool into your active virtual environment or to the the global python environment. To install with pip use the following command
pip install repo-find-orphans
- Using pipx: If you want to keep your Python global environment clean or install Python CLI tools in isolated environments use the pipx option.
- First make sure pipx is installed
pip install pipx
- Then install the tool
pipx install repo-find-orphans
This will create a dedicated virtual environment for the tool and add the executable script to your ~/.local/bin
Usage
After installing Repo Find Orphans, use the provided command-line interface to search for orphan directories. Here's how you use the tool:
Open your terminal and enter the following command.
repository-find-orphans PATH_TO_MANIFEST PATH_TO_PROJECT_DIR
replace PATH_TO_MANIFEST
with your manifest file's path, which
is usually repo/default.xml
, and PATH_TO_PROJECT_DIR
with the
path to your project directory.
For example:
repo-find-orphans ./repo/default.xml .
This will scan the project directory and will try to find all projects in the project manifest file. Then it will print the list of projects that exists in the directory, but not mentioned in the manifest. You can review this output and add the missing projects to the manifest.
Troubleshooting
If you installed your tool using pipx, but get the command not found
error when you are trying to run it check that ~/.local/bin
is in your shell search path. If it is not, run pipx ensurepath
to fix this
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file repo_find_orphans-0.0.4.tar.gz
.
File metadata
- Download URL: repo_find_orphans-0.0.4.tar.gz
- Upload date:
- Size: 5.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.2 CPython/3.11.2 Darwin/22.4.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7e2cd1663d9871028d111f32cbb28bd27d8756cbe840bfc10a678df9b12f7e6d |
|
MD5 | 278db14bc06021a84fe9831cd650cb00 |
|
BLAKE2b-256 | 9cc5fe9b6ecd4f32f688ba07b236cc9cad46d23a19dc7d5d581a5d6e772773b0 |
File details
Details for the file repo_find_orphans-0.0.4-py3-none-any.whl
.
File metadata
- Download URL: repo_find_orphans-0.0.4-py3-none-any.whl
- Upload date:
- Size: 5.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.2 CPython/3.11.2 Darwin/22.4.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7e95bc41bd4770efc5a341ed414212db2851fa1886a1f102c9e51d76a92245b3 |
|
MD5 | 194e60d566cf7dd8bdbed2113f9d86b5 |
|
BLAKE2b-256 | 8c87a803279f81591885134b33b3d31442141f643f959b251bba45b8d7ef4946 |