explain_shell 1.0.0 → 1.0.1

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
  SHA1:
3
- metadata.gz: 54c60e41d3c44ab082ff294249f2af6701c7919f
4
- data.tar.gz: ff2947ce5b102b7d57a1b9919d0f48411089b1f0
3
+ metadata.gz: 1bb4695d1f8b3ee10da4c0607af886f06c6b9057
4
+ data.tar.gz: 3a35afbaf9eeba98e2d9e8c00eeb4866df70ca72
5
5
  SHA512:
6
- metadata.gz: 9553c723ef8ec5a17a91ee488f04d672cdf45b580542bd6a34f9d840cd5a485892de817a08d0a3ce35416b54bc9ada9d010e5dc43ca9ffdcfa8b5202bd48b599
7
- data.tar.gz: 34e69f497d7f8f49f44f3bb2f05772c59fe31d151b5704361bf2c113ea2147f0236c449e78328cf84b37f249e16f58112b2042a05622a6791b860dec8353cf0e
6
+ metadata.gz: ca7aed422a6749bb198a97372fc845dcab7c1c85fbca9d8d5870c6b1ca34ad7f90ee5bb0bea4347f1d333efe088a6914d20fe519b11150d098f8f233bc830e93
7
+ data.tar.gz: 8cbe97fa356a9eb4eb9c241f2946c373611bef518bb32a1a2354e7c9d190eea4bd7e43290f1bea6a3dbaeb50c90b9b638978fe260315e5dae5a48e3ed87f47d4
@@ -1,17 +1,4 @@
1
- #!/usr/bin/env sh
1
+ #!/usr/bin/env ruby
2
2
 
3
- # base url with first command already injected
4
- # $ explain tar
5
- # => http://explainshel.com/explain/tar?args=
6
- URL="http://explainshell.com/explain/$1?args="
7
-
8
- # removes $1 (tar) from arguments ($@)
9
- shift;
10
-
11
- # iterates over remaining args and adds builds the rest of the url
12
- for i in "$@"; do
13
- URL=$URL"$i""+"
14
- done
15
-
16
- # opens url in browser
17
- open $URL
3
+ explain_script = File.expand_path('../explain.sh', __FILE__)
4
+ exec "#{explain_script} #{ARGV}"
@@ -0,0 +1,17 @@
1
+ #!/usr/bin/env sh
2
+
3
+ # base url with first command already injected
4
+ # $ explain tar
5
+ # => http://explainshel.com/explain/tar?args=
6
+ url="http://explainshell.com/explain/$1?args="
7
+
8
+ # removes $1 (tar) from arguments ($@)
9
+ shift;
10
+
11
+ # iterates over remaining args and adds builds the rest of the url
12
+ for i in "$@"; do
13
+ url=$url"$i""+"
14
+ done
15
+
16
+ # opens url in browser
17
+ open $url
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |gem|
4
4
  gem.name = "explain_shell"
5
- gem.version = "1.0.0"
5
+ gem.version = "1.0.1"
6
6
  gem.authors = ["Richard Schneeman"]
7
7
  gem.email = ["richard.schneeman+rubygems@gmail.com"]
8
8
  gem.description = %q{ Bash interface to http://explainshell.com/ }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: explain_shell
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Richard Schneeman
@@ -15,11 +15,13 @@ email:
15
15
  - richard.schneeman+rubygems@gmail.com
16
16
  executables:
17
17
  - explain
18
+ - explain.sh
18
19
  extensions: []
19
20
  extra_rdoc_files: []
20
21
  files:
21
22
  - .gitignore
22
23
  - bin/explain
24
+ - bin/explain.sh
23
25
  - explain_shell.gemspec
24
26
  - readme.md
25
27
  homepage: https://github.com/schneems/explain_shell