Join in Powershell v2.0
“Hello”, “World” -join “ “ Powershell v2.0 has a join operator. It works with simple arrays. Oh well, I still enjoyed creating my own that works with the pipeline. »
“Hello”, “World” -join “ “ Powershell v2.0 has a join operator. It works with simple arrays. Oh well, I still enjoyed creating my own that works with the pipeline. »
Quick and dirty join function for powershell, that utilizes the pipeline. function join { param($delimiter) begin { $strings = @() } process { $strings += $_ } end { [string]::Join($delimiter, $strings) } } The following now works: > "Hello", "World" | join " " Hello World »
I am planning on going to my first Code Camp this weekend in Roanoke. Hope to see you there. »
There are already a lot of people who have solved this problem, but I wanted to solve it too. Powershell doesn’t ship with a wget‘ish cmdlet, at least that I could easily find. So I decided to kill two birds with one stone, create my first SnapIn and create a Get-Url cmdlet. It’s much easier than I thought. Getting started Start by creating a new class library project. There are two references you are going to need, System.Configuration.Install and System.Management.Automation. »
Wow »
Cameron let me add another post to the Mailtrust blog. Check it out. For the longest time, my parents were concerned about the validity of Mailtrust on the sole purpose the majority of its employees worked on folding tables. I actually kind of miss them… »
I was reading through some posts on ASP.NET best practices, and a lot is mentioned about on production machines. One thing that seems to be glossed over is . Obviously, tracing is a security concern, but does it hurt your application in other ways? The biggest area I thought tracing could effect an application was memory, so I wanted to see the memory differences of having trace enabled, vs having it disabled. »
I spent most of yesterday configuring a server, then delving into the aforementioned error with a few other devs. Here is basically what we did to figure it out, and what the cause was. The error The day started by setting up a new server, and getting our ASP.NET application up and running. At first, the error wasn’t apparent. It was when we started seeing javascript errors on different pages. It looked as though one javascript includes was causing the error, /WebResource.axd?d=KadOK03KouGAGUGwjTWw4w2&t=633707613869062500. »
Setting up new IIS 6 servers can be a pain. The config is so daunting they call it a metabase! Backing up the metabase is super important, but did you know you can copy the entire metabase to another server? Yes you can, and its pretty awesome. cscript iiscnfg.vbs /copy /ts ANOTHER_SERVER /tu domain\user /tp password Perfect for web farms where you are adding new servers and need to script setup. »
I read an awesome post on Coding Horror entitled Are you an Expert. There is a great quote that really exemplifies what product ownership means. Being an expert isn't telling other people what you know. It's understanding what questions to ask, and flexibly applying your knowledge to the specific situation at hand. Being an expert means providing sensible, highly contextual direction. A product owner has to be so in touch with the product, that they can ask the right questions. »