cryptum 0.0.414 → 0.0.415
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/cryptum/log.rb +7 -2
- data/lib/cryptum/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2887eb2e6b6a4935edfb71aabd839d0cbc633f75ab6d0c7fac30187149e9d0dd
|
4
|
+
data.tar.gz: 88002f644e4d7b9839818c1df8487e14b004ebb46cb2f782c41272c8130a129d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 81a1f5db054fcc8f599d59bf03f69627980f669f52af18343d7254b7b8b356a9ae6489df8f029bcba2a922082927fdb726eee19089df276ce81a99cddeb6bfc8
|
7
|
+
data.tar.gz: 1c94d64e561029e53e2a912e2befd9a8736a858a73ec45db77394b8daf359c3a1446a556ba7490572835e514d74c9355dcb25495e3f75089b47e2b30debef863
|
data/lib/cryptum/log.rb
CHANGED
@@ -12,6 +12,8 @@ module Cryptum
|
|
12
12
|
which_self = opts[:which_self].to_s
|
13
13
|
event_history = opts[:event_history]
|
14
14
|
|
15
|
+
driver_name = File.basename($PROGRAM_NAME)
|
16
|
+
|
15
17
|
# Only attempt to exit gracefully if level == :error
|
16
18
|
exit_gracefully = false
|
17
19
|
|
@@ -43,14 +45,17 @@ module Cryptum
|
|
43
45
|
when :error
|
44
46
|
exit_gracefully = true
|
45
47
|
logger.level = Logger::ERROR
|
46
|
-
puts "\nERROR: See #{log_file_path} for more details."
|
48
|
+
puts "\nERROR: See #{log_file_path} for more details." if driver_name == 'cryptum-repl'
|
47
49
|
when :fatal
|
48
50
|
# This is reserved for the Cryptum::UI::Exit module
|
49
51
|
# if the Interrupt or StandardError exceptions are
|
50
52
|
# triggered. This prevents infintely attempting to
|
51
53
|
# exit if something in the module fails.
|
52
54
|
logger.level = Logger::FATAL
|
53
|
-
|
55
|
+
if driver_name == 'cryptum-repl'
|
56
|
+
puts "\nFATAL ERROR: Event history cannot be saved."
|
57
|
+
puts "See #{log_file_path} for more details."
|
58
|
+
end
|
54
59
|
when :info, :learning
|
55
60
|
logger.level = Logger::INFO
|
56
61
|
when :unknown
|
data/lib/cryptum/version.rb
CHANGED