File tree Expand file tree Collapse file tree 2 files changed +24
-1
lines changed Expand file tree Collapse file tree 2 files changed +24
-1
lines changed Original file line number Diff line number Diff line change @@ -102,7 +102,10 @@ jobs:
102
102
name : install NotoSansCJK fonts
103
103
command : sudo apt install fonts-noto-cjk
104
104
- run :
105
- name : install google fonts
105
+ name : download google fonts e.g. Raleway
106
+ command : python3 ./.circleci/download_google_fonts.py
107
+ - run :
108
+ name : install all google fonts
106
109
command : |
107
110
sudo cp -r .circleci/fonts/ /usr/share/
108
111
sudo fc-cache -f
Original file line number Diff line number Diff line change
1
+ import requests
2
+
3
+ dirOut = '.circleci/fonts/truetype/googleFonts'
4
+
5
+ family = 'Raleway'
6
+ repo = 'https://github.com/impallari/' + family + '/blob/master/fonts/v3.000%20Fontlab/TTF/'
7
+
8
+ types = [
9
+ '-Regular' ,
10
+ '-Regular-Italic' ,
11
+ '-Bold' ,
12
+ '-Bold-Italic'
13
+ ]
14
+
15
+ for t in types :
16
+ name = family + t + '.ttf'
17
+ url = repo + name + '?raw=true'
18
+ print (url )
19
+ req = requests .get (url , allow_redirects = True )
20
+ open (dirOut + name , 'wb' ).write (req .content )
You can’t perform that action at this time.
0 commit comments