metaipsum 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +5 -1
- data/lib/metaipsum.rb +14 -0
- data/lib/metaipsum/version.rb +1 -1
- data/metaipsum.gemspec +1 -0
- data/spec/metaipsum_spec.rb +4 -0
- metadata +17 -1
data/README.md
CHANGED
@@ -19,7 +19,11 @@ Or install it yourself as:
|
|
19
19
|
|
20
20
|
## Usage
|
21
21
|
|
22
|
-
|
22
|
+
Run the `metaipsum` command on your command-line with a file as an argument:
|
23
|
+
|
24
|
+
metaipsum source.txt
|
25
|
+
|
26
|
+
The tool will return your ipsum placeholder text, as well as *copy it to your clipboard*.
|
23
27
|
|
24
28
|
## Contributing
|
25
29
|
|
data/lib/metaipsum.rb
CHANGED
@@ -1,4 +1,5 @@
|
|
1
1
|
require "metaipsum/version"
|
2
|
+
require 'clipboard'
|
2
3
|
|
3
4
|
module Metaipsum
|
4
5
|
|
@@ -22,6 +23,14 @@ module Metaipsum
|
|
22
23
|
|
23
24
|
end
|
24
25
|
|
26
|
+
def self.clipboard
|
27
|
+
|
28
|
+
Clipboard.copy "foo"
|
29
|
+
Clipboard.paste
|
30
|
+
|
31
|
+
end
|
32
|
+
|
33
|
+
|
25
34
|
def self.generator
|
26
35
|
|
27
36
|
base = ARGV[0]
|
@@ -39,6 +48,8 @@ module Metaipsum
|
|
39
48
|
count.times do
|
40
49
|
ipsum << array.sample + " "
|
41
50
|
end
|
51
|
+
|
52
|
+
Clipboard.copy ipsum
|
42
53
|
|
43
54
|
print <<-eos
|
44
55
|
You passed in:
|
@@ -47,8 +58,11 @@ module Metaipsum
|
|
47
58
|
Here is your ipsum text:
|
48
59
|
#{ ipsum }
|
49
60
|
|
61
|
+
It has been copied to your clipboard.
|
62
|
+
|
50
63
|
eos
|
51
64
|
|
65
|
+
|
52
66
|
else
|
53
67
|
|
54
68
|
return nil
|
data/lib/metaipsum/version.rb
CHANGED
data/metaipsum.gemspec
CHANGED
@@ -14,6 +14,7 @@ Gem::Specification.new do |gem|
|
|
14
14
|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
15
15
|
gem.add_development_dependency "rspec", ">= 2.0.0"
|
16
16
|
gem.add_development_dependency "rake"
|
17
|
+
gem.add_development_dependency "clipboard"
|
17
18
|
gem.name = "metaipsum"
|
18
19
|
gem.require_paths = ["lib"]
|
19
20
|
gem.version = Metaipsum::VERSION
|
data/spec/metaipsum_spec.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metaipsum
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -43,6 +43,22 @@ dependencies:
|
|
43
43
|
- - ! '>='
|
44
44
|
- !ruby/object:Gem::Version
|
45
45
|
version: '0'
|
46
|
+
- !ruby/object:Gem::Dependency
|
47
|
+
name: clipboard
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
49
|
+
none: false
|
50
|
+
requirements:
|
51
|
+
- - ! '>='
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '0'
|
54
|
+
type: :development
|
55
|
+
prerelease: false
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
58
|
+
requirements:
|
59
|
+
- - ! '>='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
46
62
|
description: Lorem ipsum generator, generator
|
47
63
|
email:
|
48
64
|
- kristian@redsashimi.com
|