Skip to content

Instantly share code, notes, and snippets.

View tobinharris's full-sized avatar

Tobin Harris tobinharris

View GitHub Profile
/*
* UserType allowing easy saving of NHIbernate XmlDocument property.
*
* Example
* =======
*
* //Message.cs - Example class with a XmlDocument
* public class Message
* {
* public XmlDocument Body{get;set;}

NHibernate in Action Errata

Instructions

Mary says...

People will start pointing out errors to you immediately and they should be collected in a master list (html or text) and organized by page and line numebr and sent directly to Gabriel. You can keep updating the master list and sending it in every week or so, until all errata are caught. We will then fix them in the next printing of the book.

Here are two samples: >http://www.manning.com/bibeault/excerpt_errata.html

# SVN Sparkline
#
# By Tobin Harris (http://www.tobinharris.com)
#
#
# Project to generate an activity sparkline for an public SVN repository.
#
# Outputs a *javascript snippet* that can be included in a HTML document.
#
# Usage:
#
# A simple ruby script that will run in the cloud.
# You need to setup GitHub to call http://blah.com/shout on post-commit
#
require 'rubygems'
require 'xmpp4r-simple'
require 'sinatra'
get '/shout' do

yUML Test On GitHub

yUML is a simple tool for embedding UML diagrams in wikis and blogs without needing any UML or diagramming tools.

Here's an idea of how it could be used in your repository readme.markdown or wiki.

View the RAW source to see how images are made.

Example

using System;
using System.Collections.Generic;
using System.IO;
using FluentNHibernate;
using FluentNHibernate.AutoMap;
using FluentNHibernate.Cfg.Db;
using NHibernate;
using NHibernate.Cfg;
using NHibernate.Context;
using NHibernate.Event;
# .gitignore for .NET projects
# Thanks to Derick Bailey
# http://www.lostechies.com/blogs/derickbailey/archive/2009/05/18/a-net-c-developer-s-gitignore-file.aspx
# Additional Thanks to
# - Alexey Abramov
# Standard VS.NET and ReSharper Foo
obj
bin
*.csproj.user
grammar ActivityDiagram
rule diagram
phrase
end
rule phrase
node (connector node)*
end
require 'rubygems'
require 'rake'
require 'rakesetup'
namespace :queue do
task :default => [:queue_summary]
desc "Show's where the queue is up to."
task :summary do
require 'rubygems'
require 'rake'
require 'rexml/document'
require 'ftools'
#We need some libs loaded
require 'Portal.Web/bin/Iesi.Collections'
require 'Portal.Web/bin/NHibernate'
require 'Portal.Web/bin/NHibernate.Search'
require 'Portal.Web/bin/NHibernate.Linq'