From f47257442dfa2ded74e67601f93966bae2fa7731 Mon Sep 17 00:00:00 2001 From: luckyaxl Date: Sun, 10 Dec 2023 22:21:06 +0700 Subject: [PATCH] docs: update readme --- README.md | 32 ++++++++++++++++++++++---------- 1 file changed, 22 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 59adf75..3110062 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Sonargit Scraper -![SonarGit Scraper](src/images/banner.png) +![Sonargit Scraper](src/images/banner.png) Introducing Sonargit, an automated bot scraper engineered to streamline data extraction from GitHub pull requests and capture dynamic SonarQube screenshots. Tailored specifically for Catalyst engineers. Unleash productivity with a bot that effortlessly extracts, analyzes, and visualizes KPI data. @@ -16,21 +16,34 @@ npm install -g sonargit ### Usage -Execute SonarGit Scraper with the desired start date: +Execute with the desired start date: ```bash sonargit -s 10/10/2023 ``` + +Execute with date range: + +```bash +sonargit -s 10/10/2023 -e 10/12/2023 +``` + +Execute with custom output: + +```bash +sonargit -s 10/10/2023 -o my_output.csv +``` + ### Logs -Log files are generated in the `~/Users//sonargit directory`. +Log files are generated in the `~/Users//sonargit` directory. ## Features ### GitHub API Integration -SonarGit leverages the GitHub API to fetch closed pull requests from a repository within a specified date range and user-defined criteria. This includes pull requests merged into specific branches or closed by particular authors. +Sonargit leverages the GitHub API to fetch closed pull requests from a repository within a specified date range and user-defined criteria. This includes pull requests merged into specific branches or closed by particular authors. ### Extracting SonarQube Data from Comments @@ -38,11 +51,11 @@ The tool fetches comments on GitHub pull requests, extracting coverage percentag ### Puppeteer Web Scraping -Utilizing Puppeteer, SonarGit launches a headless browser, navigates to a SonarQube login page, and logs in with user-provided credentials. It then iterates through pull requests, capturing screenshots of the corresponding SonarQube pages. +Utilizing Puppeteer, Sonargit launches a headless browser, navigates to a SonarQube login page, and logs in with user-provided credentials. It then iterates through pull requests, capturing screenshots of the corresponding SonarQube pages. ### Sequential Processing -SonarGit employs the `sequentialProcess` function to handle pull requests sequentially, avoiding GitHub rate limits and mitigating high memory usage when using Puppeteer. +Sonargit employs the `sequentialProcess` function to handle pull requests sequentially, avoiding GitHub rate limits and mitigating high memory usage when using Puppeteer. ### Moment.js Integration @@ -50,17 +63,16 @@ The tool utilizes the Moment.js library for effective date and time formatting, ### GitHub API Authorization -SonarGit requires a GitHub personal access token for making authenticated requests to the GitHub API, ensuring secure and authorized data retrieval. +Sonargit requires a GitHub personal access token for making authenticated requests to the GitHub API, ensuring secure and authorized data retrieval. ## License -SonarGit Scraper is licensed under the [MIT License](https://github.com/luckyaxl/sonargit/blob/main/LICENSE). +Sonargit Scraper is licensed under the [MIT License](https://github.com/luckyaxl/sonargit/blob/main/LICENSE). ## Contributing -For information on contributing to SonarGit Scraper, please refer to the [Contributing Guidelines](https://github.com/luckyaxl/sonargit/blob/main/CONTRIBUTING.md). +For information on contributing to Sonargit Scraper, please refer to the [Contributing Guidelines](https://github.com/luckyaxl/sonargit/blob/main/CONTRIBUTING.md). ## Support For support and bug reporting, please open an issue on the [issue tracker](https://github.com/luckyaxl/sonargit/issues). -