forked from devicons/devicon
-
Notifications
You must be signed in to change notification settings - Fork 0
97 lines (84 loc) · 2.94 KB
/
build_icons.yml
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
name: Build Icons
on: workflow_dispatch
jobs:
build:
name: Get Fonts From Icomoon
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install dependencies (python, pip, npm)
run: |
python -m pip install --upgrade pip
pip install -r ./.github/scripts/requirements.txt
npm install
- name: Executing build and create fonts via icomoon
shell: bash
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: >
python ./.github/scripts/icomoon_build.py
./.github/scripts/build_assets/geckodriver-v0.32.2-linux64/geckodriver ./icomoon.json
./devicon.json ./icons ./ $GITHUB_TOKEN --headless
- name: Upload geckodriver.log for debugging purposes
uses: actions/upload-artifact@v2
if: failure()
with:
name: geckodriver-log
path: ./geckodriver.log
- name: Upload log file for debugging purposes
uses: actions/upload-artifact@v2
if: always()
with:
name: logfile
path: ./log.txt
- name: Build devicon.min.css
if: success()
run: npm run build-css
# - name: Upload screenshot of the newly made icons
# id: imgur_step
# uses: devicons/[email protected]
# if: success()
# with:
# # will have "new_icons.png" and "new_svgs.png"
# # in that order (cause sorted alphabetically)
# path: ./screenshots/*.png
# client_id: ${{secrets.IMGUR_CLIENT_ID}}
- name: Get the release message from file
id: release_message_step
uses: juliangruber/[email protected]
with:
# taken from icomoon_build.py's get_release_message()
path: ./release_message.txt
- name: Create Pull Request
if: success()
uses: peter-evans/create-pull-request@v3
env:
MESSAGE: |
Hello,
I'm Devicon's Build Bot and I just built some new font files and devicon.min.css file.
The devicon.min.css file contains:
-The icon content
-The aliases
-The colored classes
I also compiled a list of new features and icons that were added since last release.
```
{0}
```
More information can be found in the GitHub Action logs for this workflow.
Adios,
Build Bot :sunglasses:
with:
branch: 'bot/build-result'
commit-message: 'Built new icons, icomoon.json and devicon.css'
title: 'bot:build new icons, icomoon.json and devicon.css'
body: >
${{
format(
env.MESSAGE,
steps.release_message_step.outputs.content
)
}}
delete-branch: true