Skip to content

Instantly share code, notes, and snippets.

@gerane
Last active February 2, 2017 13:58
Show Gist options
  • Save gerane/84f099aaf9a80c1072ec7ab5094c2579 to your computer and use it in GitHub Desktop.
Save gerane/84f099aaf9a80c1072ec7ab5094c2579 to your computer and use it in GitHub Desktop.
# PSDeploy
Deploy ExampleDeployment {
By FileSystem Scripts {
FromSource 'SomeScripts'
To 'C:\PSDeployTo'
Tagged Dev
DependingOn ExampleDeployment-Modules
}
By FileSystem Modules {
FromSource MyModule
To C:\PSDeployTo
Tagged Build
WithOptions @{
Mirror = $true
}
}
By PSGalleryModule {
FromSource $ENV:BHPSModulePath
To PSGallery
Tagged Publish
WithOptions @{
ApiKey = $ENV:NugetApiKey
}
}
}
# Example of DSL for Build. The Build and Deploy could be combined into a single config.
Build ExampleBuild {
Task Init {
Clean $True
}
Task Build {
With PSDeploy
Tag Build
StepVersion Minor
DependingOn Init
}
Task Test {
Path "$ProjectRoot\Tests"
DependingOn Build
}
Task Publish {
With PSDeploy
Tag Publish
DependingOn Test
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment