capistrano-sozo_magento2 1.6.0 → 1.7.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: dcc222d9e3fc341f69b780d94f5179850bee32fc6fbf9d5ca21872eace7a72a4
4
- data.tar.gz: 1f0aa60540f6c2b1d3d0e23200d46f6543b0c1f1f63bf42210b070c09b85efef
3
+ metadata.gz: 923ebdbd8e0af793979bc643b64dcf620b6a41339e7a0a37fd1493d4c0ebe394
4
+ data.tar.gz: 96129ba2ee73f1f05a3e920676b8b70ed3dc1b0a2e70e500c31c19c0f75cfca1
5
5
  SHA512:
6
- metadata.gz: df41ec7d95247860cf3cd56661457fba36053378d1c4b1f600324f3a4c352183c3321555ba51b332576507c8e7df95e9ef9e9ecb80e9919fd9dbde3e5d8c2a11
7
- data.tar.gz: 34beb143b6d773664423c93361df841495625aabacaff27e0ae17fe4cc74a94ec711f03b89ea65270fe8d025758e5b52e05914c059df89f0666c7fb638e2c4fc
6
+ metadata.gz: 0a084753174d86a81c8af5fa6b4b6334121688f924cddabdb0107f34012d09db7a6106531e058de9fc833a256170f18f23597a1cb640cde3ab94f345e07991c5
7
+ data.tar.gz: 8b2e192b898f69a731df2f1e38a1fcd83bd01691eefe336cb88e848a00957043d8432919827c09e8248dca394a36ef7b736ff1f8aadae7541edca3075bfc4b49
data/CHANGELOG.md CHANGED
@@ -21,6 +21,15 @@ Given a version number MAJOR.MINOR.PATCH, increment the:
21
21
 
22
22
  ## [Unreleased]
23
23
 
24
+
25
+ ## [v1.7.0] - 2022-09-22
26
+ ### Changed
27
+ - Fixed checks for branch existence to include tags.
28
+
29
+ ### Fixed
30
+ - When deployment fails due to cleanup task failing.
31
+
32
+
24
33
  ## [v1.6.0] - 2022-06-18
25
34
  ### Added
26
35
  - Ability to copy over multiple themes and specify their name.
data/README.md CHANGED
@@ -14,6 +14,9 @@ gem "capistrano-sozo_magento2", "~> 1.6"
14
14
  bundle install
15
15
  ```
16
16
 
17
+ ## Updating
18
+ Update the gem to the latest version with `bundle update capistrano-sozo_magento2 --conservative`
19
+
17
20
  ## Usage
18
21
  Make sure the following lines are added to your project's `Capfile`:
19
22
  ```
@@ -4,6 +4,6 @@ module Capistrano
4
4
  module SozoMagento2
5
5
  # The plugin version number
6
6
  # @return [String] The gem version number
7
- VERSION = "1.6.0"
7
+ VERSION = "1.7.0"
8
8
  end
9
9
  end
@@ -34,7 +34,7 @@ namespace :deploy do
34
34
  directories_str = directories.map do |release|
35
35
  releases_path.join(release)
36
36
  end.join(" ")
37
- execute :sudo, 'rm', "-rf", directories_str
37
+ execute :sudo, 'rm', "-rf", directories_str, "||", "true"
38
38
  # TODO re-symlink the old directory
39
39
  else
40
40
  info t(:no_old_releases, host: host.to_s, keep_releases: keep)
@@ -15,11 +15,23 @@ namespace :sozo do
15
15
  desc "Git branch Check"
16
16
  task :check do
17
17
  on roles(:all) do
18
+ found = false
19
+ # Check if branch exists on remote
18
20
  check = capture(:git, 'ls-remote', '--heads', fetch(:repo_url), fetch(:branch), '|', 'wc', '-l')
19
21
 
20
22
  if check.to_i == 1
21
23
  info "Branch is available for deployment."
22
- else
24
+ found = true
25
+ else
26
+ # Check if a tag exists on remote
27
+ check = capture(:git, 'ls-remote', '--tags', fetch(:repo_url), fetch(:branch), '|', 'wc', '-l')
28
+ if check.to_i == 1
29
+ info "Tag is available for deployment."
30
+ found = true
31
+ end
32
+ end
33
+
34
+ if found == false
23
35
  error "Branch does not exist in git repository, have you pushed your changes?"
24
36
  exit 1
25
37
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: capistrano-sozo_magento2
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.0
4
+ version: 1.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Clive Walkden
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-06-18 00:00:00.000000000 Z
11
+ date: 2022-09-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: capistrano