Skip to content

Instantly share code, notes, and snippets.

@fraga
fraga / gist:963928
Created May 10, 2011 05:17
Vimrc file
" An example for a vimrc file.
"
" Maintainer: Bram Moolenaar <Bram@vim.org>
" Last change: 2008 Dec 17
"
" To use it, copy it to
" for Unix and OS/2: ~/.vimrc
" for Amiga: s:.vimrc
" for MS-DOS and Win32: $VIM\_vimrc
" for OpenVMS: sys$login:.vimrc
@fraga
fraga / gist:963930
Created May 10, 2011 05:20
Bashrc example glol and mate alias (git)
export EDITOR="$HOME/bin/mate -w"
export glol="git log --pretty=oneline --abbrev-commit --graph --decorate"
@fraga
fraga / .gitconfig
Created May 10, 2011 19:03
.gitconfig windows machine
#usage git difftool HEAD^ HEAD or HEAD~1 HEAD~1 <filename>
[apply]
whitespace = fix
[gui]
recentrepo = C:/repo
[user]
name = Rodrigo
email = email
[diff]
tool = bc
@fraga
fraga / gist:991175
Created May 25, 2011 15:29
bash_profile
export TERM="xterm-color"
alias ls="ls -G"
export PATH=$PATH:/usr/local/mysql/bin:$HOME/bin:~/Desktop/eclipse/workspace/android/android-sdk-mac_86/tools
export EDITOR="$HOME/bin/mate -w"
export glol="git log --pretty=oneline --abbrev-commit --graph --decorate"
PS1="\[\033[01;32m\]\h\[\033[01;34m\] \w \$\[\033[00m\] "
@fraga
fraga / gist:998393
Created May 30, 2011 02:53
Xunit console configuration for .net 4.0 (xunit.console.exe.config)
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<startup>
<requiredRuntime version="v4.0.20506" safemode="true"/>
</startup>
<configSections>
<section name="xunit" type="Xunit.ConsoleClient.XunitConsoleConfigurationSection, xunit.console"/>
</configSections>
@fraga
fraga / gist:998467
Created May 30, 2011 04:48
Two differents web.config regarding unity mapping
<configuration>
<configSections>
<section name="exceptionHandling" type="Microsoft.Practices.EnterpriseLibrary.ExceptionHandling.Configuration.ExceptionHandlingSettings, Microsoft.Practices.EnterpriseLibrary.ExceptionHandling, Version=4.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<section name="unity" type="Microsoft.Practices.Unity.Configuration.UnityConfigurationSection, Microsoft.Practices.Unity.Configuration, Version=1.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
</configSections>
<exceptionHandling>
<exceptionPolicies>
<add name="UIExceptionPolicy">
<exceptionTypes>
<add type="System.Exception, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" postHandlingAction="None" name="Exception">
@fraga
fraga / gist:1003096
Created June 1, 2011 19:26
Program to copy vs font color settings to sql management studio settings
//
// Program.cs
//
// Author:
// Tomas Restrepo (email was hidden for privacy concerns)
//
using System;
using System.Collections.Generic;
@fraga
fraga / interfaces
Created June 14, 2011 19:18
/etc/network/interfaces example
iface eth0:1 inet static
address 192.168.1.5
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255
gateway 192.168.1.1
iface eth0:2 inet static
address 192.168.1.10
netmask 255.255.255.0
@fraga
fraga / gist:1030298
Created June 16, 2011 21:14
Enable or disable WMI traffic in windows 7 firewall
To enable or disable WMI traffic using firewall UI
1.In the Control Panel, click Security and then click Windows Firewall.
2.Click Change Settings and then click the Exceptions tab.
3.In the Exceptions window, select the check box for Windows Management Instrumentation (WMI) to enable WMI traffic through the firewall. To disable WMI traffic, clear the check box.
You can enable or disable WMI traffic through the firewall at the command prompt.
To enable or disable WMI traffic at command prompt using WMI rule group
•Use the following commands at a command prompt. Type the following to enable WMI traffic through the firewall.
netsh advfirewall firewall set rule group="windows management instrumentation (wmi)" new enable=yes
@fraga
fraga / gist:1067295
Created July 6, 2011 14:04
changing user passwords in microsoft online exchange
$cred = Get-Credential
Set-MSOnlineUserPassword –Identity jane.dow@contoso.com –Password P@55word –ChangePasswordOnNextLogon $true –Credential $cred