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
var https = require('https'), | |
user = process.argv[2], | |
opts = parseOpts(process.argv.slice(3)) | |
request('/users/' + user, function (res) { | |
if (!res.public_repos) { | |
console.log(res.message) | |
return | |
} | |
var pages = Math.ceil(res.public_repos / 100), |
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 class CurrentTimeGetter | |
{ | |
private volatile Holder _holder; | |
const String rfc1123Pattern = "ddd, dd MMM yyyy HH':'mm':'ss 'GMT'"; | |
public string GetCurrentTimeAsString() | |
{ | |
DateTime now = DateTime.UtcNow; | |
Holder currentHolder = _holder; |
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
<%@ Page Language="C#" AutoEventWireup="true" %> | |
<%@ Import Namespace="System.Threading" %> | |
<script runat="server"> | |
protected void Page_Load(object sender, EventArgs e) | |
{ | |
uint viewIndex = 0; | |
uint.TryParse(Request.QueryString["view"], out viewIndex); | |
views.ActiveViewIndex = (int)(viewIndex < views.Views.Count ? viewIndex : 0); |
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
<%@ Page Language="C#" AutoEventWireup="true" %> | |
<%@ Import Namespace="System.Threading" %> | |
<script runat="server"> | |
protected void Page_Load(object sender, EventArgs e) | |
{ | |
uint viewIndex = 0; | |
uint.TryParse(Request.QueryString["view"], out viewIndex); | |
views.ActiveViewIndex = (int)(viewIndex < views.Views.Count ? viewIndex : 0); |
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
<%@ Page Language="C#" AutoEventWireup="true" %> | |
<%@ Import Namespace="System.Threading" %> | |
<script runat="server"> | |
protected void Page_Load(object sender, EventArgs e) | |
{ | |
uint viewIndex = 0; | |
uint.TryParse(Request.QueryString["view"], out viewIndex); | |
views.ActiveViewIndex = (int)(viewIndex < views.Views.Count ? viewIndex : 0); |
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
@echo off | |
"%ProgramFiles(x86)%\Microsoft XDE\8.0\xde.exe" -createDiffDisk "%LOCALAPPDATA%\Microsoft\XDE\dd.480x800.1024.vhd" -vhd "%ProgramFiles(x86)%\Microsoft SDKs\Windows Phone\v8.0\Emulation\Images\Flash.480x800.vhd" -name "Emulator WVGA" -memsize 1024 |
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
# --- settings --- | |
$feedUrlBase = "http://go.microsoft.com/fwlink/?LinkID=206669" | |
# the rest will be params when converting to funclet | |
$latest = $true | |
$overwrite = $false | |
$top = 5000 #use $top = $null to grab all | |
$destinationDirectory = join-path ([Environment]::GetFolderPath("MyDocuments")) "NuGetLocal" | |
# --- locals --- | |
$webClient = New-Object System.Net.WebClient |
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
using System; | |
using System.Diagnostics; | |
using System.Net; | |
namespace ConsoleApplication1 { | |
internal class Program { | |
private const int COUNT = 20; | |
private static void Main() { | |
var urls = new[] { |
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
<#PSScriptInfo | |
.VERSION 1.3 | |
.AUTHOR [email protected] | |
.GUID da220b4e-e889-42dc-85cd-91e0f91a965e | |
.PROJECTURI https://gist.github.com/jongalloway/935780 | |
.RELEASENOTES | |
1.2 adds regular expression title match (thanks, @meavk) | |
1.3 adds check for / at end of RSS URL | |
#> |