Skip to content

Instantly share code, notes, and snippets.

View matt-horwood-mayden's full-sized avatar
:electron:
Windmilling in Github!

Matthew Horwood matt-horwood-mayden

:electron:
Windmilling in Github!
View GitHub Profile
@matt-horwood-mayden
matt-horwood-mayden / ansible-summary.md
Created April 24, 2018 12:24 — forked from andreicristianpetcu/ansible-summary.md
This is an ANSIBLE Cheat Sheet from Jon Warbrick

An Ansible summary

Jon Warbrick, July 2014, V3.2 (for Ansible 1.7)

Configuration file

intro_configuration.html

First one found from of

@matt-horwood-mayden
matt-horwood-mayden / gist:b17ea28e076832cc2639f81ddfa6e4b5
Created September 20, 2017 12:29 — forked from lttlrck/gist:9628955
rename git branch locally and remotely
git branch -m old_branch new_branch # Rename branch locally
git push origin :old_branch # Delete the old branch
git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote
@matt-horwood-mayden
matt-horwood-mayden / ExportSchema.ps1
Last active June 8, 2017 07:26 — forked from cheynewallace/ExportSchema.ps1
Export MSSQL schema with PowerShell. This script will export your schema definitions for tables, stored procs, triggers, functions and views to .sql files
# Usage: powershell ExportSchema.ps1 "SERVERNAME" "DATABASE" "C:\<YourOutputPath>"
# Start Script
Set-ExecutionPolicy RemoteSigned
# Set-ExecutionPolicy -ExecutionPolicy:Unrestricted -Scope:LocalMachine
function GenerateDBScript([string]$serverName, [string]$dbname, [string]$scriptpath){
[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SqlServer.SMO") | Out-Null
[System.Reflection.Assembly]::LoadWithPartialName("System.Data") | Out-Null