Skip to content

A Node.js script that allows you to remotely upgrade specified dependencies in a GitHub project to a specified version.

Notifications You must be signed in to change notification settings

f-gorski/gh-pkg-upgrade

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gh-pkg-upgrade

GitHub Dependency Upgrader

A Node.js script that allows you to remotely upgrade specified dependencies in a GitHub project to a specified version. This tool is useful for maintaining project dependencies across multiple repositories and can be integrated into Continuous Integration (CI) environments for automated dependency management.

example script usage

Features

  • Upgrade a specified dependency to a desired version in a GitHub repository.
  • Authenticate using a fine-grained GitHub token.

Prerequisites

  • Node.js installed on your machine
  • A fine-grained GitHub token with the necessary permissions to read and write to the repository

Installation

  1. Clone the repository and navigate to the project directory:
  2. Install the necessary dependencies:
npm install

Usage

To upgrade a dependency, run the script with the following options:

node gh-pkg-upgrade.js --pkg-name <package-name> --pkg-version <version> --owner <owner> --repo <repository> --token <github-token>

Available options

  • -n, --pkg-name : Name of the package to upgrade (required)
  • -v, --pkg-version : Version to upgrade the package to (required)
  • -o, --owner : Owner of the GitHub repository (required)
  • -r, --repo : Name of the GitHub repository (required)
  • -t, --token : Fine-grained GitHub token (required)

Example

node gh-pkg-upgrade.js --pkg-name lodash --pkg-version 4.17.21 --owner my-github-username --repo my-repository --token ghp_abcdefghijklmnopqrstuvwxyz123456

Important Note

This project is done as a leisure project and it's not recommended for production use in its current form. While it demonstrates useful concepts and provides basic functionality, it may lack the robustness and security required for production environments.

About

A Node.js script that allows you to remotely upgrade specified dependencies in a GitHub project to a specified version.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published