subset alegreya now
This commit is contained in:
parent
db4e7eb22b
commit
89b650af7e
4 changed files with 34 additions and 9 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -3,4 +3,4 @@
|
|||
css/code.css
|
||||
pgvv/
|
||||
all_chars.txt
|
||||
**/*-Subset.woff2
|
||||
**/fonts/**/*-Subset.*
|
||||
|
|
14
build.sh
14
build.sh
|
@ -13,12 +13,26 @@ function soup_config {
|
|||
source ./pgvv/bin/activate
|
||||
|
||||
find acl.cool/site/ ytheleus.org/site/ -type f \( -name '*.dj' -o -name '*.html' \) -exec cat {} + > all_chars.txt
|
||||
cat common_chars.txt >> all_chars.txt
|
||||
|
||||
for font in fonts/JuliaMono/*{-Light,-Regular,-SemiBold}{,Italic}.woff2; do
|
||||
echo "Subsetting $font"
|
||||
pyftsubset "$font" --flavor=woff2 --text-file=all_chars.txt \
|
||||
--output-file="$(awk -F '.woff2' '{print $1}' <<< "$font")-Subset.woff2"
|
||||
done
|
||||
|
||||
for font in fonts/Alegreya/static/Alegreya-{Regular,Italic,Bold,BoldItalic}.ttf; do
|
||||
echo "Subsetting $font"
|
||||
pyftsubset "$font" --text-file=all_chars.txt \
|
||||
--output-file="$(awk -F '.ttf' '{print $1}' <<< "$font")-Subset.ttf"
|
||||
done
|
||||
|
||||
for font in fonts/Alegreya_Sans/AlegreyaSans-{Regular,Italic,Bold,BoldItalic}.ttf; do
|
||||
echo "Subsetting $font"
|
||||
pyftsubset "$font" --text-file=all_chars.txt \
|
||||
--output-file="$(awk -F '.ttf' '{print $1}' <<< "$font")-Subset.ttf"
|
||||
done
|
||||
|
||||
rm css/code.css
|
||||
pygmentize -f html -S algol_nu | grep -v 'line-height' > css/code.css
|
||||
|
||||
|
|
11
common_chars.txt
Normal file
11
common_chars.txt
Normal file
|
@ -0,0 +1,11 @@
|
|||
—–-
|
||||
|
||||
⁰¹²³⁴⁵⁶⁷⁸⁹ ⁽⁾
|
||||
|
||||
↩︎
|
||||
|
||||
“”
|
||||
|
||||
!"#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~
|
||||
|
||||
…
|
|
@ -56,56 +56,56 @@
|
|||
|
||||
@font-face {
|
||||
font-family: 'BodySerif';
|
||||
src: url('../assets/fonts/Alegreya/static/Alegreya-Regular.ttf') format('truetype');
|
||||
src: url('../assets/fonts/Alegreya/static/Alegreya-Regular-Subset.ttf') format('truetype');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'BodySerif';
|
||||
src: url('../assets/fonts/Alegreya/static/Alegreya-Italic.ttf') format('truetype');
|
||||
src: url('../assets/fonts/Alegreya/static/Alegreya-Italic-Subset.ttf') format('truetype');
|
||||
font-weight: normal;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'BodySerif';
|
||||
src: url('../assets/fonts/Alegreya/static/Alegreya-Bold.ttf') format('truetype');
|
||||
src: url('../assets/fonts/Alegreya/static/Alegreya-Bold-Subset.ttf') format('truetype');
|
||||
font-weight: bold;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'BodySerif';
|
||||
src: url('../assets/fonts/Alegreya/static/Alegreya-BoldItalic.ttf') format('truetype');
|
||||
src: url('../assets/fonts/Alegreya/static/Alegreya-BoldItalic-Subset.ttf') format('truetype');
|
||||
font-weight: bold;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'BodySans';
|
||||
src: url('../assets/fonts/Alegreya_Sans/AlegreyaSans-Regular.ttf') format('truetype');
|
||||
src: url('../assets/fonts/Alegreya_Sans/AlegreyaSans-Regular-Subset.ttf') format('truetype');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'BodySans';
|
||||
src: url('../assets/fonts/Alegreya_Sans/AlegreyaSans-Italic.ttf') format('truetype');
|
||||
src: url('../assets/fonts/Alegreya_Sans/AlegreyaSans-Italic-Subset.ttf') format('truetype');
|
||||
font-weight: normal;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'BodySans';
|
||||
src: url('../assets/fonts/Alegreya_Sans/AlegreyaSans-Bold.ttf') format('truetype');
|
||||
src: url('../assets/fonts/Alegreya_Sans/AlegreyaSans-Bold-Subset.ttf') format('truetype');
|
||||
font-weight: bold;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'BodySans';
|
||||
src: url('../assets/fonts/Alegreya_Sans/AlegreyaSans-BoldItalic.ttf') format('truetype');
|
||||
src: url('../assets/fonts/Alegreya_Sans/AlegreyaSans-BoldItalic-Subset.ttf') format('truetype');
|
||||
font-weight: bold;
|
||||
font-style: italic;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue