Skip to content

Dark0017/dependable-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LinkedIn


Logo

Dependable Bot

A CLI tool to check dependency version on repos, built on Nodejs.

Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Getting Started
  3. Commands
  4. CSV Specifications
  5. Contributing
  6. License
  7. Contact

About The Project

Product Name Screen Shot

  • Feed CSV - Specify requirements - Check results
    • Accepts a CSV of with names of projects and Repo links
    • Outputs CSV specifing if a project satisfies the required dependency
  • Create PR to upgrade the dependency
    • Single flag to create pull requests to upgrade the dependency on required Repos
    • Adds a column with pull request links to the Output CSV

    (back to top)

Getting Started

Prerequisites

  • You're required to install nodeJS and npm to run the app, follow this link to installation.

  • You will also need to clone the repository follow this link to install git

  • You will also need a personal access token from your github account, instructions. Make sure you have the following permissions checked :

    • repo
    • repo:status Access commit status
    • repo_deployment Access deployment status
    • public_repo Access public repositories
    • repo:invite Access repository invitations
    • security_events
    • admin:org
      • write:org
      • read:org
    • user
      • read:user
      • user:email
      • user:follow

Installation

# Clone this repository
$ git clone https://github.com/Dark0017/dependable-bot

# Go into the repository
$ cd dependable-bot

# Install dependencies
$ npm install

# Run the app in the csv directory
$ depend-bot start

Note Checkout CSV Specifications to format your CSV file

Usage Example

Product Name Screen Shot

(back to top)

Commands


  • hi

    • Say hi to dependable bot
    • To check if bot is working
    $ depend-bot hi

  • start

    • Start dependable bot

    • Required flags:

      -i: specify the csv file name -t: specify your github access token

    • Required argument:

      <dependency>: dependency that will be checked, dependency needs to follow the syntax <name>@<version> such as axios@0.23.0

    $ depend-bot start -u -i data.csv -t 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 grunt@1.5.3

    Note Generate your own personal access token for the token flag from github


(back to top)

CSV Specifications

  • Dependable bot accepts a CSV with 2 columns name and repo (case sensitive)
  • name column contains the name of the project
  • repo column contins the URL to the github repo of the project

A sample of a valid CSV file is given below

name repo
dark-react-sample-app https://github.com/dark-in/react-sample-app/
dark-js-sample-app https://github.com/dark-in/javascript-sample-app
dark-sample-app-backend https://github.com/dark-in/backend-sample-app

Sample output CSV

name repo version version_satisfied
dark-react-sample-app https://github.com/dark-in/react-sample-app/ 0.24.0 true
dark-js-sample-app https://github.com/dark-in/javascript-sample-app 0.21.1 false
dark-sample-app-backend https://github.com/dark-in/backend-sample-app 0.23.0 true

Sample output CSV with update option

Should give an output like:

name repo version version_satisfied update_pr
dark-react-sample-app https://github.com/dark-in/react-sample-app/ 0.24.0 true
dark-js-sample-app https://github.com/dark-in/javascript-sample-app 0.21.1 false https://github.com/dark-in/javascript-sample-app/pull/3
dark-sample-app-backend https://github.com/dark-in/backend-sample-app 0.23.0 true

(back to top)

Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)

License

Distributed under the MIT License. See LICENSE.txt for more information.

(back to top)

Contact

Ayushman Singh - @Ayushma81703243 - singh.ayush8827@gmail.com

(back to top)

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published