Skip to content

Commit

Permalink
[docs] working docs gen
Browse files Browse the repository at this point in the history
  • Loading branch information
haf committed Dec 19, 2015
1 parent 3840571 commit 04558ae
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 15 deletions.
19 changes: 5 additions & 14 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -162,17 +162,15 @@ Albacore::Tasks::Release.new :release,
namespace :docs do
desc 'clean generated documentation'
task :clean do
FileUtils.rm_rf 'docs/gh-pages' if Dir.exists? 'docs/gh-pages'
FileUtils.rm_rf 'docs/_site' if Dir.exists? 'docs/_site'
end

task :reference => :restore_paket do
system 'packages/docs/FsLibTool/tools/FsLibTool.exe', %W|src|, clr_command: true
system 'packages/docs/FsLibTool/tools/FsLibTool.exe', %W|src docs/_site|, clr_command: true
end

task :gh_pages do
system 'git clone https://github.com/SuaveIO/suave.git -b gh-pages docs/gh-pages' \
unless Dir.exists? 'docs/gh-pages'
Dir.chdir 'docs/gh-pages' do
task :jekyll do
Dir.chdir 'docs' do
Bundler.with_clean_env do
system 'bundle'
system 'bundle exec jekyll build'
Expand All @@ -181,14 +179,7 @@ namespace :docs do
end

desc 'build documentation'
task :build => [:clean, :restore_paket, :gh_pages, :reference]

desc 'build and push docs'
task :push => :'docs:build' do
system "sshpass -p #{ENV['SUAVE_SERVER_PASS']} scp -P #{ENV['SUAVE_SERVER_PORT']} -r _site/* [email protected]:/home/suave/site",
work_dir: 'gh-pages',
silent: true
end
task :build => [:clean, :restore_paket, :jekyll, :reference]
end

task :docs => :'docs:build'
2 changes: 1 addition & 1 deletion paket.lock
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ NUGET
remote: https://nuget.org/api/v2
specs:
FSharp.Core (4.0.0.1)
FsLibTool (0.1.0)
FsLibTool (0.1.1)
FSharp.Core (>= 4.0.0.1)
PPrint (>= 1.4.3)
PPrint (1.4.3)
Expand Down

0 comments on commit 04558ae

Please sign in to comment.