discotech 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
data/.gitignore ADDED
@@ -0,0 +1,4 @@
1
+ *.gem
2
+ .bundle
3
+ Gemfile.lock
4
+ pkg/*
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source "http://rubygems.org"
2
+
3
+ # Specify your gem's dependencies in discotech.gemspec
4
+ gemspec
data/Rakefile ADDED
@@ -0,0 +1 @@
1
+ require "bundler/gem_tasks"
data/bin/discotech ADDED
@@ -0,0 +1,19 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "discotech"
4
+
5
+ colors = [
6
+ :red, :green, :yellow,
7
+ :blue, :magenta, :cyan, :white
8
+ ]
9
+
10
+ decorations = [
11
+ :bold
12
+ ]
13
+
14
+ ARGF.chars.each do |char|
15
+ char = Discotech.send decorations.sample, char
16
+ char = Discotech.send colors.sample, char
17
+
18
+ print char
19
+ end
data/discotech.gemspec ADDED
@@ -0,0 +1,24 @@
1
+ # -*- encoding: utf-8 -*-
2
+ $:.push File.expand_path("../lib", __FILE__)
3
+ require "discotech/version"
4
+
5
+ Gem::Specification.new do |s|
6
+ s.name = "discotech"
7
+ s.version = Discotech::VERSION
8
+ s.authors = ["Johannes Gorset"]
9
+ s.email = ["jgorset@gmail.com"]
10
+ s.homepage = "http://github.com/jgorset/discotech"
11
+ s.summary = "Party time!"
12
+ s.description = "Party time!"
13
+
14
+ s.rubyforge_project = "discotech"
15
+
16
+ s.files = `git ls-files`.split("\n")
17
+ s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
18
+ s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
19
+ s.require_paths = ["lib"]
20
+
21
+ # specify any dependencies here; for example:
22
+ # s.add_development_dependency "rspec"
23
+ # s.add_runtime_dependency "rest-client"
24
+ end
@@ -0,0 +1,3 @@
1
+ module Discotech
2
+ VERSION = "0.0.1"
3
+ end
data/lib/discotech.rb ADDED
@@ -0,0 +1,43 @@
1
+ require "discotech/version"
2
+
3
+ module Discotech
4
+ def self.blink string
5
+ "\e[5m" + string + "\e[25m"
6
+ end
7
+
8
+ def self.bold string
9
+ "\e[1m" + string + "\e[22m"
10
+ end
11
+
12
+ def self.black string
13
+ "\e[30m" + string + "\e[39m"
14
+ end
15
+
16
+ def self.red string
17
+ "\e[31m" + string + "\e[39m"
18
+ end
19
+
20
+ def self.green string
21
+ "\e[32m" + string + "\e[39m"
22
+ end
23
+
24
+ def self.yellow string
25
+ "\e[33m" + string + "\e[39m"
26
+ end
27
+
28
+ def self.blue string
29
+ "\e[34m" + string + "\e[39m"
30
+ end
31
+
32
+ def self.magenta string
33
+ "\e[35m" + string + "\e[39m"
34
+ end
35
+
36
+ def self.cyan string
37
+ "\e[36m" + string + "\e[39m"
38
+ end
39
+
40
+ def self.white string
41
+ "\e[37m" + string + "\e[39m"
42
+ end
43
+ end
metadata ADDED
@@ -0,0 +1,53 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: discotech
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ prerelease:
6
+ platform: ruby
7
+ authors:
8
+ - Johannes Gorset
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2012-01-27 00:00:00.000000000 Z
13
+ dependencies: []
14
+ description: Party time!
15
+ email:
16
+ - jgorset@gmail.com
17
+ executables:
18
+ - discotech
19
+ extensions: []
20
+ extra_rdoc_files: []
21
+ files:
22
+ - .gitignore
23
+ - Gemfile
24
+ - Rakefile
25
+ - bin/discotech
26
+ - discotech.gemspec
27
+ - lib/discotech.rb
28
+ - lib/discotech/version.rb
29
+ homepage: http://github.com/jgorset/discotech
30
+ licenses: []
31
+ post_install_message:
32
+ rdoc_options: []
33
+ require_paths:
34
+ - lib
35
+ required_ruby_version: !ruby/object:Gem::Requirement
36
+ none: false
37
+ requirements:
38
+ - - ! '>='
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ required_rubygems_version: !ruby/object:Gem::Requirement
42
+ none: false
43
+ requirements:
44
+ - - ! '>='
45
+ - !ruby/object:Gem::Version
46
+ version: '0'
47
+ requirements: []
48
+ rubyforge_project: discotech
49
+ rubygems_version: 1.8.11
50
+ signing_key:
51
+ specification_version: 3
52
+ summary: Party time!
53
+ test_files: []