marco-polo 2.0.1 → 2.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG +1 -0
- data/lib/marco-polo/version.rb +1 -1
- data/lib/marco-polo.rb +19 -12
- data/marco-polo.gemspec +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 40e1aeb5fb4fb3bed982c0455a648a35a93ca4d23542ee9c29137fdf2506b140
|
4
|
+
data.tar.gz: 0b9c13b733e0caba46a90c26a4bfb9c464d86be76a44f367eadbc67253a4cbd2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3d2ad85752b81e8d1d396433b2cb59d2637b922cb4e201ba532716238060a5d056d57a38c241ba024ab081cfc818f9aa0887aa8c1c410ac08d93ec06d9723247
|
7
|
+
data.tar.gz: c6d412493e3a1330ab87748879548aba22650ced8be2ad9c9411f6bde974c1b183f537cc27658f526ad6889f5d8375415c126e7819a87db8d2a8da74f0ec74ff
|
data/CHANGELOG
CHANGED
data/lib/marco-polo/version.rb
CHANGED
data/lib/marco-polo.rb
CHANGED
@@ -12,18 +12,25 @@ module MarcoPolo
|
|
12
12
|
end
|
13
13
|
|
14
14
|
if defined? Pry
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
rails_env = Rails.env.downcase
|
15
|
+
wait_proc = proc {
|
16
|
+
current_app = ENV["MARCO_POLO_APP_NAME"] || Rails.application.class.module_parent_name.underscore.gsub("_", "-")
|
17
|
+
rails_env = Rails.env.downcase
|
19
18
|
|
20
|
-
|
21
|
-
|
22
|
-
|
19
|
+
# shorten some common long environment names
|
20
|
+
rails_env = "dev" if rails_env == "development"
|
21
|
+
rails_env = "prod" if rails_env == "production"
|
23
22
|
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
]
|
28
|
-
end
|
23
|
+
"#{current_app}(#{rails_env})> "
|
24
|
+
}
|
25
|
+
incomplete_proc = proc { "> "}
|
29
26
|
|
27
|
+
if defined? Pry::Prompt
|
28
|
+
Pry.config.prompt = Pry::Prompt.new(
|
29
|
+
'marco-polo',
|
30
|
+
'A prompt which shows your app name and environment',
|
31
|
+
[wait_proc, incomplete_proc]
|
32
|
+
)
|
33
|
+
else
|
34
|
+
Pry.config.prompt = [wait_proc, incomplete_proc]
|
35
|
+
end
|
36
|
+
end
|
data/marco-polo.gemspec
CHANGED
@@ -4,7 +4,7 @@ Gem::Specification.new do |gem|
|
|
4
4
|
gem.name = "marco-polo"
|
5
5
|
|
6
6
|
gem.authors = ["Chris Doyle"]
|
7
|
-
gem.email = ["
|
7
|
+
gem.email = ["chris@arches.io"]
|
8
8
|
|
9
9
|
gem.description = "MarcoPolo shows your app name and environment in your console prompt so you don't accidentally break production"
|
10
10
|
gem.summary = "MarcoPolo shows your app name and environment in your console prompt"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: marco-polo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chris Doyle
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-02-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: railties
|
@@ -27,7 +27,7 @@ dependencies:
|
|
27
27
|
description: MarcoPolo shows your app name and environment in your console prompt
|
28
28
|
so you don't accidentally break production
|
29
29
|
email:
|
30
|
-
-
|
30
|
+
- chris@arches.io
|
31
31
|
executables: []
|
32
32
|
extensions: []
|
33
33
|
extra_rdoc_files: []
|
@@ -57,7 +57,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
57
57
|
- !ruby/object:Gem::Version
|
58
58
|
version: '0'
|
59
59
|
requirements: []
|
60
|
-
rubygems_version: 3.0.3
|
60
|
+
rubygems_version: 3.0.3.1
|
61
61
|
signing_key:
|
62
62
|
specification_version: 4
|
63
63
|
summary: MarcoPolo shows your app name and environment in your console prompt
|