Update images
BIN
.github/readme/imgs/action_update.png
vendored
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
.github/readme/imgs/github_profile.png
vendored
Normal file
|
After Width: | Height: | Size: 292 KiB |
BIN
.github/readme/imgs/personal_repo.png
vendored
Normal file
|
After Width: | Height: | Size: 19 KiB |
|
Before Width: | Height: | Size: 31 KiB After Width: | Height: | Size: 31 KiB |
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 16 KiB |
BIN
.github/readme/imgs/plugin_lines.png
vendored
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
.github/readme/imgs/plugin_pagespeed.png
vendored
Normal file
|
After Width: | Height: | Size: 30 KiB |
BIN
.github/readme/imgs/plugin_traffic.png
vendored
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
.github/readme/imgs/repo_secrets.png
vendored
Normal file
|
After Width: | Height: | Size: 88 KiB |
BIN
.github/readme/imgs/token_repo_rights.png
vendored
Normal file
|
After Width: | Height: | Size: 11 KiB |
43
README.md
@@ -32,11 +32,11 @@ Or with HTML :
|
||||
|
||||
If you don't know yet or haven't done it yet, create a repository with the same name as your GitHub username.
|
||||
|
||||

|
||||

|
||||
|
||||
The `README.md` of this repository will be displayed on your GitHub user profile like below !
|
||||
|
||||

|
||||

|
||||
|
||||
#### 1. Create a GitHub token
|
||||
|
||||
@@ -44,13 +44,13 @@ In your account settings, go to `Developer settings` and select `Personal access
|
||||
|
||||
You'll need to create a token with the `public_repo` right so this GitHub Action has enough permissions to push the updated SVG metrics on your personal repository.
|
||||
|
||||

|
||||

|
||||
|
||||
#### 2. Put your GitHub token in your personal repository secrets
|
||||
|
||||
Go to the `Settings` of your personal repository to create a new secret and paste your GitHub token here with the name `METRICS_TOKEN`.
|
||||
|
||||

|
||||

|
||||
|
||||
#### 3. Create a new GitHub Action workflow on your personal repo
|
||||
|
||||
@@ -116,7 +116,7 @@ The bot will be able to track metrics of all your public repositories.
|
||||
|
||||
If you want to also track your private repositories metrics, you'll need to pass a personal token with `repo` permissions to `token`, and use the `committer_token` parameter to pass the bot account token.
|
||||
|
||||

|
||||

|
||||
|
||||
#### 4. Embed the link into your README.md
|
||||
|
||||
@@ -176,7 +176,7 @@ In your account settings, go to `Developer settings` and select `Personal access
|
||||
|
||||
As explained above, you do not need to grant additional permissions to the token.
|
||||
|
||||

|
||||

|
||||
|
||||
#### 2. Install the dependancies
|
||||
|
||||
@@ -336,6 +336,19 @@ Edit your README.md on your repository and link it your image :
|
||||
|
||||
</details>
|
||||
|
||||
<details>
|
||||
<summary>⚠️ HTTP errors code</summary>
|
||||
|
||||
The following errors code can be encountered if your using a server instance :
|
||||
|
||||
* `403 Forbidden` : User is not whitelisted in `restricted` users list
|
||||
* `404 Not found` : GitHub API did not found the requested user
|
||||
* `429 Too many requests` : Thrown when rate limiter is trigerred
|
||||
* `500 Internal error` : An error ocurred while generating metrics images (logs can be seen if you're the owner of the instance)
|
||||
* `503 Service unavailable` : Maximum user capacity reached, only already cached images can be accessed for now
|
||||
|
||||
</details>
|
||||
|
||||
## 📚 Documentations
|
||||
|
||||
### 🧩 Plugins
|
||||
@@ -348,7 +361,7 @@ These can provide more informations into your generated metrics, but it could al
|
||||
|
||||
The *pagespeed* plugin allows you to add your website performances.
|
||||
|
||||

|
||||

|
||||
|
||||
These are computed through [Google's pagespeed API](https://developers.google.com/speed/docs/insights/v5/get-started), which returns the same results as [web.dev](https://web.dev).
|
||||
|
||||
@@ -393,7 +406,7 @@ And pass `?pagespeed=1` in url when generating metrics.
|
||||
|
||||
The *lines* plugin allows you to add the number of lines of code you added and removed across your repositories.
|
||||
|
||||

|
||||

|
||||
|
||||
<details>
|
||||
<summary>💬 About</summary>
|
||||
@@ -431,7 +444,7 @@ And pass `?lines=1` in url when generating metrics.
|
||||
|
||||
The *traffic* plugin allows you to add the number of pages views across your repositories.
|
||||
|
||||

|
||||

|
||||
|
||||
<details>
|
||||
<summary>💬 About</summary>
|
||||
@@ -440,7 +453,7 @@ It will consume an additional GitHub request per repository.
|
||||
|
||||
Due to GitHub Rest API limitation, the GitHub token you provide will requires "repo" permissions instead of "public_repo" to allow this plugin accessing traffic informations.
|
||||
|
||||

|
||||

|
||||
|
||||
##### Setup with GitHub actions
|
||||
|
||||
@@ -522,16 +535,6 @@ Basically you create a `settings.json` containing a test token and `debug` mode
|
||||
|
||||
You can then start the node with `npm start` and you'll be able to test how the SVG renders with your editions by opening the server url in your browser.
|
||||
|
||||
### ⚠️ HTTP errors code
|
||||
|
||||
The following errors code can be encountered if your using a server instance :
|
||||
|
||||
* `403 Forbidden` : User is not whitelisted in `restricted` users list
|
||||
* `404 Not found` : GitHub API did not found the requested user
|
||||
* `429 Too many requests` : Thrown when rate limiter is trigerred
|
||||
* `500 Internal error` : An error ocurred while generating metrics images (logs can be seen if you're the owner of the instance)
|
||||
* `503 Service unavailable` : Maximum user capacity reached, only already cached images can be accessed for now
|
||||
|
||||
### 📖 Useful references
|
||||
|
||||
Below is a list of useful links :
|
||||
|
||||
|
Before Width: | Height: | Size: 11 KiB |
|
Before Width: | Height: | Size: 130 KiB |
|
Before Width: | Height: | Size: 18 KiB |
|
Before Width: | Height: | Size: 15 KiB |
|
Before Width: | Height: | Size: 20 KiB |
|
Before Width: | Height: | Size: 15 KiB |
|
Before Width: | Height: | Size: 34 KiB |
|
Before Width: | Height: | Size: 9.8 KiB |