r/PowerShell • • Apr 23 '19

Hacked together my first script in Powershell!

I'm an IT Intern for a small manufacturing company, and I've never dealt with powershell before. I was tasked with a really messy task of writing a script to open a program at startup, with the program existing in a folder labeled with an arbitrary name for each domain user.

I used a get-childitem and some parameters to find the first (and only) folder in the directory and then return it as a variable . I was able to plug that into an invoke-item and it opened. This simple task is calculated to save the company over 3000 dollars over the next month!

153 Upvotes

21 comments sorted by

View all comments

0

u/[deleted] Apr 23 '19

[deleted]

1

u/jchaven Apr 24 '19

He's a real IT boy/girl now.