middleman-gh-pages 0.1.1 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/middleman-gh-pages/tasks/gh-pages.rake +4 -4
- data/lib/middleman-gh-pages/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8e0d79113909c3b269d4b1ebd04e5753bf7c4430
|
4
|
+
data.tar.gz: e56c32ff8116c180d9c2bf33b7a80df63211b17f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f96911891076c34bfb013c89dce3b55d3fe3ab35b38bdc385ecc0988882051d2fb03a6a6ca1a4014d422c2b1cc1f3a14cb4602dc551f0a3991b5cf24742b5777
|
7
|
+
data.tar.gz: 74f962062a72aa1b9cd650edac9b076791d08b053af510b0ed4c14c491dc6ee738e2269c646f49dc284622cd25fcebe9c37404f3b0fadb368e5e4261b386d56c
|
@@ -53,10 +53,10 @@ file GH_PAGES_REF => BUILD_DIR do
|
|
53
53
|
end
|
54
54
|
|
55
55
|
# Alias to something meaningful
|
56
|
-
task :
|
56
|
+
task :prepare_build_dir => GH_PAGES_REF
|
57
57
|
|
58
58
|
# Fetch upstream changes on gh-pages branch
|
59
|
-
task :
|
59
|
+
task :sync_build_dir => :prepare_build_dir do
|
60
60
|
cd BUILD_DIR do
|
61
61
|
sh "git fetch #{remote_name}"
|
62
62
|
sh "git reset --hard #{remote_name}/#{branch_name}"
|
@@ -64,7 +64,7 @@ task :sync do
|
|
64
64
|
end
|
65
65
|
|
66
66
|
# Prevent accidental publishing before committing changes
|
67
|
-
task :
|
67
|
+
task :prevent_dirty_builds do
|
68
68
|
if uncommitted_changes?
|
69
69
|
puts "*** WARNING: You currently have uncommitted changes. ***"
|
70
70
|
fail "Build aborted, because project directory is not clean." unless ENV["ALLOW_DIRTY"]
|
@@ -81,7 +81,7 @@ task :build do
|
|
81
81
|
end
|
82
82
|
|
83
83
|
desc "Build and publish to Github Pages"
|
84
|
-
task :publish => [:
|
84
|
+
task :publish => [:prevent_dirty_builds, :sync_build_dir, :build] do
|
85
85
|
message = nil
|
86
86
|
suffix = ENV["COMMIT_MESSAGE_SUFFIX"]
|
87
87
|
|