Scripts By mjolinor

  • out-tempfile.ps1 by mjolinor 21 Apr 2011 10:53 PM UTC
    by 3 users

    Advanced Event 10
    1 Comments

    Creates a temporary (.tmp) file in the system temp directory, and writes pipeline input to the file. Encoding and newlines can be specified by parameters, and will optionally open the file in Notepad after writing. Checks for interactive user environment before running Notepad, and prompts for verification before opening large files. Includes support for shouldprocess, provided debug and verbose output.

  • get-friendlyandtwitternames_fromurl by mjolinor 16 Apr 2011 12:22 AM UTC
    by 2 users

    Advanced Event 7
    1 Comments

    Gets the twitter names from a given url along with their associated friendly names, and returns an array of PS objects with FriendlName and TwitterName properties. Script uses 2 fuctions, get-webpagedata to retrieve the data from the web page, and new-psobjectfrommatches that takes the data as pipeline input and creates the objects, using a regular expression and a list of property names provided as parameters. Both functions are re-used from Advanced Event 6, and the new-psobjectfrommatches can be used to create ps objects from any [string[]] input that can be parsed using a capturing regular expression. Write-debug statements are provided to show how the data is being matched and captured, and how the property names are being applied to the matches.

  • get-friendlyandtwittername_fromurl by mjolinor 16 Apr 2011 12:19 AM UTC
    by 2 users

    Beginner Event 6

    Gets the twitter names from a given url along with their associated friendly names, and returns an array of PS objects with FriendlName and TwitterName properties. Script uses 2 fuctions, get-webpagedata to retrieve the data from the web page, and new-psobjectfrommatches that takes the data as pipeline input and creates the objects, using a regular expression and a list of property names provided as parameters. Both functions are re-used from Advanced Event 6, and the new-psobjectfrommatches can be used to create ps objects from any [string[]] input that can be parsed using a capturing regular expression. Write-debug statements are provided to show how the data is being matched and captured, and how the property names are being applied to the matches.

  • get-twitternames_fromurl by mjolinor 16 Apr 2011 12:15 AM UTC
    by 2 users

    Advanced Event 6
    1 Comments

    Gets the twitter names from a given url and returns an array of PS objects with a TwitterName property. Script uses 2 fuctions, get-webpagedata to retrieve the data from the web page, and new-psobjectfrommatches that takes the data as pipeline input and creates the objects, using a regular expression and a list of property names provided as parameters. Both functions are re-used for Advanced Event 7, and the new-psobjectfrommatches can be used to create ps objects from any [string[]] input that can be parsed using a capturing regular expression. Write-debug statements are provided to show how the data is being matched and captured, and how the property names are being applied to the matches.

  • get-currentserverevents by mjolinor 07 Apr 2011 02:33 AM UTC
    by 2 users

    Advanced Event 3

    Retrieves a list of all the servers in the domain running Windows Server OS, finds the active classic and ETL event logs that have log entries, and retrieves a limited number of the newest events from today.

  • getcurrentserverevents by mjolinor 07 Apr 2011 02:19 AM UTC
    by 2 users

    Beginner Event 1
    2 Comments

    Gets the most recent current (today's) events from all servers in the domain

  • SG2011_ADV2.ps1 by mjolinor 05 Apr 2011 10:51 PM UTC
    by 2 users

    Advanced Event 2

    Get-serverlist function returns a list of all the computers in the domain running Window Server OS. write-dependentstatus filter takes a computername as pipeline input, and outputs the computer name, all currently running services, and the current status of all dependent services of the running services.

  • get-moduleversion by mjolinor 05 Apr 2011 02:09 AM UTC
    by 3 users

    Advanced Event 1
    1 Comments

    Gets module version information from a given executable and module Description for all computers in the domain.