Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions docs/github-actions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Using sabik with GitHub Actions

This document explains how to use sabik in GitHub Actions to generate code metrics badges.

## Setup GitHub Actions

Create a workflow file:

.github/workflows/build.yml

## Run sabik

Run sabik to generate metrics.

./bin/run ./src -t JSON

## Generated Metrics

- LogicalLineOfCode
- CognitiveComplexity
- Maintainability

## Badge generation

Badges can be generated using dynamic-badges-action.
26 changes: 13 additions & 13 deletions index.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,20 +43,20 @@ OPTIONS

# Support Programming Language

* TypeScript
* JavaScript
* PHP < 8.0
- TypeScript
- JavaScript
- PHP < 8.0

For now.

# What analyzable metrics?

Sabik analyzable metrics are following.

* Cognitive Complexity
* Halstead complexity measures
* Line of Code(Logical, Physical)
* Maintainability
- Cognitive Complexity
- Halstead complexity measures
- Line of Code(Logical, Physical)
- Maintainability

For now.

Expand Down Expand Up @@ -99,15 +99,15 @@ This metric ranges from 0 ~ 100.
It’s maintenance hard when under 60 scores. (In my experience)
This metrics is normally using the following, calculate.

* Line of Code
* Halstead metrics
* Cyclomatic Complexity
- Line of Code
- Halstead metrics
- Cyclomatic Complexity

But in Sabik using following.

* Line of Code
* Halstead metrics
* Cognitive Complexity
- Line of Code
- Halstead metrics
- Cognitive Complexity

If you want to know more about the detail, please see the following.

Expand Down