cuse 0.0.0 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/cuse.rb +11 -3
- metadata +1 -1
data/lib/cuse.rb
CHANGED
@@ -1,5 +1,13 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
1
|
+
# "open" Kernel module, that's where the `puts` lives.
|
2
|
+
module Kernel
|
3
|
+
# our new puts
|
4
|
+
def puts_with_append *args
|
5
|
+
puts_without_append args.map{|a| a + "| Let's Go Orange!"}
|
4
6
|
end
|
7
|
+
|
8
|
+
# back up name of old puts
|
9
|
+
alias_method :puts_without_append, :puts
|
10
|
+
|
11
|
+
# now set our version as new puts
|
12
|
+
alias_method :puts, :puts_with_append
|
5
13
|
end
|