Setting Up Hack

Hello, and welcome to another exciting blog post about the Hack programming language. Today I will show you how to setup and install the Hip-Hop Virtual Machine to allow you to start using the Hack programming language. Before we begin I must inform you that HHVM (Hip-Hop Virtual Machine) is only available for Linux distributions. If you do not have a Linux machine like many of us, then I would encourage to use a virtual environment. I use a free tool called VirtualBox to run the Ubuntu operating system while I’m using Windows.

 

Here is a link to download VirtualBox if you’d like to use it

https://www.virtualbox.org/wiki/Downloads

Here is a link to Ubuntu OS downloads (my preference Linux distrobution)

https://www.ubuntu.com/desktop/1710

 

Feel free to ask any questions on installation if you should run into any problems.

 

From then we are going to open execute our virtual machine, start up Ubuntu and open the terminal application.

Openning terminal

Now that we are in the terminal let’s install the HHVM. In the terminal type

apt-get install hhvm. Hit enter and hhvm should install on your machine.

install hhvm from terminal.png

To test if you have successfully installed HHVM type hhvm -m server -p 8080. This calls the package that is associated with the HHVM and gives it parameters m which specifies the mode in this case the hhvm will be in server mode. The p parameter is the port at which this hhvm will communicate from.

HHVM activation

Congratulations, you have successfully setup and installed hhvm , you can now freely experiment with Hack. Now you too can join in on the fun of Hack !

 

 

2 thoughts on “Setting Up Hack

    1. Linux operating system is required to run HHVM which is used to run a Hack. Hack commonly used by the creator Facebook inc. where it is used as an alternative to PHP as a backend scripting language.

      Like

Leave a reply to zack Cancel reply