-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcode-stats.yml
More file actions
32 lines (27 loc) · 833 Bytes
/
code-stats.yml
File metadata and controls
32 lines (27 loc) · 833 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: Code Stats with SCC + GitHub Pages
on:
push:
branches: [main]
jobs:
generate-report:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v3
- name: Install SCC
run: |
curl -s https://api.github.com/repos/boyter/scc/releases/latest \
| grep "browser_download_url.*linux_amd64.tar.gz" \
| cut -d '"' -f 4 \
| wget -i -
tar -xzf scc-*-x86_64-unknown-linux-gnu.tar.gz
sudo mv scc /usr/local/bin
- name: Generate HTML report
run: |
mkdir -p report
scc --format=html > report/index.html
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./reportp