Skip to content

Instantly share code, notes, and snippets.

View danhively's full-sized avatar

Dan Hively danhively

  • 22:45 (UTC -06:00)
View GitHub Profile
@danhively
danhively / system.md
Created October 1, 2016 00:16 — forked from andrewgioia/system.md
macOS Development Configuration Guide

OSX Development Configuration

Introduction

This guide will walk through the steps (and common issues/workarounds) to installing PHP, Apache, MySQL, Redis, Mongo DB, and Couch DB, as well as all necessary dependencies and their configuration with PHP and the OS X/macOS system.

It is important to remember Mac OS X/macOS runs atop UNIX, so all of these technologies install easily on your OS. Furthermore, Apache and PHP are included by default. In the end, you only install MySQL and the other databases and then simply "turn everything on."

Important notes on updating OS X/macOS: with every update of OS X (Yosemite, El Capitan, etc) and now macOS Sierra, your Apache configuration file will be overwritten to httpd.conf.pre-update and a stock file will be added. Your virtual hosts file, /extras/httpd-vhosts.conf will also be overwritten and not backed up automatically. You need to diff httpd.conf and your backed up version, add your virtual host configuration from your own backup, and re-apply y

@danhively
danhively / .bashrc
Created September 30, 2016 23:46 — forked from azazlife/.bashrc
macOS Profile
# ---------------------------------------------------------------------------
#
# Description: This file holds all my BASH configurations and aliases
#
# Sections:
# 1. Environment Configuration
# 2. Make Terminal Better (remapping defaults and adding functionality)
# 3. File and Folder Management
# 4. Searching
# 5. Process Management
@danhively
danhively / Vagrantfile
Created September 28, 2016 22:46 — forked from tvjames/Vagrantfile
Prepare a Windows Server 2008 R2 instance for use with vagrant-windows.
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
# All Vagrant configuration is done here. The most common configuration
# options are documented and commented below. For a complete reference,
# please see the online documentation at vagrantup.com.
@danhively
danhively / rhel7_customization.sh
Created September 14, 2016 19:48 — forked from ruzickap/rhel7_customization.sh
RHEL7 customizations
umount /home
sed -i '/\/home/d' /etc/fstab
lvremove -f /dev/mapper/rhel-home
lvextend --resizefs -l +100%FREE /dev/mapper/rhel-root
curl http://10.0.0.141:6809/fusion/rhel-server-7.0-x86_64-dvd.iso > /var/tmp/rhel-server-7.0-x86_64-dvd.iso
mkdir /mnt/iso
echo "/var/tmp/rhel-server-7.0-x86_64-dvd.iso /mnt/iso iso9660 loop,ro 0 0" >> /etc/fstab
mount /mnt/iso
@danhively
danhively / Clone-All-Repos-GitHub-Organization.md
Created September 12, 2016 02:19 — forked from nucliweb/Clone-All-Repos-GitHub-Organization.md
Clone all repos from a GitHub organization

Publics repos

With Ruby 1.8 (default version on MacOS) :

sudo gem install json
curl -s https://api.github.com/orgs/[ORGANIZATION]/repos | ruby -rubygems -e 'require “json”; JSON.load(STDIN.read).each {|repo| %x[git clone #{repo["ssh_url"]} ]}'

With Ruby 1.9+, the json library is by default thus you just use :

@danhively
danhively / .bash_profile
Created August 25, 2016 16:14 — forked from chales/.bash_profile
Mac OSX Bash Profile
# ---------------------------------------------------------------------------
#
# Description: This file holds all my BASH configurations and aliases
#
# Sections:
# 1. Environment Configuration
# 2. Make Terminal Better (remapping defaults and adding functionality)
# 3. File and Folder Management
# 4. Searching
# 5. Process Management
@danhively
danhively / _verify-repair-permissions-disk.md
Created August 21, 2016 05:24 — forked from bzerangue/_verify-repair-permissions-disk.md
Mac OS X Utilities via Terminal: (Verify and Repair: Disk Permissions AND Disk / Software Update / TimeMachine)

Verify and Repair Disk Permissions via Terminal (Mac OS X)

Verify Permissions

diskutil verifyPermissions /

Repair Permissions

diskutil repairPermissions /

The current kernel/drivers of Fedora 24 do not support the Wifi chip used on my Mac Book Pro. Proprietary Broadcom drivers are packaged and available in the rpmfusion repo.

Verify that your card is a Broadcom using: lspci -vnn -d 14e4:

Sample output:

02:00.0 Network controller [0280]: Broadcom Corporation BCM4360 802.11ac Wireless Network Adapter [14e4:43a0] (rev 03)

Install

Install the rpmfusion repo: http://rpmfusion.org/

@danhively
danhively / devlaptop
Created June 9, 2016 19:40 — forked from spjeff/devlaptop
Boxstarter install for Windows 10 developer laptop
#BoxStarter http://boxstarter.org/WebLauncher
#CMD start http://boxstarter.org/package/nr/url?https://gist.github.com/spjeff/0ff734e86cbd8182d214
cinst 7zip.install -y
cinst adobereader -y
cinst audacity -y
cinst autohotkey.portable -y
cinst avastfreeantivirus -y
cinst attributechanger -y
cinst AzureStorageExplorer -y
@danhively
danhively / fedora23.sh
Last active December 7, 2015 09:13 — forked from mvoropaiev/fedora.sh
#!/usr/bin/env bash
# update system
sudo dnf check-update --refresh \
&& sudo dnf upgrade
# tlp
sudo dnf install -y\
tlp \
tlp-rdw