wordmove 4.0.1 → 4.0.2.pre1

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
  SHA1:
3
- metadata.gz: 514a3ea8b6b0be24cce32ed4daf1cc53b585bc74
4
- data.tar.gz: 592055eb9ae5933843d88bffc4637755b8844ca9
3
+ metadata.gz: 0df33b88f616681e8850b01577a4c24d75dbb20a
4
+ data.tar.gz: ad48c5b5c056f61c841039ae6bbd816208e98ade
5
5
  SHA512:
6
- metadata.gz: eb00f9fb8ad4ce0d761c0c7256db23d54b2bed92029fc3388f7912dc86e47ca4935e6be15204a4dc46a3f5b79ebf2a8b1528d060208f786468a5831010be2766
7
- data.tar.gz: 20ea63b6eb34253405aa8a3c094d213216ace5db6a286138942a1dea9c1be608939c01acaddda6d386559c6e256fc52725f3027c46fe463c53975c7744101919
6
+ metadata.gz: 156d8223f9e0bcf9ec92e2bc41c53888d2dc2acf2fc6b5cc0328411db648c40c3ba30c2af83c99322efe6d2fbfd4a35a9321e2b9b47cd1d564e6d6de19f7b23a
7
+ data.tar.gz: fd3080d465ca5cf59a951d9f5fafd998bc9f84a1a0733abc665ddd00b04426862a31292c8a313d8841e2bc6f7c3c0f0b0cca54d38ec27fac9b64fa3e6f6c19b2
data/README.mdown CHANGED
@@ -165,22 +165,20 @@ will push your local database to the staging environment only.
165
165
  We warmly **recommend** to read the wiki article: [Multiple environments explained
166
166
  ](https://github.com/welaika/wordmove/wiki/Multiple-environments-explained)
167
167
 
168
- ## Secrets
168
+ ## Environment Variables
169
169
 
170
- If you intend on committing movefiles to your repos, consider using ERB tags to hide sensitive variables and credentials:
170
+ Wordmove allows the use of environment variables in your movefiles.
171
+ This is useful in order to protect sensitive variables and credentials, as well as make it easy to share movefiles between your team.
171
172
 
172
- ```yaml
173
- production:
174
- database:
175
- user: "<%= ENV['PROD_DB_USER'] %>"
176
- password: "<%= ENV['PROD_DB_PASS'] %>"
173
+ Environment variables are written using the **ERB tags** syntax:
174
+ ```
175
+ "<%= ENV['YOUR_SECRET_NAME'] %>"
177
176
  ```
178
177
 
179
- This can either be specified through shell variables or a dotenv file.
180
-
181
- ### Shell
182
- You can set variables like so:
178
+ ### Variables set up
179
+ Environment variables can be set up using two methods:
183
180
 
181
+ #### Using the shell:
184
182
  ```bash
185
183
  # bash
186
184
  export PROD_DB_USER="username" PROD_DB_PASS="password"
@@ -188,17 +186,39 @@ export PROD_DB_USER="username" PROD_DB_PASS="password"
188
186
  # fish
189
187
  set --export --global PROD_DB_USER "username"; set --export --global PROD_DB_PASS "password"
190
188
  ```
189
+ #### Using a `.env` file:
191
190
 
192
- ### Dotenv
193
- Wordmove supports the [dotenv](https://github.com/bkeepers/dotenv) module. Simply create a file named `.env` next to your movefile:
191
+ Wordmove supports the [dotenv](https://github.com/bkeepers/dotenv) module.
194
192
 
195
- ```dosini
196
- PROD_DB_USER=username
197
- PROD_DB_PASS=password
193
+ Simply create a `.env` file next to your movefile structured as follows:
194
+ ```bash
195
+ PROD_DB_USER="username"
196
+ PROD_DB_PASS="password"
198
197
  ```
198
+ Wordmove will take care of loading the file and making the environment variables ready to be used in your configuration file.
199
199
 
200
200
  You may also use `.env.{environmentname}`, but this is discouraged.
201
201
 
202
+ ### Use them in your `movefile.yml`
203
+ Using the ERB syntax described above, write your movefile as follows:
204
+ ```yaml
205
+ production:
206
+ database:
207
+ user: "<%= ENV['PROD_DB_USER'] %>"
208
+ password: "<%= ENV['PROD_DB_PASS'] %>"
209
+ ```
210
+
211
+ ### System variables
212
+ You can use system variables to configure your movefile.
213
+
214
+ For example:
215
+ ```yaml
216
+ local:
217
+ vhost: "http://wordpress-site.localhost"
218
+ wordpress_path: "<%= ENV['HOME'] %>/[wordpress directory path]/"
219
+ # wordpress_path will be substituted with /home/user_name/[wordpress directory path]
220
+ ```
221
+
202
222
  ## Supports
203
223
 
204
224
  ### OS
@@ -301,3 +321,4 @@ FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
301
321
  COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
302
322
  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
303
323
  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
324
+
@@ -1,3 +1,3 @@
1
1
  module Wordmove
2
- VERSION = "4.0.1".freeze
2
+ VERSION = "4.0.2.pre1".freeze
3
3
  end
data/wordmove.gemspec CHANGED
@@ -33,7 +33,7 @@ Gem::Specification.new do |spec|
33
33
  spec.add_runtime_dependency "colorize", "~> 0.8.1"
34
34
  spec.add_runtime_dependency "dotenv", "~> 2.2.1"
35
35
  spec.add_runtime_dependency "kwalify", "~> 0"
36
- spec.add_runtime_dependency "photocopier", "~> 1.3", ">= 1.3.2"
36
+ spec.add_runtime_dependency "photocopier", "1.3.3.pre1"
37
37
  spec.add_runtime_dependency "thor", "~> 0.19.4"
38
38
 
39
39
  spec.required_ruby_version = ">= 2.4.0"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: wordmove
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.1
4
+ version: 4.0.2.pre1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stefano Verna
@@ -12,7 +12,7 @@ authors:
12
12
  autorequire:
13
13
  bindir: exe
14
14
  cert_chain: []
15
- date: 2019-04-12 00:00:00.000000000 Z
15
+ date: 2019-06-03 00:00:00.000000000 Z
16
16
  dependencies:
17
17
  - !ruby/object:Gem::Dependency
18
18
  name: activesupport
@@ -80,22 +80,16 @@ dependencies:
80
80
  name: photocopier
81
81
  requirement: !ruby/object:Gem::Requirement
82
82
  requirements:
83
- - - "~>"
84
- - !ruby/object:Gem::Version
85
- version: '1.3'
86
- - - ">="
83
+ - - '='
87
84
  - !ruby/object:Gem::Version
88
- version: 1.3.2
85
+ version: 1.3.3.pre1
89
86
  type: :runtime
90
87
  prerelease: false
91
88
  version_requirements: !ruby/object:Gem::Requirement
92
89
  requirements:
93
- - - "~>"
90
+ - - '='
94
91
  - !ruby/object:Gem::Version
95
- version: '1.3'
96
- - - ">="
97
- - !ruby/object:Gem::Version
98
- version: 1.3.2
92
+ version: 1.3.3.pre1
99
93
  - !ruby/object:Gem::Dependency
100
94
  name: thor
101
95
  requirement: !ruby/object:Gem::Requirement
@@ -308,9 +302,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
308
302
  version: 2.4.0
309
303
  required_rubygems_version: !ruby/object:Gem::Requirement
310
304
  requirements:
311
- - - ">="
305
+ - - ">"
312
306
  - !ruby/object:Gem::Version
313
- version: '0'
307
+ version: 1.3.1
314
308
  requirements: []
315
309
  rubyforge_project:
316
310
  rubygems_version: 2.6.11