dumpcar 0.1.1 → 0.1.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 52511a48a41c491763ac701489b0bfe9af0d9e1d43df0664ef65164264547bf0
4
- data.tar.gz: 5dc6dd24b730d027ca9efcd5c1432acdb714874f41fc69b9cf6d98c9b6b82f59
3
+ metadata.gz: b08e3ae8d2d7e0e92ac0031399b0d8b8cade5041febce05c95d11bad2e6dd5bf
4
+ data.tar.gz: 40620d3d09bb284ea73f5dd76d67caa64dc10a1e4ff2015fecb2e9d7ae6e1d28
5
5
  SHA512:
6
- metadata.gz: 492cb8db640c682bb3547c21f4bf8768282c0658b4b436d676d41236c143d36e4cf90c33e9b88e6628d3eb7d967ffb1b011816590c9410ca1f9c85e9eff2993a
7
- data.tar.gz: 4bbb7c5f1aebab2674fc4cb06436c5f31d9641bed2f0110fad4c486906ea0ea66e32f3979ceb47ff1b331ba5fcf287722b73846f457e944704fd51bf56bc2a41
6
+ metadata.gz: df6accb1edcb0216ef5db0997b561fbae926b3fd38d82148e9b87e59cee96bcdf1b4707ee6d70ab744615b1525cfd6ea904fb42144f9acca3aa2c2db7ca5f99f
7
+ data.tar.gz: 5ee0c794ba6a1c3d7c8de55726c811d753359a40d822f8646f09c63ee8f7f3218a3ea48d8485f1f4b95b8b4e966cd1311389daea8b1dcb73f433cf33977a973d
data/README.md CHANGED
@@ -10,7 +10,7 @@ Rake tasks for dumping and restoring the contents of the PostgreSQL database for
10
10
  Install the gem executing:
11
11
 
12
12
  ```bash
13
- bundle add Dumpcar
13
+ bundle add dumpcar
14
14
  rails g dumpcar # creates db/dumps folder, adds it to .gitignore and commits
15
15
  ```
16
16
 
@@ -57,3 +57,4 @@ Everyone interacting in the Dumpcar project's codebases, issue trackers, chat ro
57
57
 
58
58
  1. Update the version in the `lib/dumpcar/version.rb`
59
59
  2. Run the Push Gem workflow
60
+ 3. Create a new release from the UI for the new tag
@@ -1,9 +1,5 @@
1
1
  module Dumpcar
2
2
  class Railtie < Rails::Railtie
3
- rake_tasks do
4
- load "dumpcar/tasks/dump.rake"
5
- end
6
-
7
3
  generators do
8
4
  load "dumpcar/generators/dumpcar_generator.rb"
9
5
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Dumpcar
4
- VERSION = "0.1.1"
4
+ VERSION = "0.1.1.2"
5
5
  end
@@ -0,0 +1,15 @@
1
+ class DumpcarCommand < Rails::Command::Base
2
+ class_option :base, type: :string, desc: "the location of your DB dumps, defaults to Rails.root.join('db/dumps')"
3
+
4
+ desc "dump", "Dump postgres backup file"
5
+ def dump
6
+ require "dumpcar"
7
+ Dumpcar::Instance.new.dump
8
+ end
9
+
10
+ desc "restore", "Restore postgres backup file"
11
+ def restore
12
+ require "dumpcar"
13
+ Dumpcar::Instance.new.restore
14
+ end
15
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dumpcar
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eric Schultz
@@ -61,8 +61,8 @@ files:
61
61
  - lib/dumpcar/location.rb
62
62
  - lib/dumpcar/pg.rb
63
63
  - lib/dumpcar/railtie.rb
64
- - lib/dumpcar/tasks/dump.rake
65
64
  - lib/dumpcar/version.rb
65
+ - lib/rails/commands/dumpcar_command.rb
66
66
  - package-lock.json
67
67
  - package.json
68
68
  homepage: https://github.com/wwahammy/dumpcar
@@ -87,5 +87,5 @@ required_rubygems_version: !ruby/object:Gem::Requirement
87
87
  requirements: []
88
88
  rubygems_version: 3.6.7
89
89
  specification_version: 4
90
- summary: Rake tasks for dumping and restoring Rails PostgreSQL database contents
90
+ summary: Commands for dumping and restoring Rails PostgreSQL database contents
91
91
  test_files: []
@@ -1,17 +0,0 @@
1
- namespace :dumpcar do
2
- namespace :pg do
3
- desc "Dumped postgres backup file"
4
- task dump: :environment do
5
- Dumpcar.dump
6
- end
7
-
8
- desc "Load dumped postgres backup file"
9
- task restore: :environment do
10
- Dumpcar.restore
11
- end
12
-
13
- def say(something)
14
- puts(something)
15
- end
16
- end
17
- end