Skip to content

Instantly share code, notes, and snippets.

@deathbeam
Last active April 18, 2017 22:39
Show Gist options
  • Save deathbeam/660a21717f2feef27b95ac53638e38d5 to your computer and use it in GitHub Desktop.
Save deathbeam/660a21717f2feef27b95ac53638e38d5 to your computer and use it in GitHub Desktop.
# -*- mode: ruby -*-
# vi: set ft=ruby :
# All Vagrant configuration is done below. The "2" in Vagrant.configure
# configures the configuration version (we support older styles for
# backwards compatibility). Please don't change it unless you know what
# you're doing.
Vagrant.configure("2") do |config|
# The most common configuration options are documented and commented below.
# For a complete reference, please see the online documentation at
# https://docs.vagrantup.com.
# Every Vagrant development environment requires a box. You can search for
# boxes at https://atlas.hashicorp.com/search.
config.vm.box = "arch"
# Create a public network, which generally matched to bridged network.
# Bridged networks make the machine appear as another physical device on
# your network.
# config.vm.network "public_network"
# Share an additional folder to the guest VM. The first argument is
# the path on the host to the actual folder. The second argument is
# the path on the guest to mount the folder. And the optional third
# argument is a set of non-required options.
# config.vm.synced_folder "./usr", "/vagrant_data"
# Provider-specific configuration so you can fine-tune various
# backing providers for Vagrant. These expose provider-specific options.
config.vm.provider "virtualbox" do |vb|
# Display the VirtualBox GUI when booting the machine
vb.gui = true
# Customize the amount of memory on the VM:
vb.memory = "2048"
# Set video memory
vb.customize ["modifyvm", :id, "--vram", "128"]
# Enable audio
if RUBY_PLATFORM =~ /darwin/
vb.customize ["modifyvm", :id, '--audio', 'coreaudio', '--audiocontroller', 'hda'] # choices: hda sb16 ac97
elsif RUBY_PLATFORM =~ /mingw|mswin|bccwin|cygwin|emx/
vb.customize ["modifyvm", :id, '--audio', 'dsound', '--audiocontroller', 'ac97']
end
end
# Install latest system updates during provisioning
config.vm.provision "shell", privileged: false, inline: <<-SHELL
yes | pacaur -Syy
yes | pacaur -Su
yes | pacaur -Scc
yes | pacaur -Rns $(pacaur -Qtdq)
sudo pacman-optimize
cd ~/.dotfiles
git pull
./install
cd ~/git/st
sudo rm config.h
git pull
sudo make clean install
cd ~/git/dmenu
sudo rm config.h
git pull
sudo make clean install
cd ~/git/slock
sudo rm config.h
git pull
sudo make clean install
SHELL
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment