source/plugins/habits/README.md
</td>
<b>default:</b> no
</td> </tr> <tr> <td nowrap="nowrap"><h4><code>plugin_habits_from</code></h4></td> <td rowspan="2"><p>Events to use</p> <p>A higher number will increase stats accuracy</p> </td> </tr> <tr> <td nowrap="nowrap"><b>type:</b> <code>number</code> <i>(1 ≤ 𝑥 ≤ 1000)</i><b>default:</b> 200
</td> </tr> <tr> <td nowrap="nowrap"><h4><code>plugin_habits_skipped</code></h4></td> <td rowspan="2"><p>Skipped repositories</p> </td> </tr> <tr> <td nowrap="nowrap">⏩ Inherits <code>repositories_skipped</code><b>type:</b> <code>array</code> <i>(newline-separated)</i>
</td> </tr> <tr> <td nowrap="nowrap"><h4><code>plugin_habits_days</code></h4></td> <td rowspan="2"><p>Event maximum age</p> </td> </tr> <tr> <td nowrap="nowrap"><b>type:</b> <code>number</code> <i>(1 ≤ 𝑥 ≤ 30)</i><b>default:</b> 14
</td> </tr> <tr> <td nowrap="nowrap"><h4><code>plugin_habits_facts</code></h4></td> <td rowspan="2"><p>Mildly interesting facts</p> <p>It includes indentation type, average number of characters per line of code, and most active time and day</p> </td> </tr> <tr> <td nowrap="nowrap"><b>type:</b> <code>boolean</code><b>default:</b> yes
</td> </tr> <tr> <td nowrap="nowrap"><h4><code>plugin_habits_charts</code></h4></td> <td rowspan="2"><p>Charts</p> <p>It includes commit activity per hour of day and commit activity per day of week Recent language activity may also displayed (it requires extras features to be enabled for web instances) for historical reasons</p> </td> </tr> <tr> <td nowrap="nowrap">🌐 Web instances must configure <code>settings.json</code>: <ul> <li><i>metrics.api.github.overuse</i></li> <li><i>metrics.run.tempdir</i></li> <li><i>metrics.run.git</i></li> </ul> <b>type:</b> <code>boolean</code><b>default:</b> no
</td> </tr> <tr> <td nowrap="nowrap"><h4><code>plugin_habits_charts_type</code></h4></td> <td rowspan="2"><p>Charts display type</p> <ul> <li><code>classic</code>: <code><div></code> based charts, simple and lightweight</li> <li><code>graph</code>: <code><svg></code> based charts, smooth</li> </ul> <blockquote> <p>⚠️ <code>chartist</code> option has been deprecated and is now equivalent to <code>graph</code></p> </blockquote> </td> </tr> <tr> <td nowrap="nowrap">🌐 Web instances must configure <code>settings.json</code>: <ul> <li><i>metrics.npm.optional.d3</i></li> </ul> <b>type:</b> <code>string</code><b>default:</b> classic
<b>allowed values:</b><ul><li>classic</li><li>graph</li><li>chartist</li></ul></td>
</tr> <tr> <td nowrap="nowrap"><h4><code>plugin_habits_trim</code></h4></td> <td rowspan="2"><p>Trim unused hours on charts</p> </td> </tr> <tr> <td nowrap="nowrap"><b>type:</b> <code>boolean</code><b>default:</b> no
</td> </tr> <tr> <td nowrap="nowrap"><h4><code>plugin_habits_languages_limit</code></h4></td> <td rowspan="2"><p>Display limit (languages)</p> </td> </tr> <tr> <td nowrap="nowrap"><b>type:</b> <code>number</code> <i>(0 ≤ 𝑥 ≤ 8)</i><b>zero behaviour:</b> disable</br> <b>default:</b> 8
</td> </tr> <tr> <td nowrap="nowrap"><h4><code>plugin_habits_languages_threshold</code></h4></td> <td rowspan="2"><p>Display threshold (percentage)</p> </td> </tr> <tr> <td nowrap="nowrap"><b>type:</b> <code>string</code><b>default:</b> 0%
</td> </tr> </table> <!--/options-->By default, dates use Greenwich meridian (GMT/UTC).
Configure config_timezone (see supported timezone) to avoid time offsets.
Example: configuring timezone
- uses: lowlighter/metrics@latest
with:
config_timezone: Europe/Paris
name: Mildly interesting facts
uses: lowlighter/metrics@latest
with:
filename: metrics.plugin.habits.facts.svg
token: ${{ secrets.METRICS_TOKEN }}
base: ""
plugin_habits: yes
plugin_habits_facts: yes
plugin_habits_charts: no
config_timezone: Europe/Paris
name: Recent activity charts
uses: lowlighter/metrics@latest
with:
filename: metrics.plugin.habits.charts.svg
token: ${{ secrets.METRICS_TOKEN }}
base: ""
plugin_habits: yes
plugin_habits_facts: no
plugin_habits_charts: yes
config_timezone: Europe/Paris