Skip to content

Commit 994a904

Browse files
author
Mélanie Chauvel
committed
add fontconfig configuration and add it to installation instructions
1 parent 35a6b09 commit 994a904

File tree

3 files changed

+22
-2
lines changed

3 files changed

+22
-2
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,8 @@ Frequently asked questions are answered in our [FAQ](FAQ.md).
5454
1. Download the [latest version of Hack][ttf_latest].
5555
2. Extract the files from the archive (`.zip`).
5656
3. Copy the font files to either your system font folder (often `/usr/share/fonts/`) or user font folder (often `~/.local/share/fonts/` or `/usr/local/share/fonts`).
57-
4. Clear and regenerate your font cache and indexes with the following set of commands:
57+
4. Copy the font configuration file in `config/fontconfig/` to either the system font configuration folder (often `/etc/fonts/conf.d/`) or the font user folder (often `~/.config/fontconfig/conf.d`)
58+
5. Clear and regenerate your font cache and indexes with the following command:
5859

5960
```
6061
$ fc-cache -f -v
@@ -223,4 +224,3 @@ See [LICENSE.md](https://github.com/source-foundry/Hack/blob/master/LICENSE.md)
223224
<!-- Link to the latest release archive for README.md file -->
224225

225226
[ttf_latest]: https://github.com/source-foundry/Hack/releases/download/v3.002/Hack-v3.002-ttf.zip
226-

config/fontconfig/45-Hack.conf

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?xml version="1.0"?>
2+
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
3+
<fontconfig>
4+
<!-- Declare Hack a monospace font -->
5+
<alias>
6+
<family>Hack</family>
7+
<default><family>monospace</family></default>
8+
</alias>
9+
<!-- if this file is put in user’s configuration, unset sans-serif family -->
10+
<match>
11+
<test compare="eq" name="family">
12+
<string>Hack</string>
13+
</test>
14+
<test compare="eq" name="family">
15+
<string>sans-serif</string>
16+
</test>
17+
<edit mode="delete" name="family"/>
18+
</match>
19+
</fontconfig>

docs/CONTRIBUTORS.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,7 @@
9494

9595
- Guilherme Amadio - Linux
9696
- Helio Chissini de Castro - Linux
97+
- Mélanie Chauvel (ariasuni) - Linux
9798
- Samina Fu - cdnjs
9899
- Michael "Tex" Hex - Windows
99100
- Paride Legovini - Linux

0 commit comments

Comments
 (0)