Skip to content

Commit

Permalink
Add dev scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
Scott Bommarito committed Mar 20, 2019
1 parent 795b88c commit 2fe899d
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
2 changes: 2 additions & 0 deletions scripts/Setup-DevEnvironment.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
. "$PSScriptRoot/Setup-Submodule.ps1"
. "$PSScriptRoot/Setup-SslCertificate"
16 changes: 16 additions & 0 deletions scripts/Setup-Submodule.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
Function Invoke-Git {
[CmdletBinding()]
Param(
[string[]] $Arguments
)

# We are invoking git through cmd here because otherwise the redirection does not process until after git has completed, leaving errors in the stream.
Write-Host "git $Arguments"
& cmd /c "git $Arguments 2>&1"
}

Write-Host 'Resetting submodules'
Invoke-Git -Arguments ('submodule', 'deinit', '--all', '-f')

Write-Host "Updating submodules"
Invoke-Git -Arguments ('submodule', 'update', '--init', '--')

0 comments on commit 2fe899d

Please sign in to comment.