Skip to content

Instantly share code, notes, and snippets.

@Tesla9527
Created January 26, 2016 06:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Tesla9527/89513b597d3e097b5b7f to your computer and use it in GitHub Desktop.
Save Tesla9527/89513b597d3e097b5b7f to your computer and use it in GitHub Desktop.
$connectionString = "Data Source=shaappt0001;Initial Catalog=Bpm;Persist Security Info=true;User ID=sa;PWD=Passw0rd;Packet Size=4096;" providerName="System.Data.SqlClient"
$webConfigPath = "%teamcity.build.workingDir%\Bpm\web.config"
$xml = [xml](get-content $webConfigPath)
$root = $xml.get_DocumentElement();
$root.connectionStrings.add.connectionString = $connectionString
$xml.Save($webConfigPath)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment