PowerShell
There are 59 entries for the tag PowerShell
Those who know me, can attest that I'm a early adopter when it comes to social networking systems. The latest one I've been getting into lately is FourSquare.com. FourSquare.com describes itself as 50% friend finder, 30% social city guide, and 20% nightlife game. They include ways to keep up with what your friends are doing as well as offering up some fun challenges to have you explore cities in different ways. Once I've played around with a social networking site for a bit, my next step is to see what kind of API's they have exposed...
posted @ Monday, October 05, 2009 12:50 PM | >
For those of you who don't know what Delicious.com is (yes it's the same as del.icio.us), I'll just borrow their overview from their getting started page: Delicious is a social bookmarking service that allows you to tag, save, manage, and share Web pages all in one place. With emphasis on the power of the community, Delicious greatly improves how people discover, remember and share on the Internet. Here on DevCentral, when new content is added, we regularly add it to various social networking sites, including Delicious. There are some great browser...
posted @ Monday, September 21, 2009 8:45 AM | >
Shrinking your Url’s is all the rage nowadays. If you are on Twitter, then odds are you have used one. Despite CodingHorror’s distaste for them in his recent blog post on Url Shorteners: Destroying the Web since 2002, they are a fact of life when we live in a world of 140 character status updates. So what’s a URL shrinking service anyway? Well, to put it simply, you supply them with a URL, they then supply you with a shorter URL containing a lookup “key”. When future requests are made to this shorter URL, connections are routed to that...
posted @ Friday, June 19, 2009 11:04 AM | >
Twitter, for those who don’t know about it, is a status updating service that is all the rage nowadays. It’s popularity is primarily due to it’s simplistic nature. You post a 140 character status (known as a “tweet”) about what you are doing. You can also friend other folks to see what they are doing. If you are still lost, read up on the entry in Wikipedia and you should get the gist of it. The downside to this minimalistic approach is that it does not allow for rich multimedia content such as images or videos to be...
posted @ Wednesday, June 17, 2009 5:31 PM | >
Last week I posted a PowerShell function library for Microsoft’s newly introduced search engine at Bing.com. The function library was appropriately named PoshBing. There was a log of interest in the script so I quickly moved it off my blog and onto a CodePlex project under PoshBing. Working on the command line is fun and all, but since I spend a good portion of my time accessing my twitter account, I figured it would be a bit of fun to integrate it with my previously released PoshTweet PowerShell twitter library. So, after an hour or so of coding...
posted @ Monday, June 08, 2009 11:36 AM | >
Microsoft released their new search engine called “Bing” at, aptly named, http://www.bing.com. Microsoft is getting positive reviews from the likes of CNET, The Wall Street Journal, and TechCrunch. Instead of posting my review of the site, I’ll let you browse the above links to find out what the services is all about. What interested me about Bing is that Microsoft has released a full API to allow you to use their services in your applications. The Bing API is documented at Microsoft’s developer site and I thought to myself how I could test it out. The obvious answer...
posted @ Wednesday, June 03, 2009 1:02 PM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. md5 The Unix “md5” command (aliased to “openssl dgst –md5” or “md5sum”) calculates and verifies 128-bit MD5 hashes as described in RFC 1321. The MD5 hash (or checksum) functions as a compact digital fingerprint of a file. It is extremely unlikely that any two non-identical files existing in the...
posted @ Monday, May 18, 2009 8:08 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. touch The Unix “touch” command is used to change a file’s access and modification timestamps. It can also be used to create a new empty file. The options to the Unix touch command are implemented with the following PowerShell parameters: ...
posted @ Thursday, May 07, 2009 10:09 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. cut The Unix “cut” command is used to extract sections from each link of input. Extraction of line segments can be done by bytes, characters, or fields separated by a delimiter. A range must be provided in each case which consists of one of N, N-M, N- (N to...
posted @ Wednesday, May 06, 2009 9:48 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. basename The Unix “basename” command will delete any prefix up to the last slash (‘/’) character and return the result. For my PowerShell implementation, I’ve switched the slash path separator character with the Windows backslash (‘\’) path separator. PowerShell does have the Split-Path cmdlet that...
posted @ Monday, May 04, 2009 9:30 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. cat The Unix “cat” command is used to concatenate and display files. Given a file or filename list, it will print the contents of that file to standard output. There are several options in the Unix command that are implemented with the following PowerShell arguments: ...
posted @ Friday, May 01, 2009 9:00 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. dirname The Unix “dirname” command will strip any non-directory suffix from a file name. Given a NAME, dirname will print the name with it’s trailing “/” component removed. If NAME contains no “/” characters, it will output “.” (meaning the current directory). Since PowerShell is run on windows,...
posted @ Thursday, April 30, 2009 10:07 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. find The Unix “find” command searches through one or more directory trees of a file system, locating files based on some user specific criteria. By default, find returns all files below the current working directory. It also allows you to perform an action to be taken on each matched...
posted @ Wednesday, April 29, 2009 11:44 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. factor The Unix “factor” command will print out the Prime Factors of each number. Factors are numbers, when multiplied together, give the original number. Prime Factors are factors that are Prime Numbers (numbers that can be divided evenly only by one and itself). The algorithm the Unix command...
posted @ Monday, April 27, 2009 7:53 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. seq The Unix “seq” command prints a sequence of numbers from FIRST to LAST, in steps of INCREMENT. The PowerShell “range” operator “..” will return an array of numbers but it does not give you the ability to modify the increment from 1 (or –1 if the LAST...
posted @ Friday, April 24, 2009 11:37 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. tac The Unix “tac” command will allow you to see a file line-by-line backwards. It will print each record in reverse order. Records are separated by instances of a string (newline being the default). The “-s” option allows you to change the newline to be any other string you...
posted @ Thursday, April 23, 2009 8:23 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. tail The Unix “tail” command that is used to display the last 10 lines of each FILE to standard output. With more than one file, precede each with a header giving the file name. There is also a mode where it prints out the last “n” bytes in a...
posted @ Wednesday, April 22, 2009 1:38 PM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on Unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. fold The Unix “fold” command will take as input a list of files and wrap each input line to fit within a specified width. By default, fold breaks lines wider than 80 columns and the output is split into as many lines as necessary. I’ve included the following...
posted @ Monday, April 20, 2009 11:56 AM | >
Tom Hearn over at NerdyHearn.com was working with SharePoint and needed to get at the Public Key Token from various assemblies to be added to the Safe Assembly list in the SharePoint configuration. He posted the code for a Cmdlet that would, given the path to an assembly, extract the Public Key Token and output it to the console. I, being too lazy to get out my C# compiler, decided to test it out with a script function. Here’s what I came up with: 1: #==================================================================================
...
posted @ Friday, April 17, 2009 1:05 PM | >
If you’ve ever had to diagnose something with your Windows system, odds are you’ve come across the Sysinternals product suite by Mark Russinovich and Bryce Cogswell. Their PsTools suite has saved my behind many times and since they regularly make updates to the tools, it’s kind of a pain to make sure that the tools you are using are always up to date. I’ve been using these so long I still have my tools directory named after the their original “NTInternals” name. Anyone else been using them this long? As part of the transition into Microsoft, they have...
posted @ Friday, April 17, 2009 11:00 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. nl The Unix “nl” (number lines) command will take as input a list of files and, for each file, it will write the file to standard output with line numbers added. There are a lot of options in the unix command and I’ve included the following: ...
posted @ Thursday, April 16, 2009 9:38 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. wc The Unix “wc” (word count) command will print the character, word, and newline counts for each file specified and a total line if more than one file is specified. This command is useful for quickly scanning a directory for small and large files or to quickly look at...
posted @ Wednesday, April 15, 2009 9:05 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. head The Unix “head” command will print the first 10 lines of each file to standard output. With more than one file, it will precede each with a header giving the file name. This command is useful when you just want to quickly scan the first few lines of...
posted @ Tuesday, April 14, 2009 9:52 AM | >
PowerShell is definitely gaining momentum in the windows scripting world but I still hear folks wanting to rely on unix based tools to get their job done. In this series of posts I’m going to look at converting some of the more popular Unix based tools to PowerShell. which For this post, I’m going to tackle the Unix “which” command. With the which command, you specify a file specification (ie notepad.exe, cs.*, etc) and it will scan your defined lookup paths in your environment for a file matching that specification. Years and years ago I wrote a...
posted @ Friday, April 10, 2009 3:38 PM | >
Last Thursday night Hal (@halr9000) and Jon (@jonwalz) over at the PowerScripting Podcast had me on their weekly podcast for episode #61. Hal and Jon are both highly esteemed in the PowerShell community and I caught their attention with my recent PowerShell ABC's blog series. During the interview, I discussed my personal background, F5, the BIG-IP product family, DevCentral, iControl, and our PowerShell implementation. We ended up the interview going a bit more in depth with a few of my ABC posts including Generics, JavaScript, Synthetic Members. If you listen long enough, you'll also find out what...
posted @ Tuesday, March 03, 2009 9:45 AM | >
A few weeks ago I was scanning through my daily PowerTips from PowerShell.com and came across one that covered Using COM Objects to Say Hi. In this tip, they describe how to use the Microsoft Speech API (SAPI) to convert text to play through the the windows audio system. Of course I started tinkering around to see how SAPI sounded with various text strings. Once the novelty of that wore off, the next thing I thought of was how I could extend my PowerShell Twitter library PoshTweet with the SAPI library. I quickly built a little script that called...
posted @ Thursday, February 26, 2009 3:17 PM | >
I'm sure you've heard of stories about folks who work day after day receiving insults from their bosses. You know, in some peoples minds, insulting others is a way to keep them "in line". If the common folk get too much encouragement, they might start thinking that they aren't replaceable. I remember reading that it's been shown that positive motivation is no way to provide a healthy work environment for your employees but unfortunately in today's world, there just isn't enough training for managers to spread this knowledge around. So, if you find yourself continuously being praised for your...
posted @ Wednesday, February 11, 2009 9:47 AM | >
With yesterday's post, another 26 blog posts are in the can. For those who missed the first 26 PowerShell ABC's, here's the complete list. Arithmetic Operators: Unlike strongly typed languages like C/C++ and Java, PowerShell is a dynamically typed language meaning that it can "morph" data types depending on the context in which they are used. This comes in handy when you need to do string manipulations. PowerShell has the standard arithmetic operators you would expect from basic programming language. begin: For all you Cmdlet writers out...
posted @ Tuesday, February 10, 2009 8:23 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. For today's letter of "Z", I'll discuss PowerShell's internationalization features and it's support for country cultures like zh-CHT. PowerShell 2.0 added features that make script internationalization relatively simple to implement. The script internationalization features query the user interface culture of the operating system during execution, import the associated translated text strings, and allows you to display them to the user. To support international text, PowerShell 2.0 includes the following features: ...
posted @ Monday, February 09, 2009 1:27 PM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. For today's letter of "Y", I'll discuss PowerShell's host interface and, most importantly, it's ability to specify one of my favorite colors Yellow. PowerShell is really an engine that operates within a hosting application, the default being the PowerShell.exe command line application. The host serves to expose a command line and a host interface to communicate with the commands invoked by the command line. The Cmdlets There are several buildin...
posted @ Friday, February 06, 2009 9:13 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. For today's letter of "X", I'll discuss PowerShell's ability to work natively with XML. XML (Extensible Markup Language) is being used more and more in today's computing environments. PowerShell is no exception in that it uses XML for its type and configuration files as well as for it's help system. Since PowerShell uses XML so much internally, it makes sense that it has to expose a way to process XML documents...
posted @ Tuesday, January 27, 2009 9:42 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. For today's letter of "W", I'll talk about PowerShell's type-promiscuous feature of numeric widening. PowerShell is a type-promiscuous language in that PowerShell will do it's best to try to convert whatever type of literal you are using into the type you need with as little work on your part as possible. This means that if you want to multiple a number by a string representation of a number, it will behave as...
posted @ Monday, January 26, 2009 9:25 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. For today's letter of "V" I will talk about default statement output, and specifically voidable statements. In traditional programming languages, statements do not return a value. Think of the C++ increment operator in the following statement: "a++;". In this example the value of variable a is incremented by one. The value of the variable a is not returned from this statement. In fact, All C/C++/C# statements do not return values. This is...
posted @ Friday, January 23, 2009 8:12 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. For today's letter of "U" I will talk about PowerShell's automatic unraveling of collections. To unravel is to "separate or disentangle the threads" or "to free from complication or difficulty; make plain or clear". One problem that people run into with .NET methods that return enumerators is that PowerShell will unravel the enumerator by default. By this I mean that it will "take it apart" and put it in a format that...
posted @ Wednesday, January 21, 2009 9:15 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. For today's letter of "T" I will talk about type specification and, in particular, Type Literals. If you've seen any example PowerShell scripts, you've likely seen some syntax that looks like [type]. This is referred to as a type literal. In PowerShell, you can use type literals to specify a particular type for your operation. Type literals can be used in several ways. They can be used as operators in a type...
posted @ Tuesday, January 20, 2009 10:13 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. For today's letter is the letter "S", I will discuss PowerShell's extension of existing object with Synthetic Members. A powerful feature in PowerShell is it's ability to extend existing object types and instances. In doing so, it can overlay a common set of interfaces onto an existing source of data. This is different that the traditional method of sub-classing or creating types derived from other types in other object-oriented programming languages where...
posted @ Monday, January 19, 2009 10:12 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "R" and for it I'll cover the runspace. If you've downloaded PowerShell, you may think of PowerShell as a console application that is a replacement for the old CMD.EXE console. That is true in that the process is called PowerShell.exe, but there is much more to it. PowerShell is simply a console application that hosts the PowerShell runtime using a console window as a mechanism for allowing the...
posted @ Friday, January 16, 2009 10:08 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "Q" and there wasn't really much to go with. We've got the "-Quiet" switch but that's fairly limited in it's usage. I opted for it's support for the FIFO data structure: queues. A queue is a particular kind of collection in which the entities in the collection are kept in order. Operation on a queue are to add items to the end position and remove them from...
posted @ Wednesday, January 14, 2009 10:21 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "P" and for it I'll cover the basics of defining input values, or Parameters. Parameters (or arguments) are how you customize the actions of a command. There are 4 types of commands in PowerShell, scripts, functions, Cmdlet's, and External Commands. Scripts and Functions are the areas I'm going to focus on here and I'll show you how parameters are defined in those two command types. Scripts Scripts,...
posted @ Tuesday, January 13, 2009 10:55 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "O" and for this letter I'll discuss the Output system. PowerShell, like most other scripting languages, wouldn't be much use without an input and output system for retrieving or sending data. PowerShell has various output systems. The Pipeline A pipeline is a series of commands separated by the pipe operator "|". Each command in the pipeline receives an object from the previous command, performs some operation on...
posted @ Friday, January 09, 2009 10:33 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "N" and for this letter I'm going to discuss one of the core types of objects you'll likely be dealing with: Numbers. PowerShell supports all of the basic .NET numeric types and performs conversions to and from the different types as needed. The types, along with the PowerShell type names are in the following table .NET Full Type Name |...
posted @ Thursday, January 08, 2009 8:03 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "M" and I'm going to touch on the power of regular expressions and pattern Matching. Along with the basic comparison operators (-[ci]eq, -[ci]ne, -[ci]gt, -[ci]ge, -[ci]lt, -[ci]le, -[ci]contains, and -[ci]notcontains), PowerShell has a number of operators allowing one to perform pattern matching comparisons. These operators work on strings, matching and manipulating them using the wildcard and regular expression patterns. Wildcard Patterns ...
posted @ Wednesday, January 07, 2009 8:21 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "L". For "L" I'm going to give an overview on Location. The current working location is the default location to which commands point if you don't supply an explicit path to the item or location that is affected by the command. In most cases, the current working location is a directory on a drive supplied by the built-in FileSystem provider but it doesn't have to be. ...
posted @ Tuesday, January 06, 2009 8:23 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "K". I had some recommendations for "Kill" and "Keep" but I think I found one a little bit more topical. Today I'm going to talk about PowerShell keywords. First of all, let's talk about keywords. A keyword, in a programming language such as PowerShell, is a word or identifier that has a particular meaning to that language. In most languages, keywords are reserved words - meaning that...
posted @ Monday, January 05, 2009 10:52 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "J". Bet you thought I was going to go with Jagged Arrays for this one huh? Nope! Today's word is JavaScript. Huh? You may ask why I would pick JavaScript since that is a completely different scripting language and this is a series on PowerShell features. Well, I'm glad you asked. PowerShell is a very extensive scripting language, but it is relatively new to the scene of windows...
posted @ Friday, January 02, 2009 12:36 PM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "I". For "I", I opted for a couple of operators that you might not know about, but come in very handy with PowerShell's loosely typed framework. The word for today is "is" (with a double bonus of "isnot" and "as"). In a previous post, I talked about the PowerShell's Arithmetic Operators. In addition to Arithmetic, there are Assignment (=, +=, -=, *=, /=, %=), Comparison (-[ci]eq, -[ci]ne, -[ci]gt,...
posted @ Wednesday, December 31, 2008 11:46 AM | >
It's probably no surprise from those of you that follow my blog and tech tips here on DevCentral that I'm a fan of Windows PowerShell. I've written a set of Cmdlets that allow you to manage and control your BIG-IP application delivery controllers from within PowerShell and a whole set of articles around those Cmdlets. I've been a Twitter user for a few years now and over the holidays, I've noticed that Jeffrey Snover from the PowerShell team has hopped aboard the Twitter bandwagon and that got me to thinking... Since I live so much of my time in...
posted @ Tuesday, December 30, 2008 12:58 PM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "H". For "H", I'm going to talk about a feature that PowerShell Guru Jeffrey Snover loves talking about each time I see him: Here-Strings. Before we get to here-strings, it's probably a good idea to go over the different kinds of string literals in PowerShell. There are actually 4 different kinds of string literals - single-quoted strings, double-quoted strings, single-quoted here-strings, and double-quoted here-strings. All of these...
posted @ Tuesday, December 30, 2008 11:36 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "G". For "G" I've picked a feature that was introduced in version 2.0 of the .NET Framework that allows for creating more generic types of objects. So, today's word is "Generics". Generics allow you to create generic objects such as collections without being constrained to the specific type of object that it contains. Generics introduce the "type parameter" that you pass in to the creation of an object...
posted @ Monday, December 29, 2008 10:01 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "F". For "F" I've picked the word that relates to how you can make nice and pretty output. Today's word is the Format operator (-f).
Most often, PowerShell's build in output formatting is good enough for your needs. But, there will always be those times when you want a more fine grained control over the formatting of your output. You may also want to format strings in a specific...
posted @ Friday, December 19, 2008 10:27 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "E". For "E" I've picked the word that relates to how PowerShell's security model supports execution of scripts. Today's word is ExecutionPolicy. One of the main features of PowerShell is the ability to execute scripts. But, scripts are not inherently "safe" and since PowerShell has no concept of sandboxing, the execution of scripts are disabled by default. The default way to execute scripts is via the console interpreter....
posted @ Thursday, December 18, 2008 1:02 PM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "D". For "D" I've picked the a term that most everyone who writes scripts needs to understand. The word for today is debugging. Debugging is a very large category so I'll scan over the various components and dig more into script level debugging since that is what most users will use most often. Basic Error Handling PowerShell implements two types of errors: terminating and non-terminating. Terminating errors will...
posted @ Wednesday, December 17, 2008 12:42 PM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "C". For "C" I've picked the most efficient type type of commands supported by PowerShel, the CmdLet.
CmdLets (pronounced "Command-let"), functions, scripts, and native Win32 executables are the four types of commands supported in PowerShell. A Cmdlet is implemented by a .NET class that derives from the Cmdlet base class in the PowerShell SDK. This class is compiled into a DLL and loaded into the PowerShell process. Since a...
posted @ Tuesday, December 16, 2008 8:50 AM | >
Welcome to this addition of the PowerShell ABC's where you'll find 26 posts detailing a component of the PowerShell scripting language, one letter at a time. Today's letter is the letter "B". For "B" I've opted to go with a keyword that you likely don't know about but can allow you write script level functions that behave like compiled Cmdlets. The word for today is "begin"
Most PowerShell users write script level functions as standalone statements that work on values in the pipeline but since functions run all at once, they cannot do streaming processing. Filters can be used run...
posted @ Monday, December 15, 2008 11:42 AM | >
Well, now that I've got the Networking and Social Media ABC's completed it's time for another round of glossary fun and games. Being from a development background, I figure it's about time to focus on something a little more technical. For a while now, I've been toying with the PowerShell scripting language from Microsoft so I figure that's as good a place as any to get started on a new series. So, in the next 28 work days or so, be on the looking for another ABC listing of all the need goodies in the PowerShell language. Since there's...
posted @ Friday, December 12, 2008 2:42 PM | >
Day four on my DevCentral trip to Tokyo started with some work in the hotel room and preparations for my presentation at the first Japan DevCentral Users group meeting. I went through the slides once figuring that since I know the material pretty well, the flow of topics would be all I needed. Boy was I wrong. More the that later... At 11:00 we headed to the F5 offices to meet some colleagues, grab some lunch and head over to the user group meeting. We have been lucky enough on this trip to have some wonderful hosts that have...
posted @ Thursday, May 22, 2008 7:08 PM | >
A while back Jeff threw out a question on forums asking about where you have "firepassed" from. I'll throw up my latest example. Last Tuesday was very hectic for me, I had meetings and internal training at the office in Seattle in the morning and had to get back to home in Sammamish by 2:40 for a physical therapy session (I've got a pinched nerve in my neck that I've been treating for the last month or so if you are interested). Anyway, at about 1:15 I had an idea about a tech tip for DevCentral, so I...
posted @ Thursday, September 13, 2007 3:37 PM | >
When we shipped DC4, we started looking at Windows PowerShell and how we could build some integration points with our products. The first pass was a set of PowerShell script files that we introduced in the PowerShell Labs section of DevCentral. No soon after we posted them, the requests started pouring in on when we would provide some native PowerShell CmdLets in addition to the function scripts.
Well, I spent a little bit of time working some out and whipped out a good first rough draft. I've been holding on to these for a while now but figured they would...
posted @ Wednesday, June 20, 2007 4:58 PM | >
In the last few months, I've been focused on Microsoft Technologies such as PowerShell, Windows Mobile, MOM, and most recently the iControl Assembly written in C# with Microsoft VisualStudio.
I've never been a professional Java developer so I never really got into extending the network in the java arena. Sure, I wrote a bunch of java samples to include with the iControl SDK, but those were nothing more than a bunch of command line scripts. Luckily for all of you, we now have Don on our team and he has started on some pretty cool Java related projects.
So, I got to thinking......
posted @ Tuesday, May 22, 2007 4:26 PM | >