-
-
Notifications
You must be signed in to change notification settings - Fork 40
/
Copy pathrakefile
38 lines (33 loc) · 781 Bytes
/
rakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
require './RakeHelpers.rb'
desc 'The default function. This will run when you type "rake"'
task :default do
puts "Hello World!";
end
desc 'Serves locally'
task :serve do
system("jekyll serve --incremental --port 4000 --config _config.yml,_config-dev.yml")
end
desc 'Deploy'
task :deploy do
if RakeHelpers::isclean() && RakeHelpers::ismaster()
puts "Clean and on master"
status = system("git push")
status = true
if status
status = system("jekyll build")
if status
puts "Code to upload to S3 will go here!"
system("s3_website push")
end
end
elsif !RakeHelpers::isclean()
puts "Not clean"
elsif !RakeHelpers::ismaster()
puts "Not on master"
end
end
desc 'Gets git master status'
task :status do
`git checkout master`
puts `git status`
end