Giter Site home page Giter Site logo

thomasthaddeus / autoupdatepip Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 19 KB

This is a CLI program that makes updating pip dependencies easier if you don't always use a virtual environment. This works on linux and windows

License: MIT License

PowerShell 6.30% Shell 11.95% Python 81.74%
automation pypi python cronjob linux pip sysadmin update-checker updater

autoupdatepip's Introduction

Pip Batch Update Utility

This utility provides a streamlined way to manage and update your pip packages in batches. It also includes scripts to add pip_update to the system environment, allowing the user to easily update pip packages from anywhere within the console.

Directory Structure

|   .gitignore
|   LICENSE
|   pyproject.toml
|   README.md
|   requirements.txt
|
+---docs
|       pip_config.md
|       powershell_profile.md
|       TODO.md
|
+---out
|       output.txt
|
\---src
    |   main.py
    |   pip_batch_update.py
    |   version.py
    |   __init__.py
    |
    +---data
    |       pip_help_commands.txt
    |
    +---logs
    |       log_0.txt
    |       log_1.txt
    |
    +---scripts
    |       build_and_push.sh
    |       create_structure.sh
    |       pip_update.ps1
    |       pip_update.sh
    |
    \---utils
            get_pip_cmds.py
            log_utils.py
            __init__.py

Installation

  1. Ensure you have Python installed on your machine.

  2. Clone this repository to your local machine.

  3. Navigate to the scripts directory.

  4. Execute the appropriate script for your system (pip_update.ps1 for PowerShell or pip_update.sh for bash) to add pip_update to the system environment.

    # For PowerShell
    ./pip_update.ps1
    
    # For bash
    ./pip_update.sh

Usage

  1. Once pip_update has been added to the system environment, simply run the following command to update your pip packages in batches:

    pip_update
  2. Additional utility scripts are provided in the src/utils directory:

    • get_pip_cmds.py: Provides utilities for fetching pip command listings and obtaining help documentation for each command.
    • log_utils.py: Contains a logrotate function to handle log rotation in the specified logs directory.

Documentation

License

Refer to the LICENSE file for license rights and limitations.

autoupdatepip's People

Contributors

thomasthaddeus avatar

Stargazers

 avatar

Watchers

 avatar

autoupdatepip's Issues

Environment and Dependencies

  • Finalize the pyproject.toml and requirements.txt files to ensure all dependencies are correctly listed and managed.
  • Set up a virtual environment for development and testing to ensure dependencies are isolated from the system Python environment.

(CI/CD)

  • Set up CI/CD pipelines to automate testing, building, and deployment processes.
  • Configure pipelines to run tests on multiple operating systems and Python versions.

Functionality Enhancements

  • Implement additional features in pip_batch_update.py such as handling specific package updates or exclusions.
  • Improve the logging mechanism in log_utils.py to support different logging levels and formats.
  • Optimize the batcher function to handle large sets of packages more efficiently.

Code Development and Testing

  • Complete the implementation of all functions and classes, ensuring they meet their design specifications.
  • Write unit tests for each module (main.py, pip_batch_update.py, get_pip_cmds.py, log_utils.py, etc.) to ensure functionality works as expected.
  • Perform integration testing to ensure all parts of the system work together seamlessly.
  • Add exception handling across the application to manage errors gracefully.

Security and Compliance

  • Conduct a security audit to identify and fix potential vulnerabilities.
  • Ensure the software complies with relevant legal and regulatory requirements.

Version Control and Branch Management

  • Use git for version control, ensuring all changes are committed with meaningful commit messages.
  • Implement a branching strategy for features, bug fixes, and releases.

User Feedback and Iteration

  • Collect user feedback on the tool's functionality and usability.
  • Plan for iterative releases to incorporate feedback and new features over time.

Documentation

  • Complete the docstrings for all functions and classes, ensuring they are detailed and follow a standard format.
  • Create a comprehensive README.md file that includes an introduction, installation instructions, usage examples, and a troubleshooting section.
  • Write detailed documentation in docs/, including pip_config.md and powershell_profile.md, and ensure they provide valuable information for setup and configuration.

Deployment and Distribution

  • Ensure scripts like build_and_push.sh are correctly configured for building and deploying the package to PyPI.
  • Test the installation process from PyPI in different environments to ensure it works correctly.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.