$/
artifacts/
build/
docs/
lib/
packages/
samples/
src/
tests/
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
NAME: MigrateTemplages.ps1 | |
AUTHOR: Cory Murdoch | |
EMAIL: cory at coryandwendy dot com | |
BLOG: http://vspherepowershellscripts.blogspot.com | |
.SYNOPSIS | |
Scipt to migrate selected templates from one virtualcenter to another | |
I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!
\
Learn REST API with Python script, slides : http://www.slideshare.net/larrycai/learn-rest-apiwithpython
REST/JSON is perfect match to fetch web data, and python requests module
- Ex1: using command line tool
curl
and browser to access http://httpbin.org/get - Ex2: Install
requests
module and try to access http://httpbin.org/get in python interactive module, print r.json() - Ex3: Use below
restapi.py
as base to implement access data in script - Ex4: continue to access https://api.github.com via GET method
- An Enumerable of Rubyists @raganwald
- An Indentation of Pythonistas @raganwald
- A fold of Haskellers! @ReinH
- A Din of Twitterers @raganwald
- A callback of JavaScripters @irvingreid
- An NCC-1701 of Java Programmers @raganwald
- A relation of SQLers @raganwald
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Just before switching jobs: | |
// Add one of these. | |
// Preferably into the same commit where you do a large merge. | |
// | |
// This started as a tweet with a joke of "C++ pro-tip: #define private public", | |
// and then it quickly escalated into more and more evil suggestions. | |
// I've tried to capture interesting suggestions here. | |
// | |
// Contributors: @r2d2rigo, @joeldevahl, @msinilo, @_Humus_, | |
// @YuriyODonnell, @rygorous, @cmuratori, @mike_acton, @grumpygiant, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"> | |
<Product Id="5fffca1a-e20b-4b76-924a-a915f3124a11" Name="WixTest" Language="1033" Version="1.0.0.0" Manufacturer="WixTest" UpgradeCode="8e607b01-0d14-4c3e-b135-53631a6b44ff"> | |
<Package InstallerVersion="200" Compressed="yes" /> | |
<Media Id="1" Cabinet="media1.cab" EmbedCab="yes" /> | |
<!-- Define Installation Components--> | |
<Directory Id="TARGETDIR" Name="SourceDir"> | |
<Directory Id="StartMenuFolder"/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Insert the following code into the *.VMX file: | |
sched.mem.pshare.enable = "FALSE" | |
mainMem.useNamedFile = "FALSE" | |
prefvmx.minVmMemPct = "100" | |
prefvmx.useRecommendedLockedMemSize = "TRUE" | |
mainMem.partialLazySave = "FALSE" | |
mainMem.partialLazyRestore = "FALSE" | |
priority.grabbed = "high" | |
priority.ungrabbed = "normal" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.IO; | |
using System.Messaging; | |
using System.Text; | |
using Newtonsoft.Json; | |
public class JsonMessageFormatter : IMessageFormatter | |
{ | |
private static readonly JsonSerializerSettings DefaultSerializerSettings = | |
new JsonSerializerSettings { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This shell script is intended to be sourced into your shell. It adds | |
# Default Zenoss server settings. | |
[ -z "$ZENOSS_URL" ] && export ZENOSS_URL="http://localhost:8080" | |
[ -z "$ZENOSS_USERNAME" ] && export ZENOSS_USERNAME="admin" | |
[ -z "$ZENOSS_PASSWORD" ] && export ZENOSS_PASSWORD="zenoss" | |
# Generic call to make Zenoss JSON API calls easier on the shell. | |
zenoss_api () { | |
ROUTER_ENDPOINT=$1 |