Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/stefanjudis/guardcat
A utility to help you keep track of github notifications
https://github.com/stefanjudis/guardcat
github github-api
Last synced: about 1 month ago
JSON representation
A utility to help you keep track of github notifications
- Host: GitHub
- URL: https://github.com/stefanjudis/guardcat
- Owner: stefanjudis
- License: mit
- Created: 2016-12-21T18:44:55.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2017-04-29T22:50:15.000Z (over 7 years ago)
- Last Synced: 2024-09-18T01:04:55.638Z (about 2 months ago)
- Topics: github, github-api
- Language: JavaScript
- Homepage:
- Size: 71.3 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[![Build Status](https://travis-ci.org/stefanjudis/guardcat.svg?branch=master)](https://travis-ci.org/stefanjudis/guardcat) [![XO code style](https://img.shields.io/badge/code_style-XO-5ed9c7.svg)](https://github.com/sindresorhus/xo) [![Coverage Status](https://coveralls.io/repos/github/stefanjudis/guardcat/badge.svg?branch=master)](https://coveralls.io/github/stefanjudis/guardcat?branch=master)
# GuardCat
GitHub notifications can be overwhelming. I watch a lot of repos and would like to get notifications only for repos that match a given pattern.
So let me introduce you to GuardCat – a simple helper utility to query the GitHub API recursively for particular patterns (and possibly more options later).![A cat watching the Octocat](./logo.jpg "GuardCat logo")
*Side note: This utility is mainly used to build a CLI tool and web app with it.*
## Getting started
```
$ npm i --save guardcat
``````javascript
const guardCat = require( 'guardcat' );guardCat.run( {
// your GitHub access token
// -> https://github.com/settings/tokens
token : '234567890',
// patterns for notifications repos (uses minimatch)
// -> everything that works there is possible here, too
repoPatterns : [ 'stefanjudis/*', 'tc39/ecma262' ]
} ).then( notification => {
// notifications only matching one of the patterns
console.log( notification );
} );
```### `guardCat.run( options )`
Get all GitHub notifications for repos matching the patterns.
**Parameters:**
- `options.token {string}` (required)
- `options.repoPatterns {array}` (required)Returns: `{Promise}`