vainy 0.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +7 -0
  2. data/lib/vainy.rb +12 -0
  3. metadata +44 -0
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: cd88326182177ed41bff1b83a56b3055e367b781
4
+ data.tar.gz: 1d9fe05f0e7ada0343bb225e453e690b41ee57cf
5
+ SHA512:
6
+ metadata.gz: da8196b37936977ec78f4d77f26b61f20f4a0b96ccd6b2d9fbf56882eae9e4a594d0e7239abbec486f8f45b94495362b9e5f1384eae8cae1f3392baea42bbf1e
7
+ data.tar.gz: 75233eccc37a3efb0be78aa47464075464df53a8d716dd406e4bc3d4e1a7cae0f81a5430f189c7daca281fe1b45dfe85a0667babe3d1cbb44fd7d85a5b1299ef
@@ -0,0 +1,12 @@
1
+ require 'open-uri'
2
+ class Vain
3
+ def self.download(url,filename)
4
+ imageURL = open(url)
5
+ image = File.new("#{filename}",'w')
6
+
7
+ imageURL.each do |pixel|
8
+ image.write(pixel)
9
+ end
10
+ image.close
11
+ end
12
+ end
metadata ADDED
@@ -0,0 +1,44 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: vainy
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.0
5
+ platform: ruby
6
+ authors:
7
+ - Guga katsiashvili
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2016-09-21 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description: A simple class to download pictures easily
14
+ email: guga.katsiashvili@gmail.com
15
+ executables: []
16
+ extensions: []
17
+ extra_rdoc_files: []
18
+ files:
19
+ - lib/vainy.rb
20
+ homepage: http://rubygems.org/gems/vainy
21
+ licenses:
22
+ - MIT
23
+ metadata: {}
24
+ post_install_message:
25
+ rdoc_options: []
26
+ require_paths:
27
+ - lib
28
+ required_ruby_version: !ruby/object:Gem::Requirement
29
+ requirements:
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: '0'
33
+ required_rubygems_version: !ruby/object:Gem::Requirement
34
+ requirements:
35
+ - - ">="
36
+ - !ruby/object:Gem::Version
37
+ version: '0'
38
+ requirements: []
39
+ rubyforge_project:
40
+ rubygems_version: 2.4.8
41
+ signing_key:
42
+ specification_version: 4
43
+ summary: Vain!
44
+ test_files: []