console_detective 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
  SHA256:
3
- metadata.gz: ef9da06b2847ed04dd93462272f647bf51ce89af78693a975234f8cb3ae011d8
4
- data.tar.gz: ae806be239601ccc221519bb1b787d21341975736f739a0061296c437e130f57
3
+ metadata.gz: 65cab924b7bcb3734b9a2004ba28b51980127ce27a3175a40339bbba60875473
4
+ data.tar.gz: f3b5b0be89182c82dfb0ae524f903a9ca0c422d2d2cc7647a13d7ad07746ebac
5
5
  SHA512:
6
- metadata.gz: 7d63f6471350aa8b5d46bf53186eda1e98a5167c2f4772ba10f816a2ee1a90b182fd6632cea1bb77fb443f575bb6f43fbfdedacec76e58f6732a14f82777ebb9
7
- data.tar.gz: 2c317ba8cc2603119f26ba809036248d7bbfa5959f02b82fcc3c5af4263c66b06acce7045b364fe84c6e8f5efeff9777443bcd0017483bf08fd2dda2ebc9cf9f
6
+ metadata.gz: 5a755923262ecb3e384bd27226d624caa3b250c40b085b683f797a27da99748c7857c4353a66ee1bcfe1597c183f89c70e9648e4b83945c149c6a021557b46ff
7
+ data.tar.gz: 126678d567a689be4757fcb5ae19fff58699a7a6cacb1976f685dce25636f864527fd27683a0b0e6864b8b3fd2f28bac85e031ec12aaf6e3759d027fb750b222
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- console_detective (0.1.1)
4
+ console_detective (0.1.2)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -49,4 +49,4 @@ DEPENDENCIES
49
49
  simplecov-lcov
50
50
 
51
51
  BUNDLED WITH
52
- 2.1.4
52
+ 2.2.22
data/README.md CHANGED
@@ -2,12 +2,12 @@
2
2
 
3
3
  A gem to track commands typed in rails console along with tagging in realtime. The tags can be used to identify users. This works with plain [pry](https://github.com/pry/pry) and [IRB](https://github.com/ruby/ruby/tree/master/lib/irb) and rails console using pry or IRB. The values for log tags, log format, log file name, and memoization requirements are configurable.
4
4
 
5
- Pry and IRB both provide options for recordng history. It has a few disadvantages:
5
+ Pry and IRB both provide options for recording history. It has a few disadvantages:
6
6
 
7
7
  1. It is not possible to get the logs in realtime.
8
8
  2. There are no tagging options available.
9
9
  3. There is no way to know the time when the command was fired.
10
- 4. If we're connecting to console using ssh, the logs will be lost if the connection is disconnected since the logs are only written only when we exit the session.
10
+ 4. If we're connecting to the console using ssh, the logs will be lost if the connection is disconnected since the logs are only written only when we exit the session.
11
11
 
12
12
  `console_detective` overcomes such disadvantages.
13
13
  ## Installation
@@ -30,7 +30,8 @@ $ gem install console_detective
30
30
  ~~~~~
31
31
  ## Usage
32
32
 
33
- There are meaningful defaults for the config. If you are using rails, run `rails console`. Otherwise, `irb -rconsole_detective` or `pry -I./lib -r console_detective` will load the respective consoles with `console_detective` loaded.
33
+ There are meaningful defaults for the config. If you are using rails, run `rails console`. Otherwise, `irb -rconsole_detective` or `pry -I./lib -r console_detective` will load the respective consoles with `console_detective` loaded. You can also modify `~/.irbrc` or `~/.pryrc` with `require console_detective` to load the `console_detective` by default.
34
+
34
35
 
35
36
  The configs can be overridden by creating a file named `console_detective.rb` with following code.
36
37
 
@@ -56,7 +57,7 @@ ConsoleDetective.setup do |config|
56
57
  end
57
58
  ~~~
58
59
 
59
- If you are using rails, place this file in `config/initializers` folder and run `rails console`. Otherwise, `irb -r ./console_detective.rb` or `pry -r ./console_detective.rb` will load the respective consoles with `console_detective` loaded with modified config.
60
+ If you are using rails, place this file in `config/initializers` folder and run `rails console`. Otherwise, `irb -r ./console_detective.rb` or `pry -r ./console_detective.rb` will load the respective consoles with `console_detective` loaded with modified config. You can also modify `~/.irbrc` or `~/.pryrc` with `require console_detective.rb` to load the modified config by default.
60
61
 
61
62
  ## Development
62
63
 
@@ -1,8 +1,8 @@
1
1
  module ConsoleDetective
2
2
  module IrbLogger
3
- def evaluate(*args)
3
+ def evaluate(*args, **kw)
4
4
  ConsoleDetective::Utils.log_command(args.first.chomp)
5
- super(*args)
5
+ super(*args, **kw)
6
6
  end
7
7
  end
8
8
  end
@@ -1,3 +1,3 @@
1
1
  module ConsoleDetective
2
- VERSION = "0.1.1".freeze
2
+ VERSION = "0.1.2".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: console_detective
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
  - ArunkumarN
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-07-25 00:00:00.000000000 Z
11
+ date: 2021-07-29 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Commands typed in rails console will be tracked realtime in a log file
14
14
  in the given format
@@ -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.1.6
60
+ rubygems_version: 3.2.22
61
61
  signing_key:
62
62
  specification_version: 4
63
63
  summary: Track rails console user activity in real time