Archive for the 'Source control' Category

Dynamsoft online source control in PowerGUI Script Editor

Claus Thude Nielsen posted a step by step tutorial on how you can get PowerGUI’s version control system to use Dynamsoft.

Which is very cool because Dynamsoft:

  • Is a cloud system – so someone hosts that for you and can get to your files from anywhere,
  • It is free for up to 25 MB – and 25 MB is a lot of PowerShell scripts!

Learn more about Dynamsoft and get the step-by-step tutorial here.

Also, I have previously published similar tutorials on:

Subversion (SVN) Source-Control for PowerShell Scripts

I’ve already blogged about the use of PowerGUI Pro Script Editor with Team Foundation Server (TFS), now it’s time to check out integration with another popular source control solution – Subversion.

As with any other revision control system, to integrate PowerGUI needs you to install an MSSCCI provider for the system (this is the API which Microsoft Visual Studio is using). For Subversion there is a bunch of clients available – so use whichever you like as long as MSSCCI is one of its features.

For this post I used TamTam SVN SCC. It seems to be a great client however you would need to pay the author $14.99 unless you enjoy seeing their “Buy now” prompts every few minutes. 😉

(If you really want to save the $14.99 there is also a free SCC client for Subversion: TortoiseSVN – however, you would have to spend a few minutes to make it work because the SCC provider is only supported by a fairly old version of the client – 1.3.5. If you want to go that route, download version 1.3.5 of the client here, and install it along with the TortoiseSVNSCC provider found in Documents & Files section here. You might also have to apply some registry keys on Vista and later.)

Anyway, I went the easy way:

1. Downloaded and installed Subversion v1.4.3 and TamTam SVN SCC .

2. In PowerGUI Pro Script Editor, went to Tools / Options / Version Control, selected TamTam as the Current provider and browsed to the svn.exe file.

3. Now I can add files to Subversion, check out, check in, and so on by using the Version Control menu in the editor:

Protecting PowerShell Scripts with Team Foundation Server (TFS)

PowerGUI Pro Script Editor 2.0 integrates with multiple source control systems. In this blog post I will guide you through setting it up to work with Microsoft Visual Studio Team Foundation Server.

First of all, the machine on which you are doing your script development needs to have the following prerequisites from Microsoft:

  • Microsoft Visual Studio Team Explorer – the setup ships with Team Foundation Server.
  • Install Team Foundation Server MSSCCI Provider – it is a free download from microsoft.com but you need to make sure you pick the same version as your VS installation: 2005, 2008, or 2010 (currently RC).

Now you are ready to start using TFS inside PowerGUI!

  1. Start PowerGUI Pro Script Editor
  2. In Tools / Options / Version Control / Current provider, select Team Foundation Server MSSCCI Provider.

Once you’ve done that checking in your scripts is trivial. When you save a script, you will be prompted whether you want to add it to the source control project:

And if you click Yes you will be able to pick the TFS server and project:

And then supply your check-in comments:

After that the Tab displaying the script will have a blue check indicating that the file is under source control, and you will be able to use Version Control menu or toolbar to check in/check out the file and perform other source-control-related operations:

One final comment to add, is that if this is a fresh machine and there already exists a TFS project which you want to join and from which you want to download all existing files, you may do so using the Visual Studio or Visual Studio Team Explorer. All you need to do is add the server/project in File / Source Control / Open from Source Control menu, then double-clicking Source Control in Team Explorer, and Getting Latest Version of the projects you need:

I hope this makes your scripting even safer and more compliant with your corporate policies.


My Recent Tweets

Legal

The posts on this blog are provided “as is” with no warranties and confer no rights. The opinions expressed on this site are mine and mine alone, and do not necessarily represent those of my employer - WSO2 or anyone else for that matter. All trademarks acknowledged.

© 2007-2014 Dmitry Sotnikov

December 2019
M T W T F S S
« Oct    
 1
2345678
9101112131415
16171819202122
23242526272829
3031  

%d bloggers like this: