wp-capistrano3 0.0.39 → 0.0.40
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/capistrano/tasks/install_plugins.rake +12 -12
- data/wp-capistrano.gemspec +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a2f8651568b1a42cc326132d7194a7a0d1941d475e53f10f61f0d1df05432020
|
4
|
+
data.tar.gz: df4a43097b3203502f49e67fd60d6c95a18655cb688d39152c88689216ad2b77
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4ce3568ac3d7c025e8d4cde42bd63f938b0e40eba12b6a6da86c75771c77afb200f5362ad50eb99bfa997352d0666bf7dd9588234bfd94333f2b261153e80397
|
7
|
+
data.tar.gz: 91e145cd081b313d3dc142cdfa19d02b119cc03bd362985a8116895242da97c7b941f85e5eade481f5a8f2efc88e6b6a36763a21d7bb8479eb725357ab8bb398
|
@@ -13,11 +13,11 @@ namespace "wp-capistrano" do
|
|
13
13
|
|
14
14
|
if(test("[ -L #{current_path} ]"))
|
15
15
|
info "installing pluggins..."
|
16
|
-
installedPlugins = capture("
|
16
|
+
installedPlugins = capture("php #{fetch(:tmp_dir)}/wp-cli.phar plugin list --path=#{current_path} |awk '{ print $1 }'")
|
17
17
|
installedPluginsArr = installedPlugins.to_s.gsub(/\n/, '|').split("|")
|
18
|
-
installedPluginsStatus = capture("
|
18
|
+
installedPluginsStatus = capture("php #{fetch(:tmp_dir)}/wp-cli.phar plugin list --path=#{current_path} |awk '{ print $2 }'")
|
19
19
|
installedPluginsStatusArr = installedPluginsStatus.to_s.gsub(/\n/, '|').split("|")
|
20
|
-
installedPluginsVersion = capture("
|
20
|
+
installedPluginsVersion = capture("php #{fetch(:tmp_dir)}/wp-cli.phar plugin list --path=#{current_path} |awk '{ print $4 }'")
|
21
21
|
installedPluginsVersionArr = installedPluginsVersion.to_s.gsub(/\n/, '|').split("|")
|
22
22
|
|
23
23
|
plugins = []
|
@@ -45,8 +45,8 @@ namespace "wp-capistrano" do
|
|
45
45
|
|
46
46
|
if( !jsonPlugins["languages"].nil? )
|
47
47
|
jsonPlugins["languages"].each do |language|
|
48
|
-
execute "
|
49
|
-
execute "
|
48
|
+
execute "php #{fetch(:tmp_dir)}/wp-cli.phar language core install #{language} --path=#{release_path}"
|
49
|
+
execute "php #{fetch(:tmp_dir)}/wp-cli.phar language core activate #{language} --path=#{release_path}"
|
50
50
|
end
|
51
51
|
end
|
52
52
|
|
@@ -57,7 +57,7 @@ namespace "wp-capistrano" do
|
|
57
57
|
next
|
58
58
|
end
|
59
59
|
|
60
|
-
existingPlugins = capture("
|
60
|
+
existingPlugins = capture("php #{fetch(:tmp_dir)}/wp-cli.phar plugin search #{plugin[:slug]} --path=#{release_path} --field=slug --per-page=999999")
|
61
61
|
if (existingPlugins.to_s.gsub(/\n/, '|').split("|").include?("#{plugin[:slug]}") == false)
|
62
62
|
warn "Pluggin #{plugin[:slug]} not known in wordpress repository. skip installation"
|
63
63
|
next
|
@@ -65,10 +65,10 @@ namespace "wp-capistrano" do
|
|
65
65
|
|
66
66
|
info "install #{plugin[:slug]}:#{plugin[:version]}"
|
67
67
|
if(plugin[:version]) == "latest"
|
68
|
-
execute "
|
68
|
+
execute "php #{fetch(:tmp_dir)}/wp-cli.phar plugin install #{plugin[:slug]} --path=#{release_path} --force"
|
69
69
|
info "install #{plugin[:slug]}"
|
70
70
|
else
|
71
|
-
execute "
|
71
|
+
execute "php #{fetch(:tmp_dir)}/wp-cli.phar plugin install #{plugin[:slug]} --path=#{release_path} --version=#{plugin[:version]} --force"
|
72
72
|
info "install #{plugin[:slug]} #{plugin[:version]}"
|
73
73
|
end
|
74
74
|
end
|
@@ -78,19 +78,19 @@ namespace "wp-capistrano" do
|
|
78
78
|
next
|
79
79
|
end
|
80
80
|
if (plugin[:status] == "active")
|
81
|
-
execute "
|
81
|
+
execute "php #{fetch(:tmp_dir)}/wp-cli.phar plugin activate #{plugin[:slug]} --path=#{release_path}"
|
82
82
|
info "activate #{plugin[:slug]}"
|
83
83
|
elsif(plugin[:status] == "active-network")
|
84
|
-
execute "
|
84
|
+
execute "php #{fetch(:tmp_dir)}/wp-cli.phar plugin activate #{plugin[:slug]} --path=#{release_path} --network"
|
85
85
|
elsif(plugin[:status] == "inactive")
|
86
|
-
execute "
|
86
|
+
execute "php #{fetch(:tmp_dir)}/wp-cli.phar plugin deactivate #{plugin[:slug]} --path=#{release_path}"
|
87
87
|
info "deactivate #{plugin[:slug]}"
|
88
88
|
end
|
89
89
|
end
|
90
90
|
|
91
91
|
if( !jsonPlugins["languages"].nil? )
|
92
92
|
jsonPlugins["languages"].each do |language|
|
93
|
-
execute "
|
93
|
+
execute "php #{fetch(:tmp_dir)}/wp-cli.phar language plugin install --all #{language} --path=#{release_path}"
|
94
94
|
end
|
95
95
|
end
|
96
96
|
end
|
data/wp-capistrano.gemspec
CHANGED
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
4
|
|
5
5
|
Gem::Specification.new do |spec|
|
6
6
|
spec.name = 'wp-capistrano3'
|
7
|
-
spec.version = '0.0.
|
7
|
+
spec.version = '0.0.40'
|
8
8
|
spec.authors = ['Nicolas RENAULT']
|
9
9
|
spec.email = ['nrenault@tangkoko.com']
|
10
10
|
spec.description = %q{Wordpress tasks for Capistrano 3.x}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: wp-capistrano3
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.40
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nicolas RENAULT
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-03-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: capistrano
|