Skip to content

Instantly share code, notes, and snippets.

@andysnell
andysnell / pre-commit.sh
Created March 27, 2019 20:57
Pre-Commit Git Hook for SALT
#!/bin/bash
STAGED_FILES_CMD=`git diff --cached --name-only --diff-filter=ACMR HEAD | grep \\\\.php`
# Determine if a file list is passed
if [ "$#" -eq 1 ]
then
oIFS=$IFS
IFS='
'

Keybase proof

I hereby claim:

  • I am andysnell on github.
  • I am andysnell (https://keybase.io/andysnell) on keybase.
  • I have a public key ASBtcikHUwAsROsKrm9WhNPgUagoLCxUMgkx2u_A0rcvtwo

To claim this, I am signing this object:

sudo apt-get update
sudo add-apt-repository -y ppa:ondrej/php
sudo apt-get install -y php7.0
sudo apt-get update
sudo apt-get install -y php7.0-mysql libapache2-mod-php7.0 php-mbstring
sudo a2dismod php5
sudo a2enmod php7.0
sudo apachectl restart
@andysnell
andysnell / homestead_sqlsrv_driver_installer.sh
Created September 19, 2016 20:25
SQL Server Driver Installer for Laravel Homestead
#!/bin/bash
# SQL Server Driver Installer for Laravel Homestead
#
# This script downloads, compiles, and installs the PHP 7 extension
# files for both the native sqlsrv and the PDO pdo_sqlsrv drivers.
# Get the Microsoft Driver Source Code from Github
cd ~
git clone https://github.com/Microsoft/msphpsql.git
cd msphpsql