Skip to main content

Posts

Showing posts from March, 2015

Getting things done

Attended one of those sessions where the key selling point was “how to get things done”. In other words, get your sh*t together and get organized with zero emails in you inbox. It is a whole philosophy, google it :-) Well one of the suggestions was to use the “send to onenote” program that is installed with OneNote. Of course that is way to may clicks for me and my mouse and I started to look into a quicker way of doing it in powershell, what else? Turns out there are very few posts on the subject, sending things from powershell to OneNote. Found a couple of references using c# and that is almost powershell so of I went and created this function Out-Note. (Out-Note) The function takes two parameters. Note = The text you want to send to OneNote and an optional parameter Section that defaults to “General”. UPDATE - 23 March 2015 Received a tweet from Jan Egil Ring (Powershell MVP - @JanEgilRing ). He was having issues with the function. It would only create a new page in O

Devops – Unit testing in Powershell Part 2

Powershell has really gained a strong momentum the last 3-4 years and is becoming increasingly the scripting language of choice if you live in the Windows part of the IT world. Together with the increasing popularity of the Devops phrase, unit testing is a key factor going forward. This is part 2 ( Part1 ) of a small series of posts related to unit testing in Powershell. You can read the first post her. In the previous post we presented the Scenario we will be working with and the API functions that our SillyModule will wrap logic around. The tasklist Read up on Unit Testing frameworks for powershell (Pester or PSUnit) Create the the SillySystem Import-Object and Export-Object API Walk through of the module and the functions (Get/Update-Person/Group) Create tests for the functions Refactor where needed ad update the tests The SillyModule The context of the module is pretty simple. We need cmdlets to receive a list of persons or groups. The list may be filtered on a s

Powershell ISE – Increase your productivity

For some time now I have been thinking about extending ISE to increase my productivity. Those of you that do heavy “powershelling” are probably already living inside ISEsteriods which is a terrific and professional extension. For all others this might suit your needs or maybe you will find it lacking in some areas. Why On the top of my head? Why not. Microsoft has created a powerful environment for us which is free and lacking is some areas. Still with the update regime currently being the “defacto” standard there is no way they would satisfy the demanding needs you guys have. Secondly I was kind of curious if it could be done, and last but not least it was fun. Disclaimer Please bear in mind that this is a alpha version 0.1 release and I know there are some issues with it, however it works and demonstrates the capabilities you can implement with very little efforts. I have organized the extension as a module which is built by my build.ps1 script. If you clone the repro a

Devops – Unit testing in Powershell

Powershell has really gained a strong momentum the last 3-4 years and is becoming increasingly the scripting language of choice if you live in the Windows part of the IT world. Together with the increasing popularity of the Devops phrase, unit testing is a key factor going forward. One of the new phrase/term that is spoken often and warm about is Devops . It represents the evolvement from regular IT operation to IT operations with development. It is getting increasingly difficult to separate what is Operations and what is Development, they are combined into one entity. traditionally IT operations has very limited experience (that is zero) with the unit test concept. Testing is catching on and becoming one of the key elements that separates regulars from professionals in the Devops world. Everyone know they need to learn it and may have done it or are in the process of embracing it. Powershell has really gained a strong momentum the last 3-4 years and is becoming increasingly the