capistrano-cul 0.0.14 → 0.0.15
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/lib/capistrano/tasks/wp/migrate.cap +10 -9
- data/lib/capistrano/tasks/wp.cap +3 -3
- 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: 2d08bd99ee59976271ab8640c51fd056aa82b7f1
|
4
|
+
data.tar.gz: 699fffbfb4d982bbebe1e5d9e9956aefd8b66c52
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1c6fde504264cd5bd7baf29f54f895db501b609f97759b21403076e961147e8aa99c2f9745fe0c1cb3b563cc22c57ccc5bc37a06ea961b49c44d89393d92dc7d
|
7
|
+
data.tar.gz: 7d0fb86de4e4326477994e15b24e5144d6a725240e7b65dc5f25164d0ee0d181db553b3c4bf187632d64ceac8cd7c081b90a7eff6729d814d752266fa2f141ed
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.15
|
@@ -13,19 +13,17 @@ namespace :cul do
|
|
13
13
|
require_cap_params!([:wp_docroot, :wp_content_path])
|
14
14
|
|
15
15
|
if fetch(:multisite, false)
|
16
|
-
puts "Since this is a multisite, you'll need to specify the source instance
|
17
|
-
set :source_site_multisite_url, ask('source multisite
|
16
|
+
puts "Since this is a multisite, you'll need to specify the source multisite instance domain to continue:"
|
17
|
+
set :source_site_multisite_url, ask('source multisite instance domain (e.g. blogs.cul.columbia.edu)')
|
18
18
|
fetch(:source_site_multisite_url)
|
19
19
|
|
20
|
-
puts "And you'll also need to specify the destination instance
|
21
|
-
set :destination_site_multisite_url, ask('destination multisite
|
20
|
+
puts "And you'll also need to specify the destination multisite instance domain to continue:"
|
21
|
+
set :destination_site_multisite_url, ask('destination multisite instance domain (e.g. blogs-dev.cul.columbia.edu)')
|
22
22
|
fetch(:destination_site_multisite_url)
|
23
23
|
end
|
24
24
|
|
25
|
-
# TODO:
|
25
|
+
# TODO: Would be nice to verify that destination wordpress has already had the setup and deploy tasks run for it
|
26
26
|
set :src_wp_docroot, ask("server path to source WordPress installation (to copy from)")
|
27
|
-
#set :src_wp_docroot, '/cul/cul0/lito/vmounts/haydn/var-www/kennedyprize/html'
|
28
|
-
#set :src_wp_docroot, '/cul/cul0/ldpd/culblogs/prod/ssl-html'
|
29
27
|
|
30
28
|
# Confirm operation because it is destructive
|
31
29
|
puts "\nWARNING: This operation will obliterate all content in environment [#{fetch(:stage)}] and replace it with content from [#{fetch(:src_wp_docroot)}]."
|
@@ -69,14 +67,14 @@ namespace :cul do
|
|
69
67
|
# EXCLUDE plugins, themes, mu-plugins, uploads, and blogs.dir
|
70
68
|
"-not \\( -path './plugins/*' -o -path './mu-plugins/*' -o -path './themes/*' -o -path './uploads/*' -o -path './blogs.dir/*' \\) " +
|
71
69
|
# EXCLUDE certain unwanted files and paths
|
72
|
-
"-a -not \\( -name '.nfs*' \\) " +
|
70
|
+
"-a -not \\( -name '.nfs*' -o -name 'config.tmp.*' \\) " +
|
73
71
|
"-a -not \\( -path '*/.git*' -o -path '*/.svn*' -o -path '*/.hg*' \\) "
|
74
72
|
|
75
73
|
find_upload_dirs = '. -type f ' +
|
76
74
|
# INCLUDE ONLY uploads and blogs.dir
|
77
75
|
"\\( -path './uploads/*' -o -path './blogs.dir/*' \\) " +
|
78
76
|
# EXCLUDE certain unwanted files and paths
|
79
|
-
"-a -not \\( -name '.nfs*' \\) " +
|
77
|
+
"-a -not \\( -name '.nfs*' -o -name 'config.tmp.*' \\) " +
|
80
78
|
"-a -not \\( -path '*/.git*' -o -path '*/.svn*' -o -path '*/.hg*' \\) " +
|
81
79
|
# INCLUDE ONLY certain file extensions
|
82
80
|
"-a \\( " + JSON.parse(capture(:wp, (fetch(:multisite, false) ? "--url=#{fetch(:source_site_multisite_url)}" : ''), 'eval', '"echo cul_allowed_upload_file_extensions_as_json();"')).map{ |allowed_file_extension|
|
@@ -128,6 +126,9 @@ namespace :cul do
|
|
128
126
|
|
129
127
|
execute :rsync, *rsync_params
|
130
128
|
|
129
|
+
# clean up path_to_list_of_files_to_copy file
|
130
|
+
execute :rm, path_to_list_of_files_to_copy
|
131
|
+
|
131
132
|
# Next, create symlinks to repo-managed plugins and themes, which will also recreate plugins, mu-plugins, and themes directories
|
132
133
|
|
133
134
|
within fetch(:wp_docroot) do
|
data/lib/capistrano/tasks/wp.cap
CHANGED
@@ -2,7 +2,7 @@ CUL_ALLOWED_UPLOAD_TYPES_PLUGIN_NAME = 'cul-allowed-upload-types'
|
|
2
2
|
CUL_ALLOWED_UPLOAD_TYPES_REPO_URL = "https://github.com/cul/#{CUL_ALLOWED_UPLOAD_TYPES_PLUGIN_NAME}"
|
3
3
|
|
4
4
|
# Set cul_allowed_uplaod_types_version here so it can be overridden by env config
|
5
|
-
set :cul_allowed_uplaod_types_version, 'v0.
|
5
|
+
set :cul_allowed_uplaod_types_version, 'v0.5.0'
|
6
6
|
|
7
7
|
namespace :cul do
|
8
8
|
namespace :wp do
|
@@ -244,8 +244,8 @@ namespace :cul do
|
|
244
244
|
start_time = Time.now
|
245
245
|
|
246
246
|
if fetch(:multisite, false)
|
247
|
-
puts "Since this is a multisite, you'll need to specify the source multisite
|
248
|
-
set :multisite_url, ask('
|
247
|
+
puts "Since this is a multisite, you'll need to specify the source multisite instance domain to continue:"
|
248
|
+
set :multisite_url, ask('source multisite instance domain (e.g. blogs.cul.columbia.edu)')
|
249
249
|
|
250
250
|
execute :wp, "--url=#{fetch(:multisite_url)}", 'search-replace', "'#{fetch(:search_string)}'", "'#{fetch(:replacement_string)}'", '--all-tables', '--skip-columns=guid'
|
251
251
|
else
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: capistrano-cul
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.15
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Carla Galarza
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2018-02-
|
12
|
+
date: 2018-02-13 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: capistrano
|