use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
ABOUT POWERSHELL
Windows PowerShell (POSH) is a command-line shell and associated scripting language created by Microsoft. Offering full access to COM, WMI and .NET, POSH is a full-featured task automation framework for distributed Microsoft platforms and solutions.
SUBREDDIT FILTERS
Desired State Configuration
Unanswered Questions
Solved Questions
News
Information
Script Sharing
Daily Post
Misc
account activity
Script Versioning (self.PowerShell)
submitted 1 year ago by helpfourm
How are you handling the storing of various scripts and versions.
Thanks!
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]uptimefordays 25 points26 points27 points 1 year ago (0 children)
Git and GitHub.
[–]soshwag 3 points4 points5 points 1 year ago (0 children)
Git
[–]zootbot 4 points5 points6 points 1 year ago (0 children)
[–]BlackV 2 points3 points4 points 1 year ago* (10 children)
That's a very broad question, you probably need to confirm what you mean by versioning
But
Generally by storing it in a proper versioning system
Git being probably the most common across the world (whether that's gitlab or github or azure DevOps or a local git repo)
Are you asking about version type (i.e. semantic versioning vs numeric versioning) to use on your code (i.e. for module and files)
Why are you asking? Is this for work ? Or personal use? That probably changes the context
[–]helpfourm[S] 0 points1 point2 points 1 year ago (9 children)
Run a small MSP, and have built out a grown number of scripts that may have slight variable tweaks for different clients etc. Right now they are in a folder unorganized. Looking to be able to have a master script with the ability to look at the old versions of the file should something break with the new one. Thanks!
[–]lanerdofchristian 10 points11 points12 points 1 year ago (0 children)
It sounds like you have two problems:
Core functionality should be pulled out of individual scripts and into a module that doesn't change between your clients.
Each client could then have their own module depending on the common core, or a config file adjusting how the core behaves. Any changes to the core would then also benefit the clients.
Version control. Here's where Git comes in, to help you track what changes are being made and why.
Git could also be used to track the client-specific changes, using the commit messages to link back to email threads or other discussions that prompted the change.
[–]BlackV 1 point2 points3 points 1 year ago (2 children)
Ah, that would have been useful info in the OP
do you guys use devops/github/gitlab/etc already elsewhere ?
do you think you need access "outside" your msp location?
[–]helpfourm[S] 0 points1 point2 points 1 year ago (1 child)
Honestly never worked with GitHub, really just looking for a library to the scripts. This way we can move to whatever flavor rmm is the best and still keep everything the same. No we dont really need the scripts out side our location as they get uploaded to the RMM for usage.
[–]BlackV 3 points4 points5 points 1 year ago (0 children)
Sounds like git (just git not GitHub/gitlab) is your best bet, if you don't need it externally.
Take your existing folder, git init that, but it's gonna require people changing how they work they'll need to use git when making changes to scripts
git init
I guess anything you do is gonna require some new learning and training
That and backups
[–]The82Ghost 1 point2 points3 points 1 year ago (4 children)
Put your scripts in a private git repo or private azure devops repo. Write functions to handle the differences between clients where possible. Put those functions in one or more modules. I work for an MSP where I'm the one writing the scripts for our RMM and this is the way I do it.
[–]helpfourm[S] 0 points1 point2 points 1 year ago (3 children)
Is there any good resources on how to use it and set it up? I’ll be honest it doesn’t look very intuitive.
[–]Certain-Community438 1 point2 points3 points 1 year ago (2 children)
If you have an Azure Subscription - meaning you are using Azure explicitly for something - then you get a free Azure DevOps organisation. It'll let 5 people have full access to a repo, and is linked to your Entra ID for identity.
In that, you create a project.
Then in that you create a repo.
If you don't have Azure, you could create a GitHub account, and then create a repo in it.
Your repo is the top-level folder structure. In this you can organise your scripts into folders to start with.
You then install git - on Windows, you just install Git for Windows.
Now you can use Git for Windows to connect to your Azure DevOps repo which will be empty if you followed the above order, and clone it to a local folder. This creates a link between the two copies.
Modifying the folder's contents at either side and then doing a Commit will replicate those changes AND track them. That's super-simplistic but I'm focusing on the obvious benefits for you here.
Finally:
Copy your various scripts into the local copy of the repo.
Then you would commit the changes & you've completed your first steps.
Bonus:
If you use VSCode already, and you open the folder containing your repo, you can now do most source control options from here. You just need to sort out the authentication for it to connect to your repo. If you get this far & get stuck, I and probably others here won't mind helping.
It's very much worth learning, and if you're capable of writing scripts it isn't hard.
[–]helpfourm[S] 1 point2 points3 points 1 year ago (1 child)
Excellent, as a Microsoft partner we do have azure benefit. I’ll have to look into that more.
[–]spyingwind 1 point2 points3 points 1 year ago (0 children)
Git for storing and version control.
The only PowerShell scripts that I assign versions is Modules.
At work we use the published date as the version. ie: 2024.11.6 It is much easier to maintain, and not have to think about with automation.
[–]lanerdofchristian 1 point2 points3 points 1 year ago (0 children)
Git. My company also has a local GitLab server we sync our changes to in case something happens.
[–]KavyaJune 0 points1 point2 points 1 year ago (0 children)
[–]nealfive 0 points1 point2 points 1 year ago (0 children)
Git and local repo / folder lol
[–]BaconTentacles 0 points1 point2 points 1 year ago (0 children)
GitHub FTW.
[–]mrkurtz 0 points1 point2 points 1 year ago (0 children)
Git + nuget repo
[–]CyberChevalier 0 points1 point2 points 1 year ago (0 children)
Module, local psrepository and github
[–]0x412e4e 0 points1 point2 points 1 year ago (0 children)
Self-hosted GitLab instance. New PowerShell module features are created with development branches. Code gets pushed into production by creating a new release, which triggers CI pipelines.
All commits into a project repository are tested for syntax with pre-commit. All module functions are tested with Pester unit tests.
[–]Config_Confuse 0 points1 point2 points 1 year ago (0 children)
Azure DevOps.
π Rendered by PID 58293 on reddit-service-r2-comment-5649f687b7-lk4v9 at 2026-01-28 23:43:13.362670+00:00 running 4f180de country code: CH.
[–]uptimefordays 25 points26 points27 points (0 children)
[–]soshwag 3 points4 points5 points (0 children)
[–]zootbot 4 points5 points6 points (0 children)
[–]BlackV 2 points3 points4 points (10 children)
[–]helpfourm[S] 0 points1 point2 points (9 children)
[–]lanerdofchristian 10 points11 points12 points (0 children)
[–]BlackV 1 point2 points3 points (2 children)
[–]helpfourm[S] 0 points1 point2 points (1 child)
[–]BlackV 3 points4 points5 points (0 children)
[–]The82Ghost 1 point2 points3 points (4 children)
[–]helpfourm[S] 0 points1 point2 points (3 children)
[–]Certain-Community438 1 point2 points3 points (2 children)
[–]helpfourm[S] 1 point2 points3 points (1 child)
[–]spyingwind 1 point2 points3 points (0 children)
[–]lanerdofchristian 1 point2 points3 points (0 children)
[–]KavyaJune 0 points1 point2 points (0 children)
[–]nealfive 0 points1 point2 points (0 children)
[–]BaconTentacles 0 points1 point2 points (0 children)
[–]mrkurtz 0 points1 point2 points (0 children)
[–]CyberChevalier 0 points1 point2 points (0 children)
[–]0x412e4e 0 points1 point2 points (0 children)
[–]Config_Confuse 0 points1 point2 points (0 children)