capistrano-rsync-bladrak 1.3.2 → 1.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/README.md +2 -1
- data/lib/capistrano/rsync.rb +23 -3
- data/lib/capistrano/rsync/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6b76adfe7757ac58921b5d2de5d5ba2c00cf2a02
|
4
|
+
data.tar.gz: 2e932bb014c955142d65fd4a408861a3819a580c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5b43d974bd1c6904fc95a86d8f1e5263af62a297806c69db873450f552cd99548687e335fc9b9f0864fc36cbc379d03bc15e33d5226bafb63d08ade9004848a8
|
7
|
+
data.tar.gz: 9fb48e3646db6c892598f99b332c26029c4382dc662c474fad5f0d0ea0d344e2b75f568334848ff353e2bf476f3c8e71b328c7df0fcc953673d0615f9e2133d0
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,6 @@
|
|
1
|
+
## 1.3.3 (Jul 15, 2015)
|
2
|
+
- Adds support for checking out revisions on top of tags and branches (rsync_checkout_tag is now deprecated)
|
3
|
+
|
1
4
|
## 1.3.0 (Jul 2, 2015)
|
2
5
|
- Refactored library to use run_locally and execute from Capistrano, so the output is uniformized & we exit on failed commands
|
3
6
|
- Added some options as well (see README.md for complete list)
|
data/README.md
CHANGED
@@ -131,7 +131,8 @@ rsync_cache | `shared/deploy` | Path where to cache your repository on the ser
|
|
131
131
|
rsync_options | `[]` | Array of options to pass to `rsync`.
|
132
132
|
rsync_sparse_checkout | `[]` | Array of directories to checkout (checks out all if empty)
|
133
133
|
rsync_depth | `1` | Sets the --depth argument value for the git operations; this is set to 1 by default as you won't need the git history
|
134
|
-
|
134
|
+
rsync_checkout | `branch` | Is the ``:branch`` symbol containing a branch, tag or revision?
|
135
|
+
rsync_checkout_tag | `false` | Is the ``:branch`` symbol containing a branch or a tag? ``Deprecated``
|
135
136
|
rsync_copy | `rsync --archive --acls --xattrs` | The command used to copy from remote cache to remote release
|
136
137
|
rsync_target_dir | `.` | The local directory within ``:rsync_stage`` to clone to & deploy (useful if you want to keep cache of several branches/tags for instance)
|
137
138
|
enable_git_submodules | `false` | Should we fetch submodules as well?
|
data/lib/capistrano/rsync.rb
CHANGED
@@ -8,9 +8,17 @@ set_if_empty :rsync_copy, "rsync --archive --acls --xattrs"
|
|
8
8
|
# Sparse checkout allows to checkout only part of the repository
|
9
9
|
set_if_empty :rsync_sparse_checkout, []
|
10
10
|
|
11
|
-
#
|
11
|
+
# Merely here for backward compatibility reasons
|
12
12
|
set_if_empty :rsync_checkout_tag, false
|
13
13
|
|
14
|
+
# Option states what to checkout
|
15
|
+
set_if_empty :rsync_checkout, "branch"
|
16
|
+
|
17
|
+
# To be somewhat backward compatible to the previous checkout_tag option
|
18
|
+
if fetch(:rsync_checkout_tag, false)
|
19
|
+
set :rsync_checkout, "tag"
|
20
|
+
end
|
21
|
+
|
14
22
|
# You may not need the whole history, put to false to get it whole
|
15
23
|
set_if_empty :rsync_depth, 1
|
16
24
|
|
@@ -40,12 +48,24 @@ rsync_cache = lambda do
|
|
40
48
|
end
|
41
49
|
|
42
50
|
rsync_target = lambda do
|
43
|
-
|
51
|
+
case fetch(:rsync_checkout)
|
52
|
+
when "tag"
|
53
|
+
target = "tags/#{fetch(:branch)}"
|
54
|
+
when "revision"
|
55
|
+
target = fetch(:branch)
|
56
|
+
else
|
57
|
+
target = "origin/#{fetch(:branch)}"
|
58
|
+
end
|
44
59
|
target
|
45
60
|
end
|
46
61
|
|
47
62
|
rsync_branch = lambda do
|
48
|
-
|
63
|
+
if fetch(:rsync_checkout) == "tag"
|
64
|
+
branch = "tags/#{fetch(:branch)}"
|
65
|
+
else
|
66
|
+
branch = fetch(:branch)
|
67
|
+
end
|
68
|
+
|
49
69
|
branch
|
50
70
|
end
|
51
71
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: capistrano-rsync-bladrak
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.3.
|
4
|
+
version: 1.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Hugo Briand, Andri Möll
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-07-
|
11
|
+
date: 2015-07-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: capistrano
|