First, start out by reading my blog from two days ago titled “Meet the People of PowerShell at PowerShell.org/People and PowerShell.net” otherwise you’ll be starting in the middle of the story and this blog will only end up causing confusion.
To change an item on your PowerShell People profile page, the item has to be removed and then re-added. With that said, we’ll cover removing an item and see the previous blog article referenced in the first paragraph for how to add it back.
In this example, I’ll remove twitter from my PowerShell People profile:
I start out by running the prerequisites region of my sample script and specifying my existing username and password when prompted:
There’s an example of removing twitter in the sample script. I’ve highlighted and run only that section of the script. I can see based on the results, it removed twitter:
Refreshing the web browser shows twitter has been removed from my profile:
Let’s take a look at what really happens when twitter is removed. Prior to running the script to remove twitter, I can see a twitter tag in my profile with my twitter handle in it:
In the previous example, Format-XML is used which is a cmdlet from the PowerShell Community Extensions PowerShell module (pscx).
After running the command to remove twitter from my profile, the twitter tag is completely removed:
Where this is really helpful, is in the following scenario. I’m now going to remove my blog website from my PowerShell People profile:
Why didn’t it remove my blog website? No error or anything? There must be something wrong with the PowerShell People profile site, right? Wrong, it is a PICNIC error.
Let’s go back and see what string is in the URL field for my blog website. The URL contains a backslash at the end of it that wasn’t specified in my previous attempt to remove it:
Specifying the URL that actually exists removes the website without issue:
You should also be able guess what the type, tag name, and data is based on this information so that removing the information via PowerShell is fairly straight forward. You could also view your data along with all the tags very easily using a GUI, but then you wouldn’t have to learn how to do this in PowerShell and what fun what that be?