Skip to content

Commit 59233a0

Browse files
committed
Ticket #199 : Add publishWebsite task
1 parent 2515114 commit 59233a0

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

default.ps1

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,4 +180,21 @@ task test {
180180
} finally {
181181
Pop-Location
182182
}
183+
}
184+
185+
task publishWebsite {
186+
exec { git checkout gh-pages }
187+
exec { git rm -r . }
188+
exec { git checkout HEAD -- .gitignore }
189+
exec { git add . }
190+
exec { git commit -m "Remove" }
191+
exec { git checkout master }
192+
exec { docfx ./docs/docfx.json }
193+
exec { Copy-item -Force -Recurse -Verbose "./docs/_site/*" -Destination "." }
194+
exec { git checkout gh-pages --merge }
195+
exec { git add . }
196+
exec { git commit -m "Update Documentation" }
197+
exec { git rebase -i HEAD~2 }
198+
exec { git push origin gh-pages }
199+
exec { git checkout master }
183200
}

0 commit comments

Comments
 (0)