Someone wrote a script here. Hope it can be integrated.
https://gist.github.com/keeferrourke/d29bf364bd292c78cf774a5c37a791db#file-install-google-fonts-sh
Someone wrote a script here. Hope it can be integrated.
https://gist.github.com/keeferrourke/d29bf364bd292c78cf774a5c37a791db#file-install-google-fonts-sh
I tried to run above script line by line, but it seems ran out of space and got a lot of errors after git clone $giturl command.
I expanded the VM’s disk size to 80G beforehand. The VM got 2GB memory.
error: unable to write file ofl/trochut/OFL.txt
error: unable to write file ofl/trochut/Trochut-Bold.ttf
error: unable to write file ofl/trochut/Trochut-Italic.ttf
error: unable to write file ofl/trochut/Trochut-Regular.ttf
error: unable to write file ofl/truculenta/DESCRIPTION.en_us.html
error: unable to write file ofl/truculenta/METADATA.pb
error: unable to write file ofl/truculenta/OFL.txt
error: unable to write file ofl/truculenta/Truculenta[opsz,wdth,wght].ttf
.
.
.
error: unable to write file ufl/ubuntumono/UFL.txt
error: unable to write file ufl/ubuntumono/UbuntuMono-Bold.ttf
error: unable to write file ufl/ubuntumono/UbuntuMono-BoldItalic.ttf
error: unable to write file ufl/ubuntumono/UbuntuMono-Italic.ttf
error: unable to write file ufl/ubuntumono/UbuntuMono-Regular.ttf
Checking out files: 100% (10823/10823), done.
fatal: unable to checkout working tree
warning: Clone succeeded, but checkout failed.
You can inspect what was checked out with 'git status'
and retry the checkout with 'git checkout -f HEAD'
root@DietPiVM:/tmp/google-fonts#
After reboot, some services stop running. I couldn’t even run Dietpi-Config and it exited immediately.
Tried with original VM 8GB disk , also given 2GM RAM. Change /var/swap from 1027MB to 2048MB with Dietpi-Drive_Manager, same result.
many write errors when running git clone command with the script.
Probably the file system is damaged, as it switched to read-only.
Please try to either scan the drive on another Linux system or have it scanned at reboot:
> forcefsck
reboot
# then after reboot
journalctl -t systemd-fsck
MichaIng
This is a VM I guess
maya95
can you try to clone git somewhere else than /tmp as this is an own mountpoint and a tmpfs file system. It has no relation to the size of the root file system
Yep, I run DietPi in a VM.
===
I ran mount -o remount,rw / and the file system is back.
Linux’s file system is really confusing for a Windows guy.
I change /tmp to /temp in the script and the script ran most part OK. But got some errors:
Receiving objects: 100% (38116/38116), 1016.69 MiB | 1.76 MiB/s, done.
Resolving deltas: 100% (18744/18744), done.
Checking out files: 100% (10825/10825), done.
Installing fonts...
Cleaning up...
...
find: paths must precede expression: `;'
find: paths must precede expression: `;'
...
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package 'fonts-roboto' is not installed, so not removed
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Updating font-cache...
...
/etc/scripts/install-google-fonts.sh: line 31: unexpected EOF while looking for matching `"'
/etc/scripts/install-google-fonts.sh: line 32: syntax error: unexpected end of file
===
questions:
1.
Don’t quite understand the -Dm644 and ; part in the bash command:
sudo find /temp/google-fonts -type f -name “*.ttf” -exec install -Dm644 {} $pkgdir ;
2.
What exactly is the command that I can increase the size of tmpfs /tmp from 1G to 2G?
3.
Is Mate Font Viewer always slow? It took almost 2 minutes to display the fonts installed in the system.
(Found Google fonts took 1.5GB space though)
size of /tmp depends on the available physical memory + swap. It is defined in /etc/fstab
It seems the script is a little buggy.