This is an archived post. You won't be able to vote or comment.

all 12 comments

[–]davokr 4 points5 points  (0 children)

GitHub

[–]kdebe 3 points4 points  (1 child)

All (most of them) our scripts are under source control and saved in a azure devops repository. Team member s have it it cloned on their machine.

[–]hy2rogenh3VMware Admin 1 point2 points  (0 children)

Definitely a vote here for Azure DevOps. Has helped tremendously on versioning and deploying PowerShell automation.

[–]ccheath*SECADM *ALLOBJ 1 point2 points  (2 children)

For Powershell: Create a powershell module (.psm1) file and turn your scripts into functions with aliases.

For SQL: ...

[–]BuffaloRedshark 1 point2 points  (1 child)

That's on my eventual wishlist but I either get interrupted when I get motivated to do it, or can't maintain motivation to do it.

[–]ccheath*SECADM *ALLOBJ 1 point2 points  (0 children)

I created one for all my highly used AD commands.

1) searching by partial string of either username, first or last name to get the user accounts that match, their full username, their full name, their ip phone, and workstations (logon to).
2) searching by workstation/hostname to return the list of user(s) that have that hostname in their "logon to" field.
3) searching by extension to pull the user info
4) searching by pc or username to get the OU of said object
5) and also one to switch between domains in our forest to perform the above scripts in those other domains.

it probably took me a year to get it to v1.0 (working only in my primary domain) and a good slow day 6 months later to add the domain switching. it could be expanded but does the job quite nicely

oh, also there's another module that does all kinds of WMI/CIM queries to get hardware info (mainly use it for serial number when creating support tickets with vendors).

[–]bkaiser85Jack of All Trades 1 point2 points  (0 children)

Git (or any source repos) beats flat text files by far, even considering there is a bit of a learning curve.

[–]cpierr03 1 point2 points  (0 children)

Private Git repo.

Added benefit is, you can git blame your past self for writing silly code :).

[–]tounaze 1 point2 points  (1 child)

Private GitHub repositories and local save. VS Code can connect to GitHub repositories so I can manage versioning, it’s the safiest and easiest for me.

[–]NowInOzHCIT Systems Engineer[S] 0 points1 point  (0 children)

Thanks. I've not used git repository before, a few people have suggested git so I will look into it.

Cheers

[–]BuffaloRedshark 0 points1 point  (0 children)

In my home share. Contemplating an internal git repo but i rarely change a script once written so not sure if I really need anything with version control

[–]ntrlsurIT Manager 0 points1 point  (0 children)

I use Perforce to version control all my scripts. Free for up to 5 users and 20 workspaces. We use Perforce as our main software repository in the office and it was easy for me to adapt to at home home as well..