wp-capistrano3 0.0.15 → 0.0.16

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: eda551519bb55fe762827c03a3b724470a95fe32d35cb1c3c9aed6a3de63d5c1
4
- data.tar.gz: f7fd4c055aa3b7aebd5f4da38ef79f14c9249220223c164723dcb7b5ca763343
3
+ metadata.gz: ff2c58a3b43c9cd1edeaab949816dfdf6013f3697db5a8a1d63d5ddbd0366efc
4
+ data.tar.gz: a57872fe96afbd6aa45610a3a7aa76f2519fcb6394bc087ca0c6a2e7aaab9e46
5
5
  SHA512:
6
- metadata.gz: f888079e2a20b99e261822a3b314de71efce04696404c10e5e755e45e95aeb499d481df93121088d2151563bed10252a1eecd84d59e723eba1780a4b0b81dbe0
7
- data.tar.gz: dd23b43892bb78ef4b548cd53022a5b29bfbe6d6fcbe0778b0b40f4fa88fdf723c975a4c1ef939b01bd670073de9c41a0179687324603a0acf2731c74fdf347b
6
+ metadata.gz: e7ce10075342bc37df272280adaeea1461db31ec8674867796d9666e73c7a870fc17633d6f5e0d71a92d67579b237ec91c6e88a80aac042df3dafee5efc114ff
7
+ data.tar.gz: cc7d54beeb8258d52b4ded60d45bbab569387635a9f1729aaeeac043448786747fd23913bc923bf0eb19bc5df5e4878fe9ac24e00362fb10e00c7b34449f0062
@@ -20,7 +20,8 @@ namespace "wp-capistrano" do
20
20
  installedPluginsVersion = capture("/usr/bin/env php /tmp/wp-cli.phar plugin list --path=#{current_path} |awk '{ print $4 }'")
21
21
  installedPluginsVersionArr = installedPluginsVersion.to_s.gsub(/\n/, '|').split("|")
22
22
 
23
- plugins = [];
23
+ plugins = []
24
+ languages = []
24
25
 
25
26
  installedPluginsArr.each_with_index do |plugin, index|
26
27
  if(index == 0)
@@ -29,17 +30,26 @@ namespace "wp-capistrano" do
29
30
  pluginInfo = {:slug => plugin, :version => installedPluginsVersionArr[index], :status => installedPluginsStatusArr[index] }
30
31
  plugins.push(pluginInfo)
31
32
  end
33
+ if( !jsonPlugins["plugins"].nil? )
34
+ jsonPlugins.each do |plugin, version|
35
+ plugginInfo = plugins.detect {|f| f["slug"] == plugin }
36
+ if(plugginInfo)
37
+ plugginInfo[:version] = version
38
+ plugginInfo[:status] = "active"
39
+ else
40
+ pluginInfo = {:slug => plugin, :version => version, :status => "active" }
41
+ plugins.push(pluginInfo)
42
+ end
43
+ end
44
+ end
45
+
46
+ if( !jsonPlugins["languages"].nil? )
47
+ jsonPlugins["languages"].each do |language|
48
+ execute "/usr/bin/env php /tmp/wp-cli.phar language core install #{language} --path=#{release_path}"
49
+ execute "/usr/bin/env php /tmp/wp-cli.phar language core activate #{language} --path=#{release_path}"
50
+ end
51
+ end
32
52
 
33
- jsonPlugins.each do |plugin, version|
34
- plugginInfo = plugins.detect {|f| f["slug"] == plugin }
35
- if(plugginInfo)
36
- plugginInfo[:version] = version
37
- plugginInfo[:status] = "active"
38
- else
39
- pluginInfo = {:slug => plugin, :version => version, :status => "active" }
40
- plugins.push(pluginInfo)
41
- end
42
- end
43
53
 
44
54
  plugins.each do |plugin|
45
55
  existingPlugins = capture("/usr/bin/env php /tmp/wp-cli.phar plugin search #{plugin[:slug]} --path=#{release_path} --field=slug --per-page=999999")
@@ -2,5 +2,5 @@
2
2
  before 'deploy:check:linked_files', 'wp-capistrano:create_wp_config'
3
3
  before 'deploy:updating', 'wp-capistrano:download_wordpress'
4
4
  after 'wp-capistrano:download_wordpress', 'wp-capistrano:install_wordpress'
5
- after 'wp-capistrano:install_wordpress', 'wp-capistrano:update_wordpress'
6
- after 'deploy:updating', 'wp-capistrano:install_plugins'
5
+ after 'wp-capistrano:install_plugins', 'wp-capistrano:update_wordpress'
6
+ after 'deploy:updating', 'wp-capistrano:install_plugins'
@@ -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.15'
7
+ spec.version = '0.0.16'
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.15
4
+ version: 0.0.16
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nicolas RENAULT
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-06-07 00:00:00.000000000 Z
11
+ date: 2021-11-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: capistrano