mirror of
https://github.com/tonsky/FiraCode.git
synced 2024-10-04 00:31:49 +03:00
Put steps into an install script.
parent
65147c7937
commit
f5a2e7c4fe
@ -17,19 +17,33 @@ emerge -av media-fonts/fira-code
|
||||
|
||||
## Manual Installation
|
||||
|
||||
With most desktop-oriented distributions, double-clicking each font file in the ttf folder and selecting “Install font” should be enough. If it isn’t, try this:
|
||||
With most desktop-oriented distributions, double-clicking each font file in the ttf folder and selecting “Install font” should be enough. If it isn’t, create and run download_and_install.sh script:
|
||||
|
||||
```bash
|
||||
#!/bin/bash
|
||||
|
||||
fonts_dir="~/.local/share/fonts"
|
||||
if [ ! -d ${fonts_dir} ]; then
|
||||
echo "mkdir -p $fonts_dir"
|
||||
mkdir -p ${fonts_dir}
|
||||
else
|
||||
echo "Found fonts dir $fonts_dir"
|
||||
fi
|
||||
|
||||
for type in Bold Light Medium Regular Retina; do
|
||||
file_path="~/.local/share/fonts/FiraCode-${type}.ttf"
|
||||
file_url="https://github.com/tonsky/FiraCode/blob/master/distr/ttf/FiraCode-${type}.ttf?raw=true"
|
||||
if [ ! -e ${file_path} ]; then
|
||||
echo "wget -O $file_path $file_url"
|
||||
wget -O ${file_path} ${file_url}
|
||||
else
|
||||
echo "Found existing file $file_path"
|
||||
fi;
|
||||
done
|
||||
|
||||
echo "fc-cache -f"
|
||||
fc-cache -f
|
||||
```
|
||||
|
||||
1. `mkdir -p ~/.local/share/fonts`
|
||||
2. `touch download.sh`
|
||||
|
||||
3. ```shell
|
||||
# In download.sh
|
||||
for type in Bold Light Medium Regular Retina; do
|
||||
wget -O ~/.local/share/fonts/FiraCode-${type}.ttf \
|
||||
"https://github.com/tonsky/FiraCode/blob/master/distr/ttf/FiraCode-${type}.ttf?raw=true";
|
||||
done
|
||||
```
|
||||
4. `bash download.sh`
|
||||
5. `fc-cache -f`
|
||||
|
||||
[More details](https://github.com/tonsky/FiraCode/issues/4)
|
Loading…
Reference in New Issue
Block a user