morpheus-heroku 0.4.0 → 0.4.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 +4 -4
- data/CHANGELOG.md +7 -1
- data/README.md +10 -0
- data/lib/morpheus-heroku/fetch.rb +6 -6
- data/lib/morpheus-heroku/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6891013fb3cbe344ac476e8ac9aadfe1f58553a8b3a64aecb3d4671721bb5cdf
|
4
|
+
data.tar.gz: 0b1d924179c6a2d508c6f94ee379e6433b6ce117f8dd0292de377a12c7069fae
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cb96d19a28732f3e8a717bf8de6e397045b64aa4d7ad8c2fd239ca31c0cffe79301d9f8932b9641e34bdf91a1d205c054e23960eae65a0f7338fa21f040ca6b8
|
7
|
+
data.tar.gz: f484c9742f429cec68083d522cdfa4e4b37ef3db4e665dd042e00fa17fbe8b294718f7fa88c59b75f747522953f643ca9324473e4646077a371e23f430d320c0
|
data/CHANGELOG.md
CHANGED
@@ -1,10 +1,16 @@
|
|
1
1
|
# Change Log
|
2
2
|
|
3
|
+
## 0.4.1
|
4
|
+
|
5
|
+
_Fixes_
|
6
|
+
|
7
|
+
- Use the app name when generating the download url for the backup
|
8
|
+
|
3
9
|
## 0.4.0
|
4
10
|
|
5
11
|
- Email Scrambler
|
6
12
|
|
7
|
-
|
13
|
+
_Fixes_
|
8
14
|
|
9
15
|
- Fix `Failed to create the file tmp/latest.dump` [@rcsm, #1]
|
10
16
|
- Perform a git fetch before trying to update the remote
|
data/README.md
CHANGED
@@ -59,3 +59,13 @@ If you see `ActiveRecord::ProtectedEnvironmentError: You are attempting to run a
|
|
59
59
|
even when running in development, then you need to do this:
|
60
60
|
|
61
61
|
`bin/rails db:environment:set RAILS_ENV=development`
|
62
|
+
|
63
|
+
## Development
|
64
|
+
|
65
|
+
```
|
66
|
+
$ gem bump
|
67
|
+
|
68
|
+
$ gem release
|
69
|
+
|
70
|
+
$ gem tag
|
71
|
+
```
|
@@ -2,6 +2,8 @@ module MorpheusHeroku
|
|
2
2
|
module Fetch
|
3
3
|
extend self
|
4
4
|
|
5
|
+
delegate :backup_location, :app_name, to: 'MorpheusHeroku.configuration'
|
6
|
+
|
5
7
|
def run
|
6
8
|
generate_backup!
|
7
9
|
download_backup!
|
@@ -15,16 +17,14 @@ module MorpheusHeroku
|
|
15
17
|
|
16
18
|
def download_backup!
|
17
19
|
prepare_location
|
18
|
-
Helper.bash_run(command: "curl -o #{
|
20
|
+
Helper.bash_run(command: "curl -o #{backup_location} `heroku pg:backups public-url -a #{app_name}`")
|
19
21
|
end
|
20
22
|
|
21
23
|
def prepare_location
|
22
|
-
|
23
|
-
|
24
|
-
return if File.writable?(location)
|
24
|
+
return if File.writable?(backup_location)
|
25
25
|
|
26
|
-
create_dir(
|
27
|
-
create_file(
|
26
|
+
create_dir(backup_location[/^.+(?=\/)/])
|
27
|
+
create_file(backup_location[/(?<=\/).+$/])
|
28
28
|
end
|
29
29
|
|
30
30
|
def create_dir(dir_name)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: morpheus-heroku
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Catalin Ionescu
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-10-
|
11
|
+
date: 2019-10-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|