sc 0.0.1
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 +7 -0
- data/LICENSE +19 -0
- data/README +33 -0
- data/bin/sc +83 -0
- data/sc.gemspec +14 -0
- metadata +49 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 92e3c50b871abb4e7652633da97850ace03d45bb
|
4
|
+
data.tar.gz: bed4e0d0ce8fe9919569a9f44c6eb7f2a39d4c63
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 4d0fa0eab59727491e5bd490ec7e962fad8482f26a9df40825287b2f862b7fa8d418548e6ecaf19c52376d88d337b630ca671b210972f56e1eb308da2286e8d6
|
7
|
+
data.tar.gz: 10b64465f0f03e524779255cd45d4c14f0a2a99c0e4c7840dbf33ab29e366abfe5c64578e90964080eb1b08970bb8844a9b2c9ced773506abfeb534d235b3407
|
data/LICENSE
ADDED
@@ -0,0 +1,19 @@
|
|
1
|
+
Copyright (c) 2013 Michel Martens
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
4
|
+
of this software and associated documentation files (the "Software"), to deal
|
5
|
+
in the Software without restriction, including without limitation the rights
|
6
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
7
|
+
copies of the Software, and to permit persons to whom the Software is
|
8
|
+
furnished to do so, subject to the following conditions:
|
9
|
+
|
10
|
+
The above copyright notice and this permission notice shall be included in
|
11
|
+
all copies or substantial portions of the Software.
|
12
|
+
|
13
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
14
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
15
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
16
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
17
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
18
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
19
|
+
THE SOFTWARE.
|
data/README
ADDED
@@ -0,0 +1,33 @@
|
|
1
|
+
sc
|
2
|
+
==
|
3
|
+
|
4
|
+
List of HTTP status codes
|
5
|
+
|
6
|
+
Description
|
7
|
+
-----------
|
8
|
+
|
9
|
+
List of HTTP status codes that can be filtered with a regular
|
10
|
+
expression.
|
11
|
+
|
12
|
+
Examples
|
13
|
+
--------
|
14
|
+
|
15
|
+
``` console
|
16
|
+
$ sc 400
|
17
|
+
400: Bad Request
|
18
|
+
|
19
|
+
$ sc 302
|
20
|
+
302: Found
|
21
|
+
|
22
|
+
$ sc 5.0
|
23
|
+
500: Internal Server Error
|
24
|
+
510: Not Extended
|
25
|
+
```
|
26
|
+
|
27
|
+
## Installation
|
28
|
+
|
29
|
+
You can install it using rubygems.
|
30
|
+
|
31
|
+
```
|
32
|
+
$ gem install sc
|
33
|
+
```
|
data/bin/sc
ADDED
@@ -0,0 +1,83 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
if ARGV[0].nil?
|
4
|
+
puts <<-EOS
|
5
|
+
Usage: sc <pattern>
|
6
|
+
|
7
|
+
Examples:
|
8
|
+
|
9
|
+
$ sc 400
|
10
|
+
400: Bad Request
|
11
|
+
|
12
|
+
$ sc 302
|
13
|
+
302: Found
|
14
|
+
|
15
|
+
$ sc 5.0
|
16
|
+
500: Internal Server Error
|
17
|
+
510: Not Extended
|
18
|
+
EOS
|
19
|
+
|
20
|
+
exit(1)
|
21
|
+
end
|
22
|
+
|
23
|
+
puts File.readlines(__FILE__).grep(/^#{ARGV[0]}:/)
|
24
|
+
|
25
|
+
__END__
|
26
|
+
100: Continue
|
27
|
+
101: Switching Protocols
|
28
|
+
102: Processing
|
29
|
+
200: OK
|
30
|
+
201: Created
|
31
|
+
202: Accepted
|
32
|
+
203: Non-Authoritative Information
|
33
|
+
204: No Content
|
34
|
+
205: Reset Content
|
35
|
+
206: Partial Content
|
36
|
+
207: Multi-Status
|
37
|
+
208: Already Reported
|
38
|
+
226: IM Used
|
39
|
+
300: Multiple Choices
|
40
|
+
301: Moved Permanently
|
41
|
+
302: Found
|
42
|
+
303: See Other
|
43
|
+
304: Not Modified
|
44
|
+
305: Use Proxy
|
45
|
+
306: Reserved
|
46
|
+
307: Temporary Redirect
|
47
|
+
308: Permanent Redirect
|
48
|
+
400: Bad Request
|
49
|
+
401: Unauthorized
|
50
|
+
402: Payment Required
|
51
|
+
403: Forbidden
|
52
|
+
404: Not Found
|
53
|
+
405: Method Not Allowed
|
54
|
+
406: Not Acceptable
|
55
|
+
407: Proxy Authentication Required
|
56
|
+
408: Request Timeout
|
57
|
+
409: Conflict
|
58
|
+
410: Gone
|
59
|
+
411: Length Required
|
60
|
+
412: Precondition Failed
|
61
|
+
413: Request Entity Too Large
|
62
|
+
414: Request-URI Too Long
|
63
|
+
415: Unsupported Media Type
|
64
|
+
416: Requested Range Not Satisfiable
|
65
|
+
417: Expectation Failed
|
66
|
+
422: Unprocessable Entity
|
67
|
+
423: Locked
|
68
|
+
424: Failed Dependency
|
69
|
+
426: Upgrade Required
|
70
|
+
428: Precondition Required
|
71
|
+
429: Too Many Requests
|
72
|
+
431: Request Header Fields Too Large
|
73
|
+
500: Internal Server Error
|
74
|
+
501: Not Implemented
|
75
|
+
502: Bad Gateway
|
76
|
+
503: Service Unavailable
|
77
|
+
504: Gateway Timeout
|
78
|
+
505: HTTP Version Not Supported
|
79
|
+
506: Variant Also Negotiates (Experimental)
|
80
|
+
507: Insufficient Storage
|
81
|
+
508: Loop Detected
|
82
|
+
510: Not Extended
|
83
|
+
511: Network Authentication Required
|
data/sc.gemspec
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
Gem::Specification.new do |s|
|
4
|
+
s.name = "sc"
|
5
|
+
s.version = "0.0.1"
|
6
|
+
s.summary = "List of HTTP status codes"
|
7
|
+
s.description = "List of HTTP status codes with pattern matching."
|
8
|
+
s.authors = ["Michel Martens"]
|
9
|
+
s.email = ["michel@soveran.com"]
|
10
|
+
s.homepage = "https://github.com/soveran/sc"
|
11
|
+
s.files = `git ls-files`.split("\n")
|
12
|
+
s.license = "MIT"
|
13
|
+
s.executables.push("sc")
|
14
|
+
end
|
metadata
ADDED
@@ -0,0 +1,49 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: sc
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Michel Martens
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2013-06-07 00:00:00.000000000 Z
|
12
|
+
dependencies: []
|
13
|
+
description: List of HTTP status codes with pattern matching.
|
14
|
+
email:
|
15
|
+
- michel@soveran.com
|
16
|
+
executables:
|
17
|
+
- sc
|
18
|
+
extensions: []
|
19
|
+
extra_rdoc_files: []
|
20
|
+
files:
|
21
|
+
- LICENSE
|
22
|
+
- README
|
23
|
+
- bin/sc
|
24
|
+
- sc.gemspec
|
25
|
+
homepage: https://github.com/soveran/sc
|
26
|
+
licenses:
|
27
|
+
- MIT
|
28
|
+
metadata: {}
|
29
|
+
post_install_message:
|
30
|
+
rdoc_options: []
|
31
|
+
require_paths:
|
32
|
+
- lib
|
33
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
34
|
+
requirements:
|
35
|
+
- - '>='
|
36
|
+
- !ruby/object:Gem::Version
|
37
|
+
version: '0'
|
38
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
39
|
+
requirements:
|
40
|
+
- - '>='
|
41
|
+
- !ruby/object:Gem::Version
|
42
|
+
version: '0'
|
43
|
+
requirements: []
|
44
|
+
rubyforge_project:
|
45
|
+
rubygems_version: 2.0.3
|
46
|
+
signing_key:
|
47
|
+
specification_version: 4
|
48
|
+
summary: List of HTTP status codes
|
49
|
+
test_files: []
|