Skip to content

Instantly share code, notes, and snippets.

View pythoninthegrass's full-sized avatar

pythoninthegrass

View GitHub Profile
@pythoninthegrass
pythoninthegrass / .bash_profile
Last active May 2, 2020 18:17 — forked from natelandau/.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
@pythoninthegrass
pythoninthegrass / 0_reuse_code.js
Created April 5, 2016 13:38
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
#!/bin/bash
########################################################################
# Originally Created Created By: Andrina Kelly, andrina.kelly@bellmedia.ca
# Modifications from scripts from Bryson Tyrrell
# Final by Ross Derewianko
# Creation Date: April 2015
# Last modified: April, 18 2015
# Brief Description: Gather diagnostic logs and submit to the JSS
########################################################################
curl -O -L https://dl.bintray.com/mitchellh/packer/packer_0.7.5_darwin_amd64.zip
unzip packer_0.7.5_darwin_amd64.zip
sudo mv packer_0.7 /usr/local/packer
sudo chown $USER /usr/local/packer/
# then update your .bash_profile with the new path e.g.:
# export PATH="/usr/local/git/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/local/packer:$PATH"

method 1

sudo /usr/local/McAfee/AntiMalware/VSControl stopoas

alternatively

sudo defaults write /Library/Preferences/com.mcafee.ssm.antimalware.plist OAS_Enable -bool False
sudo /usr/local/McAfee/AntiMalware/VSControl stop
sudo /usr/local/McAfee/AntiMalware/VSControl reload
//#define WITH_DEBUG_CONSOLE
#ifndef UNICODE
# define UNICODE
#endif
#define WIN32_LEAN_AND_MEAN
#include <Windows.h>
@pythoninthegrass
pythoninthegrass / Documentation.md
Created September 6, 2016 23:49 — forked from KartikTalwar/Documentation.md
Rsync over SSH - (40MB/s over 1GB NICs)

The fastest remote directory rsync over ssh archival I can muster (40MB/s over 1gb NICs)

This creates an archive that does the following:

rsync (Everyone seems to like -z, but it is much slower for me)

  • a: archive mode - rescursive, preserves owner, preserves permissions, preserves modification times, preserves group, copies symlinks as symlinks, preserves device files.
  • H: preserves hard-links
  • A: preserves ACLs
@pythoninthegrass
pythoninthegrass / cask_gist.txt
Last active May 2, 2020 18:17 — forked from jitendravyas/gist:8d35b092dd9102a05ea3
Brew Cask installation with Laptop script
#!/bin/sh
# homebrew taps
brew tap caskroom/cask
brew tap caskroom/versions
brew tap homebrew/boneyard
brew tap caskroom/fonts
# Updated grep
#!/bin/bash
# ¯\_(ツ)_/¯
REMOVE_PATHS=( "/Applications/Microsoft Office 2011/" \
"/Library/Preferences/com.microsoft.office.licensing.plist" \
"/Library/LaunchDaemons/com.microsoft.office.licensing.helper.plist" \
"/Library/PrivlegedHelperTools/com.microsoft.office.licensing.helper" \
#"/Users/*/Library/Application Support/Microsoft/Office/" \
#"/Users/*/Library/Preferences/com.microsoft*" \
#"/Users/*/Library/Preferences/ByHost/com.microsoft*" \
@pythoninthegrass
pythoninthegrass / wsus_client.ps1
Created January 11, 2017 23:49 — forked from trodemaster/wsus_client.ps1
Register Windows Server 2012 r2 to wsus server via registry keys
New-Item -Path "HKLM:Software\Policies\Microsoft\Windows\WindowsUpdate"
New-Item -Path "HKLM:Software\Policies\Microsoft\Windows\WindowsUpdate\AU"
Set-ItemProperty -Path "HKLM:\software\policies\Microsoft\Windows\WindowsUpdate" -Name WUServer -Value "http://wsus.domain.com:8530" -Type String -force
Set-ItemProperty -Path "HKLM:\software\policies\Microsoft\Windows\WindowsUpdate" -Name WUStatusServer -Value "http://wsus.domain.co:8530" -Type String -force
Set-ItemProperty -Path "HKLM:\software\policies\Microsoft\Windows\WindowsUpdate\AU" -Name UseWUServer -Value "1" -Type DWORD -force