rgb2hex 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/bin/rgb2hex +4 -0
- data/lib/rgb2hex.rb +17 -0
- metadata +45 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 9e4720acbe7b30e319d117b618201b0a43daff72
|
4
|
+
data.tar.gz: b6f7ccf569be8cc73eaf154db89d4157ed6a53a4
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 5b8f1332cddc9bf96337355dac6a1affec715c8aa96b70ec9bb711e1a4f37b4e60d0252449ffb6562b53c8ef4f2ca5aabc1c7d39552967855ad2ec1c8820b0d1
|
7
|
+
data.tar.gz: b5cc873f5a12508bcb907f94e970219a981b7461a2c65c03e4c16182ecddc8c3bd5798bf53a1a8a91a45410df22c4f49c14484403f517d82236912d73c093544
|
data/bin/rgb2hex
ADDED
data/lib/rgb2hex.rb
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
# Class with single class method which does convertion
|
2
|
+
class Rgb2Hex
|
3
|
+
# Produces a HEX value out of 3 ints
|
4
|
+
#
|
5
|
+
# Example:
|
6
|
+
# >> Rgb2Hex(0, 0, 0)
|
7
|
+
# => #000000
|
8
|
+
#
|
9
|
+
# Arguments:
|
10
|
+
# red: (Integer)
|
11
|
+
# green: (Integer)
|
12
|
+
# blue: (Integer)
|
13
|
+
|
14
|
+
def self.convert(red = 0, green = 0, blue = 0)
|
15
|
+
"#000000"
|
16
|
+
end
|
17
|
+
end
|
metadata
ADDED
@@ -0,0 +1,45 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: rgb2hex
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Jeff Zelenkov
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2013-07-26 00:00:00.000000000 Z
|
12
|
+
dependencies: []
|
13
|
+
description: Converts RGB values to HEX value
|
14
|
+
email: zj@jz.ee
|
15
|
+
executables:
|
16
|
+
- rgb2hex
|
17
|
+
extensions: []
|
18
|
+
extra_rdoc_files: []
|
19
|
+
files:
|
20
|
+
- lib/rgb2hex.rb
|
21
|
+
- bin/rgb2hex
|
22
|
+
homepage: http://rubygems.org/gems/rgb2hex
|
23
|
+
licenses: []
|
24
|
+
metadata: {}
|
25
|
+
post_install_message:
|
26
|
+
rdoc_options: []
|
27
|
+
require_paths:
|
28
|
+
- lib
|
29
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - '>='
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
35
|
+
requirements:
|
36
|
+
- - '>='
|
37
|
+
- !ruby/object:Gem::Version
|
38
|
+
version: '0'
|
39
|
+
requirements: []
|
40
|
+
rubyforge_project:
|
41
|
+
rubygems_version: 2.0.3
|
42
|
+
signing_key:
|
43
|
+
specification_version: 4
|
44
|
+
summary: RGB -> HEX
|
45
|
+
test_files: []
|