summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorstreetturtle <streetturtle@gmail.com>2020-07-14 10:44:20 -0400
committerstreetturtle <streetturtle@gmail.com>2020-07-14 10:44:20 -0400
commitf0524d3a679652a062c8f0515200ebc31430fb5d (patch)
treed4b929ab08d29a4b7eb0141f66ed51a62e10f7fc
parentbcbde507eb857a67a25fe415a133fd7e639a6bdf (diff)
[github-activity-widget] fix #166
Add Installation section to the readme
-rw-r--r--github-activity-widget/README.md24
1 files changed, 24 insertions, 0 deletions
diff --git a/github-activity-widget/README.md b/github-activity-widget/README.md
index 4f69eb5..2dbf98b 100644
--- a/github-activity-widget/README.md
+++ b/github-activity-widget/README.md
@@ -18,6 +18,30 @@ It is possible to customize widget by providing a table with all or some of the
| `username` | your username | Required parameter |
| `number_of_events` | 10 | Number of events to display in the list |
+## Installation
+
+Clone repo under **~/.config/awesome/** and add widget in **rc.lua**:
+
+```lua
+local github_activity_widget = require("awesome-wm-widgets.github-activity-widget.github-activity-widget")
+...
+s.mytasklist, -- Middle widget
+ { -- Right widgets
+ layout = wibox.layout.fixed.horizontal,
+ ...
+ -- default
+ github_activity_widget{
+ username = 'streetturtle',
+ },
+ -- customized
+ github_activity_widget{
+ username = 'streetturtle',
+ number_of_events = 5
+ },
+
+```
+
+
## How it works
Everything starts with this timer, which gets recent activities by calling GitHub [Events API](https://developer.github.com/v3/activity/events/) and stores the response under /.cache/awmw/github-activity-widget/activity.json directory: