Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Install Phantom.js on Ubuntu 10.04 and tweak for better rendering quality.
sudo apt-get update
sudo apt-get install libfreetype6 libfreetype6-dev libfontconfig
# /etc/apt/sources.list should contain these:
# deb http://us.archive.ubuntu.com/ubuntu/ lucid multiverse
# deb-src http://us.archive.ubuntu.com/ubuntu/ lucid multiverse
# deb http://us.archive.ubuntu.com/ubuntu/ lucid-updates multiverse
# deb-src http://us.archive.ubuntu.com/ubuntu/ lucid-updates multiverse
sudo echo ttf-mscorefonts-installer msttcorefonts/accepted-mscorefonts-eula select true | sudo debconf-set-selections
sudo apt-get install -y ttf-mscorefonts-installer
wget --no-check-certificate https://gist.github.com/madrobby/5265845/raw/edd7ba1f133067afd2bd60ba7d40e684bb852c6c/localfonts.conf
sudo mv localfonts.conf /etc/fonts/local.conf
wget https://phantomjs.googlecode.com/files/phantomjs-1.9.0-linux-x86_64.tar.bz2
cd /usr/local/share/
sudo tar xjf ~/phantomjs-1.9.0-linux-x86_64.tar.bz2
sudo ln -s /usr/local/share/phantomjs-1.9.0-linux-x86_64/bin/phantomjs /usr/bin/phantomjs
@grantgeorge

This comment has been minimized.

Copy link

commented Jul 26, 2013

How does this increase rendering quality?

@aleemb

This comment has been minimized.

Copy link

commented Jul 31, 2013

Minor nitpick: the multiverse edits should come before the apt-get update

@andrewsavill

This comment has been minimized.

Copy link

commented Jan 24, 2014

For anyone else looking at this here is some refferences to the font config settings. https://wiki.ubuntu.com/Fonts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.