Skip to content

Instantly share code, notes, and snippets.

View vcaraulean's full-sized avatar

Valeriu Caraulean vcaraulean

View GitHub Profile
@vcaraulean
vcaraulean / FieldNullValueAttribute.cs
Created May 6, 2011 15:16
Path for FileHelpers.com for handling empty (not provided) Guid values
// Replace constructor in line 53 with this one
public FieldNullValueAttribute(Type type, string nullValue)
: this(TypeDescriptor.GetConverter(type).ConvertFromString(nullValue))
{ }
@vcaraulean
vcaraulean / DoubleClickEvent
Created November 18, 2010 10:16
Mouse Double Click event implementation for Silverlight and Caliburn.Micro
public static class DoubleClickEvent
{
public static readonly DependencyProperty AttachActionProperty =
DependencyProperty.RegisterAttached(
"AttachAction",
typeof (string),
typeof (DoubleClickEvent),
new PropertyMetadata(OnAttachActionChanged));
public static void SetAttachAction(DependencyObject d, string attachText)
@vcaraulean
vcaraulean / profile.ps1
Created August 17, 2010 21:17
Poweshell profile to combine posh-git and posh-hg prompts
Push-Location (Split-Path -Path $MyInvocation.MyCommand.Definition -Parent)
$profilePath = split-path $profile
# Load posh-git and posh-hg modules from default profile directory
Import-Module $profilePath\posh-git\posh-git
Import-Module $profilePath\posh-hg\posh-hg
function prompt {
Write-Host($pwd) -nonewline