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
<CodeSnippet Format="1.1.0" xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet"> | |
<!-- JS console Snippet --> | |
<Header> | |
<Title>console</Title> | |
<Author>Lucas Caballero</Author> | |
<Shortcut>console</Shortcut> | |
<Description>Markup snippet for console</Description> | |
<SnippetTypes> | |
<SnippetType>Expansion</SnippetType> | |
<SnippetType>SurroundsWith</SnippetType> |
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
<CodeSnippet Format="1.1.0" xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet"> | |
<!-- JS surround with closure Snippet --> | |
<Header> | |
<Title>closure</Title> | |
<Author>Lucas Caballero</Author> | |
<Shortcut>jqclosure</Shortcut> | |
<Description>Surround/Expand with the typeical jQuery closure plug-in syntax.</Description> | |
<SnippetTypes> | |
<SnippetType>Expansion</SnippetType> | |
<SnippetType>SurroundsWith</SnippetType> |
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
XmlSerializer xs = new XmlSerializer(typeof(Resources)); | |
StringWriter sw = new StringWriter(); | |
XmlTextWriter xw = new XmlTextWriter(sw); | |
xw.Formatting = Formatting.Indented; | |
xs.Serialize(xw, | |
new Resources | |
{ | |
Caches = new List<Cache> | |
{ | |
new Cache |
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
comment.block.antlr | |
comment.block.applescript | |
comment.block.bibtex | |
comment.block.c | |
comment.block.css | |
comment.block.d | |
comment.block.documentation | |
comment.block.documentation.javadoc | |
comment.block.documentation.js | |
comment.block.documentation.json |
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
public static IEnumerable<string> Files( | |
this string root, Func<string, bool> accept) | |
{ | |
return | |
Directory.GetFiles(root).Where(accept) | |
.Concat( | |
Directory.GetDirectories(root) | |
.SelectMany(d => d.Files(accept))); | |
} |
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
public static IEnumerable<int> To(this int from, int to) | |
{ | |
for (int i = from; i < to; i++) | |
{ | |
yield return i; | |
} | |
} |
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
"Less than 10% of the code has to do with the ostensible purpose of the system; the rest deals with input-output, data validation, data structure maintenance, and other housekeeping." -- Mary Shaw (from Pro Asp.Net 4 CMS) | |
"Low-level programming is good for the programmer's soul." -- John Carmack (from Pro Asp.Net 4 CMS) | |
"If the automobile had followed the same development cycle as the computer, a Rolls-Royce would today cose $100, get a million miles per gallon, and explode once a year, killing everyone inside." -- Robert X. Cringly (from Pro Asp.Net 4 CMS) | |
"What you leave behind is not what is engraved in stone monuments, but what is woven into the lives of others." -- Pericles | |
"The learning process is something you can incite, literally incite, like a riot." - Audre Lorde |
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
package main | |
import ( | |
"fmt" | |
_ "github.com/lib/pq" | |
_ "github.com/jmoiron/sqlx" | |
"database/sql" | |
"reflect" | |
) |
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
package main | |
import ( | |
"flag" | |
"io/ioutil" | |
"http" | |
"time" | |
"fmt" | |
"os" | |
) |
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 carousel requires the following minimum structure, where everything | |
* in [] are part of the dom which the carousel doesn't effect, and can be | |
* customized to the situation. See also: usage below. | |
* | |
* [module] | |
* [header/] | |
* .content-carousel-container | |
* ul | |
* li [content-1] |
OlderNewer