Go to file
Shadowfacts 1f418d1b13
Fix URL
2017-02-10 19:28:58 -05:00
src Everything 2017-02-10 19:23:33 -05:00
.gitignore Everything 2017-02-10 19:23:33 -05:00
README.md Fix URL 2017-02-10 19:28:58 -05:00
github-activity.widget.zip Add zip for Ubersicht widgets website 2017-02-10 19:24:44 -05:00
index.js Everything 2017-02-10 19:23:33 -05:00
package.json Everything 2017-02-10 19:23:33 -05:00
run.sh Everything 2017-02-10 19:23:33 -05:00
widget.json Everything 2017-02-10 19:23:33 -05:00

README.md

github-activity.widget

Übersicht widget that displays your GitHub contributions in a style based on the GitHub activity graph.

Red circles, varying size & color

Red squares, varying color

Green circles, varying size & color

Green squares, varying color

Installation

Requirements:

Installation:

  1. Download the zip

  2. Unzip it

  3. Move the github-activity.widget folder into your Übersicht widgets folder (defaults to ~/Library/Application Support/Übersicht/widgets/).

  4. Modify the options to fit your preferences by editing the options object in src/generate.js. Information about how to configure it is provided in the file's comments.

Options

  • user: Your GitHub username.
  • size: The maximum size (not radius), in pixels, of the shapes.
  • incrAmount: The amount, in pixels, to increase the raw number of contributions when computing the size.
  • margin: The margin, in pixels, between two max-sized shapes.
  • vary: Which settings to vary based on contribution count. Valid options are size, which varies the size of the shape, and color which varies the color of the shape.
  • shape: Which shape type to use. Valid options are circle and square.
  • theme: Which color theme to use. Defaults included are red and green, but any value will be accepted as long as colors are provided in the appropriate sub-object of colors.
  • colors: Each sub-object is a color theme. There are four sets of colors: none for no contributions, one for 1-5 contributions, two for 6-10 contributions, three for 11-15 contributions, and max for anything beyond that.
    • overrides: Used to override individual values from the selected color-scheme without modifying it.
    • red: The default red color theme.
    • green: The default green color theme, based on GitHub's activity graph

Other Notes

  • The shell script (run.sh) is used to find the location of Node and run the script. Currently, the script only special cases for Node installed via Homebrew and falls back on running node through the shell's normal behavior. The environment the shells script is executed in does not have .bash_profile/.bashrc/.zshrc/anything else loaded. If you have node installed in an unusual location, open an issue and, if it's common enough, I'll add another special case.
  • You'll need to change the size, incrAmount, and possibly margin values in the options to fit your screen size. The defaults are sized for the largest that can fit on a 1440p screen. A rule of thumb for size/margin is screenWidth / 54 >= size + margin
  • You may need to modify the values used by the else if conditions in the getColorsForPalette function, depending on your GitHub contributions. GitHub determines which color "level" to use dynamically, based on your average contributions but this widget does not.