Skip to content

Instantly share code, notes, and snippets.

Scott Hanselman shanselman

Block or report user

Report or block shanselman

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View start480x800.1024.bat
@echo off
"C:\Program Files (x86)\Microsoft XDE\8.0\xde.exe" -createDiffDisk "C:\Users\Erik\AppData\Local\Microsoft\XDE\dd.480x800.1024.vhd" -vhd "C:\Program Files (x86)\Microsoft SDKs\Windows Phone\v8.0\Emulation\Images\Flash.480x800.vhd" -name "Emulator WVGA.erik" -memsize 1024
View keybase.md

Keybase proof

I hereby claim:

  • I am shanselman on github.
  • I am shanselman (https://keybase.io/shanselman) on keybase.
  • I have a public key whose fingerprint is E010 F4EC CF9A D085 FD3C A875 AE91 5B1E FA9A DBD0

To claim this, I am signing this object:

View gist:969e190dcb21d9814c57
Set-ExplorerOptions -showHidenFilesFoldersDrives -showProtectedOSFiles -showFileExtensions
Enable-RemoteDesktop
cinst 1password
cinst 7zip
cinst 7zip.install
cinst AdobeAIR
cinst adobereader
cinst Atom
cinst markdownpad2
View blogpost
<p>It's always the little throwaway tweets that go picked up. Not the ones that we agonize over. I was doing some work at the command line and typed "dotnet --version | clip" to copy the .NET Core version number into the clipboard. Then I tweeted a little "hey, remember this great utility?" and then the plane took off. I landed two hours later and it had over 500 RTs. Madness. </p> <p>It's funny that 10 year old command prompt utility (this was added in Vista) that everyone's forgotten elicits such an enthusiastic response.</p> <p>Since you all love that stuff, here's a few other "forgotten command prompt features."</p> <center> <blockquote class="twitter-tweet" data-lang="en"> <p lang="en" dir="ltr">Windows folk: Did you know you can pipe cmd prompt commands into the clipboard? <a href="https://t.co/fSE7ZHBBbB">pic.twitter.com/fSE7ZHBBbB</a></p>— Scott Hanselman (@shanselman) <a href="https://twitter.com/shanselman/status/744967489356865538">June 20, 2016</a></blockquote><script async src="//platform.twitte
View start480x800.1024.bat
@echo off
"C:\Program Files (x86)\Microsoft XDE\8.0\xde.exe" -createDiffDisk "C:\Users\Erik\AppData\Local\Microsoft\XDE\dd.480x800.1024.vhd" -vhd "C:\Program Files (x86)\Microsoft SDKs\Windows Phone\v8.0\Emulation\Images\Flash.480x800.vhd" -name "Emulator WVGA.erik" -memsize 1024
View Program.cs
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.Configuration;
namespace WebApplication
{
public class Program{
View gist:5313362
(1..366) | foreach {
$url = New-Object System.Uri("http://hanselminutes.com/images/shows/" + $_ + ".jpg")
$file = $url.Segments[-1]
$file
(New-Object System.Net.WebClient).DownloadFile($url, "c:\hm\" + $file)
}
View DownloadAzureFriday.ps1
mkdir "~\Desktop\AzureFriday"
cd "~\Desktop\AzureFriday"
[Environment]::CurrentDirectory=(Get-Location -PSProvider FileSystem).ProviderPath
$a = ([xml](new-object net.webclient).downloadstring("http://channel9.msdn.com/Shows/Azure-Friday/feed/mp4high"))
$a.rss.channel.item | foreach{
$url = New-Object System.Uri($_.enclosure.url)
$file = $url.Segments[-1]
"Downloading: " + $file
if (!(test-path $file))
{
View dasblog.txt
<figure><a href="https://flic.kr/p/9arwvh"><img title="Burnout photo by Michael Himbeault used under cc" style="display: inline" alt="Burnout photo by Michael Himbeault used under cc" src="http://www.hanselman.com/blog/content/binary/Windows-Live-Writer/Burnout-Or-just-a-natural_CE1C/5357683026_a34d4df4ba_b_0d1090af-d456-4276-8f7d-19186a95d315.jpg" width="999" height="330"></a></figure> <p><a href="https://twitter.com/sarahmei">Sarah Mei</a> had a great series of tweets last week. She's a Founder of RailsBridge, Director of Ruby Central, and the Chief Consultant of <a href="https://www.devmynd.com/">DevMynd</a> so she's experienced with work both "on the job" and "on the side." Like me, she organizes OSS projects, conferences, but she also has a life, as do I.</p> <p>If you're reading this blog, it's likely that you have gone to a User Group or Conference, or in some way did some "on the side" tech activity. It could be that you have a blog, or you tweet, or you do videos, or you volunteer at a school.</p>
View IIS and Windows 10 14942
REG ADD HKLM\SYSTEM\CurrentControlSet\Services\W3SVC /v SvcHostSplitDisable /t REG_DWORD /d 1 /f
REG ADD HKLM\SYSTEM\CurrentControlSet\Services\WAS /v SvcHostSplitDisable /t REG_DWORD /d 1 /f
You can’t perform that action at this time.