-
Notifications
You must be signed in to change notification settings - Fork 182
59 lines (52 loc) · 1.73 KB
/
build.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
name: Codicons Build
on:
push:
branches: [ main ]
tags:
- '*'
pull_request:
branches: [ main ]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: '16'
- name: Install dependencies
run: npm install
- name: Build font
run: npm run build
- name: Upload artifact
uses: actions/upload-artifact@v2
with:
name: codicon-font-${{ github.sha }}
path: dist/codicon.ttf
# Create a release when a new tag is pushed. Writes out all new commit messages since the last release.
- name: Create Release
if: startsWith(github.ref, 'refs/tags/')
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
commits=$(git log --pretty=format:"- %h: %s%n (%H)%n" ${{ github.event.before }}..${{ github.sha }})
echo "This release includes: ${commits}" > commit_messages.txt
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: false
prerelease: false
body: $(cat commit_messages.txt)
# run: |
# git config --global user.email "[email protected]"
# git config --global user.name "GitHub Actions"
# git clone https://github.com/microsoft/vscode.git
# cd vscode
# git checkout -b update-codonicons
# cp -r ../dist/codicon.ttf src/vs/base/browser/ui/codicons/codicon/
# git add .
# git commit -m "Update codicons to ${{ github.ref }}"
# git push origin update-font
# # TODO: Create PR