alcapon 0.4.18 → 0.4.19

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE.md +1 -1
  3. data/lib/db.rb +13 -2
  4. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8ad2a04b0b969ddcdd084c811fca9eded8b1c501
4
- data.tar.gz: c657ccd1631591f313ecfc06940ca6297cad240e
3
+ metadata.gz: 94e5f99bef83e6ef54ef050419597162c5f9555c
4
+ data.tar.gz: 3f0ea644669fc958eebe15a10f811e2d24b07d67
5
5
  SHA512:
6
- metadata.gz: e0c27c326b6358b238912fab48f0555d9c8899ff7176c8c37252239172472ca48de9d78746a6db000c960468634f783f41a8f52148242ec7333155991b734744
7
- data.tar.gz: e12957da18393dac9dbc6ba3d6e089ce0755b410195a1d989ed09c4c1868ac9127db060e4d90e36e2c5034dc03125adfb14f1e49fbe4d4716e63f4e4c60493fa
6
+ metadata.gz: 333abecc7a62b411da1f24e462121420b3fa6426dcd439aaab253566bf0105fae2bf83dd41a9009f259c288f59fac8c8980f451c0eba0f7d4630142fbad7a461
7
+ data.tar.gz: 60d1eb64ee2aa6dc0f5a4a5ffe4c35d3c2239d4aeb768fe83f497cc3f722df0f483adf929f470828a0bdbaf2f7dae295f70c0df5e6b9c18ffdf1234152772248
data/LICENSE.md CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2013 Arnaud Lafon, http://github.com/alafon
1
+ Copyright (c) 2014 Arnaud Lafon, https://github.com/alafon
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4
4
 
data/lib/db.rb CHANGED
@@ -17,14 +17,25 @@ namespace :db do
17
17
  files[i] = value
18
18
  i += 1
19
19
  }
20
+
20
21
  file_to_import = Capistrano::CLI.ui.ask "Which one ?"
21
- dbpasswd = fetch( :database_local_passd, "#{database_passd}" )
22
22
  if files.has_key?( file_to_import.to_i )
23
23
  filename = File.join( backup_dir, files[file_to_import.to_i] )
24
- system( "gunzip < #{filename} | mysql -u#{database_uname} -p#{dbpasswd} #{database_name} ")
25
24
  else
26
25
  abort "Bad index"
27
26
  end
27
+
28
+ if fetch( :ezdfs_database_name, nil ) != nil && filename =~ /#{ezdfs_database_name}/i
29
+ thisdbname = fetch( :ezdfs_database_name )
30
+ thisdbuser = fetch( :ezdfs_database_uname )
31
+ thisdbpass = fetch( :ezdfs_database_passd )
32
+ else
33
+ thisdbname = database_name
34
+ thisdbuser = database_uname
35
+ thisdbpass = database_passd
36
+ end
37
+ thisdbpass = fetch( :database_local_passd, "#{database_passd}" )
38
+ system( "gunzip < #{filename} | mysql -u#{thisdbuser} -p#{thisdbpass} #{thisdbname} ")
28
39
  end
29
40
 
30
41
  # Should use :db as :roles
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: alcapon
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.18
4
+ version: 0.4.19
5
5
  platform: ruby
6
6
  authors:
7
7
  - Arnaud Lafon
@@ -41,7 +41,7 @@ dependencies:
41
41
  description: Capistrano is a utility and framework for executing commands in parallel
42
42
  on multiple remote machines, via SSH. This package gives you some tools to deploy
43
43
  your eZ Publish projects.
44
- email: alcapon@arnaudlafon.com
44
+ email: alcapon@phasetwo.fr
45
45
  executables:
46
46
  - capezit
47
47
  extensions: []