crypt-rot13 1.0.4 → 1.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/CHANGES +4 -0
- data/README +30 -35
- data/Rakefile +17 -17
- data/crypt-rot13.gemspec +15 -16
- data/lib/crypt/rot13.rb +1 -1
- data/test/test_crypt_rot13.rb +1 -1
- metadata +18 -8
data/CHANGES
CHANGED
data/README
CHANGED
@@ -1,48 +1,43 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
1
|
+
= Description
|
2
|
+
A library for performing simple character rotation (i.e. Caesar Cipher)
|
3
|
+
encryption. There are many like it, but this one is mine.
|
4
4
|
|
5
5
|
== Installation
|
6
|
-
|
7
|
-
|
8
|
-
rake install
|
9
|
-
|
10
|
-
=== Gem Installation
|
11
|
-
rake test (optional)
|
12
|
-
rake install_gem
|
6
|
+
|
7
|
+
gem install crypt-rot13
|
13
8
|
|
14
|
-
|
15
|
-
|
16
|
-
|
9
|
+
= Synopsis
|
10
|
+
require 'crypt/rot13'
|
11
|
+
include Crypt
|
17
12
|
|
18
|
-
|
19
|
-
|
13
|
+
str = Rot13.new("Hello World", 3) # Caesar cipher
|
14
|
+
puts str # "Khoor Zruog"
|
20
15
|
|
21
|
-
|
22
|
-
|
16
|
+
= Notes
|
17
|
+
Not unicode friendly. Only works on ASCII values 65-90 and 97-122.
|
23
18
|
|
24
|
-
|
19
|
+
See http://en.wikipedia.org/wiki/ROT13 for more on ROT13
|
25
20
|
|
26
|
-
|
27
|
-
|
28
|
-
|
21
|
+
= Acknowledgements
|
22
|
+
Thanks go to Gaius Julius Caesar (d. 44 BC) for creating one of the first,
|
23
|
+
and most simple, encryption schemes. Hail Caesar!
|
29
24
|
|
30
|
-
|
31
|
-
|
25
|
+
= Known Bugs
|
26
|
+
None that I'm aware of.
|
32
27
|
|
33
|
-
|
34
|
-
|
28
|
+
Please log any bugs you find on the SourceForge project page at
|
29
|
+
http://www.rubyforge.org/projects/shards.
|
35
30
|
|
36
|
-
|
37
|
-
|
31
|
+
= License
|
32
|
+
Artistic 2.0
|
38
33
|
|
39
|
-
|
40
|
-
|
34
|
+
= Copyright
|
35
|
+
(C) 2005-2010, Daniel J. Berger, All Rights Reserved
|
41
36
|
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
37
|
+
= Warranty
|
38
|
+
This package is provided "as is" and without any express or
|
39
|
+
implied warranties, including, without limitation, the implied
|
40
|
+
warranties of merchantability and fitness for a particular purpose.
|
46
41
|
|
47
|
-
|
48
|
-
|
42
|
+
= Author
|
43
|
+
Daniel J. Berger
|
data/Rakefile
CHANGED
@@ -1,26 +1,26 @@
|
|
1
1
|
require 'rake'
|
2
|
+
require 'rake/clean'
|
2
3
|
require 'rake/testtask'
|
3
4
|
|
4
|
-
|
5
|
-
task :install do
|
6
|
-
dest = File.join(Config::CONFIG['sitelibdir'], 'crypt')
|
7
|
-
Dir.mkdir(dest) unless File.exists? dest
|
8
|
-
cp 'lib/crypt/rot13.rb', dest, :verbose => true
|
9
|
-
end
|
5
|
+
CLEAN.include("**/*.gem", "**/*.rbc")
|
10
6
|
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
7
|
+
namespace :gem do
|
8
|
+
desc 'Create the crypt-rot13 gem'
|
9
|
+
task :create => [:clean] do
|
10
|
+
spec = eval(IO.read('crypt-rot13.gemspec'))
|
11
|
+
Gem::Builder.new(spec).build
|
12
|
+
end
|
16
13
|
|
17
|
-
desc 'Install the crypt-rot13
|
18
|
-
task :
|
19
|
-
|
20
|
-
|
14
|
+
desc 'Install the crypt-rot13 gem'
|
15
|
+
task :install => [:create] do
|
16
|
+
file = Dir["*.gem"].first
|
17
|
+
sh "gem install #{file}"
|
18
|
+
end
|
21
19
|
end
|
22
20
|
|
23
21
|
Rake::TestTask.new do |t|
|
24
|
-
|
25
|
-
|
22
|
+
t.warning = true
|
23
|
+
t.verbose = true
|
26
24
|
end
|
25
|
+
|
26
|
+
task :default => :test
|
data/crypt-rot13.gemspec
CHANGED
@@ -1,22 +1,21 @@
|
|
1
1
|
require 'rubygems'
|
2
2
|
|
3
3
|
Gem::Specification.new do |gem|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
gem.files = Dir['**/*'].reject{ |f| f.include?('CVS') }
|
4
|
+
gem.name = 'crypt-rot13'
|
5
|
+
gem.version = '1.0.5'
|
6
|
+
gem.author = 'Daniel J. Berger'
|
7
|
+
gem.license = 'Artistic 2.0'
|
8
|
+
gem.email = 'djberg96@gmail.com'
|
9
|
+
gem.homepage = 'http://www.rubyforge.org/projects/shards'
|
10
|
+
gem.summary = 'Character rotation encryption, i.e. Caesar Cipher'
|
11
|
+
gem.test_file = 'test/test_crypt_rot13.rb'
|
12
|
+
gem.files = Dir['**/*'].reject{ |f| f.include?('git') }
|
14
13
|
|
15
|
-
|
16
|
-
|
14
|
+
gem.rubyforge_project = 'shards'
|
15
|
+
gem.extra_rdoc_files = ['README', 'CHANGES', 'MANIFEST']
|
17
16
|
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
17
|
+
gem.description = <<-EOF
|
18
|
+
The crypt-rot13 library provides an interface for a simple character
|
19
|
+
substitution cipher known as ROT13, a variation on the Caesar cipher.
|
20
|
+
EOF
|
22
21
|
end
|
data/lib/crypt/rot13.rb
CHANGED
data/test/test_crypt_rot13.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: crypt-rot13
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
4
|
+
hash: 29
|
5
|
+
prerelease:
|
6
|
+
segments:
|
7
|
+
- 1
|
8
|
+
- 0
|
9
|
+
- 5
|
10
|
+
version: 1.0.5
|
5
11
|
platform: ruby
|
6
12
|
authors:
|
7
13
|
- Daniel J. Berger
|
@@ -9,11 +15,10 @@ autorequire:
|
|
9
15
|
bindir: bin
|
10
16
|
cert_chain: []
|
11
17
|
|
12
|
-
date:
|
13
|
-
default_executable:
|
18
|
+
date: 2011-09-01 00:00:00 Z
|
14
19
|
dependencies: []
|
15
20
|
|
16
|
-
description: "
|
21
|
+
description: " The crypt-rot13 library provides an interface for a simple character\n substitution cipher known as ROT13, a variation on the Caesar cipher.\n"
|
17
22
|
email: djberg96@gmail.com
|
18
23
|
executables: []
|
19
24
|
|
@@ -31,7 +36,6 @@ files:
|
|
31
36
|
- Rakefile
|
32
37
|
- README
|
33
38
|
- test/test_crypt_rot13.rb
|
34
|
-
has_rdoc: true
|
35
39
|
homepage: http://www.rubyforge.org/projects/shards
|
36
40
|
licenses:
|
37
41
|
- Artistic 2.0
|
@@ -41,21 +45,27 @@ rdoc_options: []
|
|
41
45
|
require_paths:
|
42
46
|
- lib
|
43
47
|
required_ruby_version: !ruby/object:Gem::Requirement
|
48
|
+
none: false
|
44
49
|
requirements:
|
45
50
|
- - ">="
|
46
51
|
- !ruby/object:Gem::Version
|
52
|
+
hash: 3
|
53
|
+
segments:
|
54
|
+
- 0
|
47
55
|
version: "0"
|
48
|
-
version:
|
49
56
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
50
58
|
requirements:
|
51
59
|
- - ">="
|
52
60
|
- !ruby/object:Gem::Version
|
61
|
+
hash: 3
|
62
|
+
segments:
|
63
|
+
- 0
|
53
64
|
version: "0"
|
54
|
-
version:
|
55
65
|
requirements: []
|
56
66
|
|
57
67
|
rubyforge_project: shards
|
58
|
-
rubygems_version: 1.
|
68
|
+
rubygems_version: 1.8.10
|
59
69
|
signing_key:
|
60
70
|
specification_version: 3
|
61
71
|
summary: Character rotation encryption, i.e. Caesar Cipher
|