babel 0.0.1 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/babel.rb +89 -2
- metadata +3 -4
data/lib/babel.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
|
2
2
|
module Babel
|
3
|
-
VERSION = '0.
|
3
|
+
VERSION = '0.1.1'
|
4
4
|
|
5
5
|
CHUNKS = [
|
6
6
|
'ACM',
|
@@ -2463,6 +2463,93 @@ LONG_TEXT_1 = ["To whom it may concern,",
|
|
2463
2463
|
end.join(".").downcase
|
2464
2464
|
end
|
2465
2465
|
|
2466
|
-
|
2466
|
+
def morph_login(login)
|
2467
|
+
login = login.downcase.gsub(/\s/, "")
|
2468
|
+
morphs = [:ored, :ed, :own, :age, :xor, :ck, :er, :leetz, :leetw2, :leetx, :leetw, :leets4, :leeto2, :leetg, :leetf2, :leetb, :leets3, :leets2, :leets, :leetf, :leetc, :rovar, :leeta, :leete, :leetl, :leett, :leeto, :zor, :ster, :lor, :prependnr1, :first, :iam, :thereal, :appendnr1, :forreal, :prependn, :appendn]
|
2469
|
+
morph = morphs[rand(morphs.size)]
|
2470
|
+
stripped = login.gsub(/[aoueiy]*$/, "")
|
2471
|
+
case morph
|
2472
|
+
when :ed
|
2473
|
+
login.gsub(/ed^/, "t")
|
2474
|
+
when :ored
|
2475
|
+
login.gsub(/or^/, "ored")
|
2476
|
+
when :own
|
2477
|
+
login.gsub(/own/, "pwn")
|
2478
|
+
when :age
|
2479
|
+
"#{login}age"
|
2480
|
+
when :ck
|
2481
|
+
login.gsub(/ck/, "x")
|
2482
|
+
when :er
|
2483
|
+
login.gsub(/er$/, "or")
|
2484
|
+
when :leetz
|
2485
|
+
login.gsub(/z/, "s")
|
2486
|
+
when :leetw2
|
2487
|
+
login.gsub(/w/, "dubya")
|
2488
|
+
when :leetb
|
2489
|
+
login.gsub(/b/, "8")
|
2490
|
+
when :leetx
|
2491
|
+
login.gsub(/x/, "ecks")
|
2492
|
+
when :leetw
|
2493
|
+
login.gsub(/w/, "vv")
|
2494
|
+
when :leets4
|
2495
|
+
login.gsub(/s/, "ehs")
|
2496
|
+
when :leeto2
|
2497
|
+
login.gsub(/o/, "oh")
|
2498
|
+
when :leetg
|
2499
|
+
login.gsub(/g/, "6")
|
2500
|
+
when :leetf2
|
2501
|
+
login.gsub(/f/, "v")
|
2502
|
+
when :leeta
|
2503
|
+
login.gsub(/a/, "4")
|
2504
|
+
when :leets3
|
2505
|
+
login.gsub(/s/, "5")
|
2506
|
+
when :leete
|
2507
|
+
login.gsub(/e/, "3")
|
2508
|
+
when :leetl
|
2509
|
+
login.gsub(/l/, "1")
|
2510
|
+
when :leett
|
2511
|
+
login.gsub(/t/, "7")
|
2512
|
+
when :leeto
|
2513
|
+
login.gsub(/o/, "0")
|
2514
|
+
when :leets
|
2515
|
+
login.gsub(/s/, "z")
|
2516
|
+
when :leets2
|
2517
|
+
login.gsub(/s/, "c")
|
2518
|
+
when :leetf
|
2519
|
+
login.gsub(/f/, "ph")
|
2520
|
+
when :leetc
|
2521
|
+
login.gsub(/c/, "k")
|
2522
|
+
when :rovar
|
2523
|
+
login.gsub(/([cdfghklmnpqrstvwxz])/, "\\1o\\1")
|
2524
|
+
when :zor
|
2525
|
+
"#{stripped}zor"
|
2526
|
+
when :xor
|
2527
|
+
"#{stripped}xor"
|
2528
|
+
when :ster
|
2529
|
+
"#{stripped}ster"
|
2530
|
+
when :lor
|
2531
|
+
"#{stripped}lor"
|
2532
|
+
when :iam
|
2533
|
+
"iam#{login}"
|
2534
|
+
when :thereal
|
2535
|
+
"thereal#{login}"
|
2536
|
+
when :appendnr1
|
2537
|
+
"#{login}nr1"
|
2538
|
+
when :forreal
|
2539
|
+
"#{login}forreal"
|
2540
|
+
when :prependnr1
|
2541
|
+
"nr1#{login}"
|
2542
|
+
when :first
|
2543
|
+
"thefirst#{login}"
|
2544
|
+
when :prependn
|
2545
|
+
"#{rand(100)}#{login}"
|
2546
|
+
when :appendn
|
2547
|
+
"#{login}#{rand(100)}"
|
2548
|
+
else
|
2549
|
+
raise "unknown morph #{morph}"
|
2550
|
+
end
|
2551
|
+
end
|
2552
|
+
|
2553
|
+
module_function :produce, :random_single, :random_short, :random_long, :morph_login
|
2467
2554
|
|
2468
2555
|
end
|
metadata
CHANGED
@@ -1,10 +1,10 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
|
-
rubygems_version: 0.
|
2
|
+
rubygems_version: 0.8.11
|
3
3
|
specification_version: 1
|
4
4
|
name: babel
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 0.
|
7
|
-
date: 2006-11-
|
6
|
+
version: 0.1.1
|
7
|
+
date: 2006-11-22 00:00:00 +01:00
|
8
8
|
summary: Lorem ipsum generator on methamphetamine
|
9
9
|
require_paths:
|
10
10
|
- lib
|
@@ -25,7 +25,6 @@ required_ruby_version: !ruby/object:Gem::Version::Requirement
|
|
25
25
|
platform: ruby
|
26
26
|
signing_key:
|
27
27
|
cert_chain:
|
28
|
-
post_install_message:
|
29
28
|
authors:
|
30
29
|
- Ryan Davis
|
31
30
|
files:
|