Skip to content

Instantly share code, notes, and snippets.

View jnericks's full-sized avatar

Jon Erickson jnericks

View GitHub Profile
public class MyClass
{
IList<object> _myObjects;
public IEnumerable<object> MyObjects
{
get { return _myObjects = (_myObjects ?? new List<object>()); }
}
}
public class MyClass
{
IList<object> _myObjects;
public IEnumerable<object> MyObjects
{
get { return _myObjects; }
}
public MyClass()
{
@jnericks
jnericks / osx_lion_scrolling.ahk
Created December 16, 2011 23:35
AutoHotKey OS X Lion Scrolling
;Reverse Scrolling
WheelUp::
Send {WheelDown}
Return
WheelDown::
Send {WheelUp}
Return
Application xlApp;
Workbooks xlBooks;
Workbook xlBook;
Worksheet xlSheet;
public IndexUpdaterExcelService()
{
try
{
try
_excelWB = CType(GetObject(_fileNameAndPath), Excel.Workbook)
_excelApp = CType(_excelWB.Parent, Excel.Application)
_excelApp.Visible = True
_excelWS = CType(_excelWB.Worksheets(1), Excel.Worksheet)
using System;
using System.ServiceModel;
using BenchmarkPlus.RMS.Infrastructure.AlphaCorrelations;
using BenchmarkPlus.RMS.Infrastructure.Configuraiton;
namespace BenchmarkPlus.RMS.Infrastructure.Services
{
public class WcfCalculationService : ICalculationService
{
ChannelFactory<AlphaCorrelationsServiceChannel> _factory;
@jnericks
jnericks / timer.html
Created May 11, 2011 16:15
COD Timer
<html>
<head>
<title>Respawn Timer</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<script type="text/javascript">
var timerId;
$(function(){
$("#TimeBox p:first").css("display", "block");
using Machine.Specifications;
using Machine.Specifications.DevelopWithPassion.Rhino;
namespace Specs
{
public class TestSpecs
{
public abstract class concern : Observes
{
Establish c = () =>
$(function() {
$('.' + (window.location.href).match(/\d/g).join('')).click();
});
<!-- Publish to Daily Build Location -->
<Target Name="PublishDailyBuild">
<MSBuild Projects="MyProject.csproj"
Targets="Clean;Publish"
Properties="Configuration=Release;
Platform=x86;
PublishDir=$(DailyBuildDir);
PublishUrl=$(DailyBuildDir);
InstallUrl=$(DailyBuildDir);
ApplicationVersion=$(Version);