capistrano-craft 0.1.1 → 0.1.2

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: ccc517736e79408a6302f9d48c3d9fdf9add3283
4
- data.tar.gz: ceeb2af2e5057d14dcfb24e781bd12d122c939e9
3
+ metadata.gz: 0307770f776f3de8aa29e6903060ef0549e7bf81
4
+ data.tar.gz: f4d15ac89b13f88992b32e9b0c67d4cf0262695e
5
5
  SHA512:
6
- metadata.gz: 1d441c129fe7c1dee24322f82bf01bc84ebd9b6b4ba481afd065d0041b941a0969de5452c17523bdff0fc7347b8c013a838e6edd2cdb5c8db3738ae9f7c06bd0
7
- data.tar.gz: ef9a333c743f98f358f317a7f2eff081bceb246407d378b841f5cef2a6568bc359eb5752e21b36881ecd25be67adab5c56644225b00bb29b7a1ac475c9e2f6fd
6
+ metadata.gz: 5d30b65c31c6f3cabaac3711ed517b7986d4cd75db98320aee342f35670297bbdc96b327ae96f3b7587d8878e55d43950291f57ce89e7773fe4d0d23bd800ebf
7
+ data.tar.gz: 2d0c5092c8f1cc8c500e34d937cbc0499885303c3549c19100f284c65cd65efd1d1716acc72dc3e27ec59816bc46e859322e59a6ab2b05b930f05f36c8adee81
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- capistrano-craft (0.1.1)
4
+ capistrano-craft (0.1.2)
5
5
  capistrano (~> 3.1)
6
6
  capistrano-composer (~> 0.0.6)
7
7
 
@@ -1,5 +1,5 @@
1
1
  module Capistrano
2
2
  module Craft
3
- VERSION = "0.1.1"
3
+ VERSION = "0.1.2"
4
4
  end
5
5
  end
@@ -79,7 +79,7 @@ module Capistrano
79
79
  when "pgsql" then return :pgsql
80
80
  when "mysql" then return :mysql
81
81
  else
82
- raise "Unable to determine remote server database driver"
82
+ raise "Unable to determine database driver: \"#{driver.strip}\""
83
83
  end
84
84
  end
85
85
 
@@ -17,7 +17,8 @@ namespace :craft do
17
17
  end
18
18
 
19
19
  namespace :cache do
20
- task :clear do
20
+ desc "Run the cache/flush Craft command"
21
+ task :flush do
21
22
  on release_roles(fetch(:craft_deploy_roles)) do
22
23
  craft_console "cache/flush"
23
24
  end
@@ -29,9 +30,8 @@ namespace :craft do
29
30
  task :sync do
30
31
  run_locally do
31
32
  release_roles(fetch(:craft_deploy_roles)).each do |role|
32
- puts "User -> " + role.user
33
- execute :rsync, "-rvzO #{role.user}@#{role.hostname}:#{shared_path}/#{fetch(:assets_path)}/ #{fetch(:assets_path)}"
34
- execute :rsync, "-rvzO #{fetch(:assets_path)}/ #{role.user}@#{role.hostname}:#{shared_path}/#{fetch(:assets_path)}"
33
+ execute :rsync, "-rzO #{role.user}@#{role.hostname}:#{shared_path}/#{fetch(:assets_path)}/ #{fetch(:assets_path)}"
34
+ execute :rsync, "-rzO #{fetch(:assets_path)}/ #{role.user}@#{role.hostname}:#{shared_path}/#{fetch(:assets_path)}"
35
35
  end
36
36
  end
37
37
  end
@@ -40,12 +40,13 @@ namespace :craft do
40
40
  desc "Pull database and sync assets"
41
41
  task :pull do
42
42
  invoke "db:pull"
43
- invoke "craft:sync_assets"
43
+ invoke "craft:assets:sync"
44
44
  end
45
45
 
46
46
  desc "Push database and sync assets"
47
47
  task :push do
48
48
  invoke "db:push"
49
- invoke "craft:sync_assets"
50
- end
49
+ invoke "craft:assets:sync"
50
+ end
51
+
51
52
  end
@@ -1,13 +1,13 @@
1
1
  namespace :db do
2
2
  namespace :local do
3
- desc "Export the local database to craft_local_db_dump (db.sql)"
3
+ desc "Export the local database (to db.sql by default)"
4
4
  task :backup do
5
5
  run_locally do
6
6
  database_dump(fetch(:craft_local_env), fetch(:craft_local_db_dump))
7
7
  end
8
8
  end
9
9
 
10
- desc "Import into the local database from craft_local_db_dump (db.sql)"
10
+ desc "Import into the local database (from db.sql by default)"
11
11
  task :import do
12
12
  run_locally do
13
13
  database_restore(fetch(:craft_local_env), fetch(:craft_local_db_dump))
@@ -35,7 +35,7 @@ namespace :db do
35
35
  task :pull do
36
36
  invoke 'db:backup'
37
37
 
38
- on release_roles(fetch(:craft_deploy_roles)) do
38
+ run_locally do
39
39
  database_restore(fetch(:craft_local_env), fetch(:backup_filename))
40
40
  end
41
41
  end
@@ -14,4 +14,5 @@ namespace :deploy do
14
14
  end
15
15
 
16
16
  after 'deploy:updated', 'deploy:compile_assets'
17
+ after 'deploy:finished', 'craft:cache:flush'
17
18
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: capistrano-craft
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chris Dyer
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-10-15 00:00:00.000000000 Z
11
+ date: 2019-10-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: capistrano