Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

github-stats-box

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github-stats-box

Update a gist to contain your GitHub stats

  • 0.1.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1.5K
increased by2.2%
Maintainers
1
Weekly downloads
 
Created
Source

github-stats-box

⚡️📌 Update a pinned gist to contain your GitHub stats


Setup

Prep work

  1. Create a new public GitHub Gist (the gist description will be displayed on top of your pinned Gist)
  2. Create a token with the gist scope and copy it

Project setup

  1. Fork this repository

  2. From your new fork, go to Settings > Secrets

  3. Add the following secrets using the New secret button:

    • GH_TOKEN: The GitHub token generated above.
    • GIST_ID: The ID portion from your gist url: https://gist.github.com/bokub/387aeb084c3433e24a11b36660ba9937.
    • ALL_COMMITS: Boolean value, If true it will count all commits instead of last year commits
  4. Go to the Actions tab of your fork

  5. Click set up a workflow yourself

  6. Copy-paste this workflow:

    name: Update Github Stats Gist
    on:
        schedule:
            - cron: '0 * * * *'
        push:
            branches: master
    
    jobs:
        run:
            runs-on: ubuntu-latest
            steps:
                - uses: actions/setup-node@v1
                  with:
                      node-version: 12
                - run: npx github-stats-box
                  env:
                      GH_TOKEN: ${{ secrets.GH_TOKEN }}
                      GIST_ID: ${{ secrets.GIST_ID }}
                      ALL_COMMITS: ${{ secrets.ALL_COMMITS }}
    
  7. Click Start commit then Commit new file to save

That's it! You Gist will be updated immediately, and every hour after that

Keywords

FAQs

Package last updated on 17 Aug 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc