Skip to main content

Utils for managing Azure DevOps code repositories

Project description

jps-ado-repo-utils

Build Publish to PyPI codecov

Utils for managing Azure DevOps code repositories

🚀 Overview

jps-ado-repo-utils is a Python utility for scanning multiple git repositories to identify dependencies on specific Python packages. It's particularly useful for managing large codebases across multiple repositories in Azure DevOps environments.

The tool clones repositories, analyzes both project configuration files (like pyproject.toml, setup.py, requirements.txt) and Python source files for import statements, then generates comprehensive reports on where dependencies are found.

Features

Parallel Processing — Scan multiple repositories concurrently with configurable worker threads

🔍 Comprehensive Scanning — Detects dependencies in:

  • Project configuration files (pyproject.toml, setup.py, setup.cfg, requirements.txt, Pipfile)
  • Python source files (import statements)
  • Git submodules (.gitmodules)

📊 Detailed Reporting — Generates structured reports with:

  • Successfully scanned repositories
  • Repositories with found dependencies
  • Repositories without dependencies
  • Failed git clone operations
  • Scan errors with detailed diagnostics

🔒 SSH Support — Designed for Azure DevOps SSH URLs

📝 Structured Logging — Comprehensive logging with timestamps and severity levels

Example Usage

# Install the package
pip install jps-ado-repo-utils

# Scan repositories for a specific package dependency
jps-ado-repo-utils-dependency-finder \
    --infile repos.txt \
    --package my-package-name \
    --max-workers 10

Create a repos.txt file with one repository URL per line:

git@vs-ssh.visualstudio.com:v3/org/project/repo1
git@vs-ssh.visualstudio.com:v3/org/project/repo2
git@vs-ssh.visualstudio.com:v3/org/project/repo3

The tool will generate:

  • A detailed log file tracking all operations
  • A comprehensive report showing which repositories use the specified package

For detailed usage instructions, see USAGE.md.

📦 Installation

make install

🧪 Development

make fix && make format && make lint
make test

📜 License

MIT License © Jaideep Sundaram

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

jps_ado_repo_utils-0.3.0.tar.gz (15.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

jps_ado_repo_utils-0.3.0-py3-none-any.whl (12.8 kB view details)

Uploaded Python 3

File details

Details for the file jps_ado_repo_utils-0.3.0.tar.gz.

File metadata

  • Download URL: jps_ado_repo_utils-0.3.0.tar.gz
  • Upload date:
  • Size: 15.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for jps_ado_repo_utils-0.3.0.tar.gz
Algorithm Hash digest
SHA256 62967761150beda21cb9cccd56195cdb8cb1f6eed24678e0e12a555976985431
MD5 eb6f6c5627e7e279c738b0ae6426d1f8
BLAKE2b-256 8b055ea1936227be041cc40a8e1dc187135086c2599ca25fb5c34e91e1ae8901

See more details on using hashes here.

File details

Details for the file jps_ado_repo_utils-0.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for jps_ado_repo_utils-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 bdda1b3f37afffea07b4f534943d28713d676cf519b708c6236a7108bef3fd23
MD5 d48a90f3e14b89cfd3a005667f0816b1
BLAKE2b-256 066fea500d98e2151b5bcd25087becbad834be0fca0ded6337c592eb2961df3e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page