tarzan 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 48d8fc93eaece86456048969d194c58108e8314b
4
- data.tar.gz: aaa3c190fa9936411732d48848a6565dd231fb5b
3
+ metadata.gz: 8d1f8f241b3d98808dd495d75bc8ccfcb8967e39
4
+ data.tar.gz: 6f297af38489451bb3876e22b888bcfb84edf0eb
5
5
  SHA512:
6
- metadata.gz: 89daeae501122d5506262b6dce5b21d89323a8f5a44ef8fdd79ebb186e6fe9469d546bffdb89de03b0c3f675d538041afcda9437a5d654839bfabfc76681fcb9
7
- data.tar.gz: d793de75d0576cc6f33eef246ccb75c480a8cb58fc47bd77091637158df2ddc11b6d69f17af598d8354a14c9a6265fe7b90de2b98df180dcd42fc01e81756f2c
6
+ metadata.gz: c63d52815b50dbf9ad537a39fa5ed99f50bfbf3c85037c2d115977b7778943b342c7eb387b8dcab616fcad1a31baf0b766054387de52ee2c9a71273f643b13f3
7
+ data.tar.gz: 28bcfd412957d457c90a81275d1a5ee124303a2d0fffd7b5a5a67e6ac57298798c54928b7cad81e0cb2a125bdf431ce7496abbe765ac5d85c6c315cf56b74b2a
data/LICENSE.txt CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2013 claudiob
1
+ Copyright (c) 2014 claudiob
2
2
 
3
3
  MIT License
4
4
 
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Tarzan
2
2
 
3
- TODO: Write a gem description
3
+ King of the Game Jungle
4
4
 
5
5
  ## Installation
6
6
 
@@ -18,11 +18,13 @@ Or install it yourself as:
18
18
 
19
19
  ## Usage
20
20
 
21
- TODO: Write usage instructions here
21
+ From the command line run:
22
+
23
+ $ tarzan
22
24
 
23
25
  ## Contributing
24
26
 
25
- 1. Fork it
27
+ 1. Fork it ( http://github.com/claudiob/tarzan/fork )
26
28
  2. Create your feature branch (`git checkout -b my-new-feature`)
27
29
  3. Commit your changes (`git commit -am 'Add some feature'`)
28
30
  4. Push to the branch (`git push origin my-new-feature`)
data/bin/tarzan ADDED
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ begin
4
+ require 'tarzan'
5
+ rescue LoadError
6
+ require 'rubygems'
7
+ require 'tarzan'
8
+ end
9
+
10
+ Tarzan.play!
@@ -1,3 +1,3 @@
1
1
  module Tarzan
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
data/lib/tarzan.rb CHANGED
@@ -1,5 +1,22 @@
1
- require "tarzan/version"
2
-
3
1
  module Tarzan
4
- # Your code goes here...
5
- end
2
+ def self.play!
3
+ puts %{Welcome to the Game Hall}
4
+
5
+ puts %{Let’s play Rock Paper Scissors}
6
+
7
+ puts %{Pick [R]ock, [P]aper, or [S]cissors: }
8
+
9
+ move_p1 = gets.strip
10
+ move_p2 = ['R', 'P', 'S'].sample
11
+
12
+ puts %{You played #{move_p1} - I played #{move_p2}}
13
+
14
+ case "#{move_p1}#{move_p2}"
15
+ when 'RS', 'SP', 'PR' then puts %{You win!}
16
+ when 'RP', 'SR', 'PS' then puts %{You lose!}
17
+ when 'RR', 'SS', 'PP' then puts %{It’s a tie!}
18
+ end
19
+
20
+ puts %{Goodbye, and come back to the Game Hall}
21
+ end
22
+ end
data/tarzan.gemspec CHANGED
@@ -8,16 +8,16 @@ Gem::Specification.new do |spec|
8
8
  spec.version = Tarzan::VERSION
9
9
  spec.authors = ["claudiob"]
10
10
  spec.email = ["claudiob@gmail.com"]
11
- spec.description = %q{King of the Amazon}
12
- spec.summary = %q{AGHHHHEYEYAYAYAAAAAAR}
13
- spec.homepage = ""
11
+ spec.summary = %q{King of the Game Jungle.}
12
+ spec.description = %q{Step-by-step tutorial to modular games in Ruby}
13
+ spec.homepage = "https://github.com/claudiob/tarzan"
14
14
  spec.license = "MIT"
15
15
 
16
- spec.files = `git ls-files`.split($/)
16
+ spec.files = `git ls-files -z`.split("\x0")
17
17
  spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
18
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
19
  spec.require_paths = ["lib"]
20
20
 
21
- spec.add_development_dependency "bundler", "~> 1.3"
22
- spec.add_development_dependency "rake"
21
+ spec.add_development_dependency "bundler", "~> 1.5"
22
+ spec.add_development_dependency "rake", "~> 0"
23
23
  end
metadata CHANGED
@@ -1,59 +1,61 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tarzan
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - claudiob
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-12-17 00:00:00.000000000 Z
11
+ date: 2014-02-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.3'
19
+ version: '1.5'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ~>
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '1.3'
26
+ version: '1.5'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '>='
31
+ - - "~>"
32
32
  - !ruby/object:Gem::Version
33
33
  version: '0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '>='
38
+ - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
- description: King of the Amazon
41
+ description: Step-by-step tutorial to modular games in Ruby
42
42
  email:
43
43
  - claudiob@gmail.com
44
- executables: []
44
+ executables:
45
+ - tarzan
45
46
  extensions: []
46
47
  extra_rdoc_files: []
47
48
  files:
48
- - .gitignore
49
+ - ".gitignore"
49
50
  - Gemfile
50
51
  - LICENSE.txt
51
52
  - README.md
52
53
  - Rakefile
54
+ - bin/tarzan
53
55
  - lib/tarzan.rb
54
56
  - lib/tarzan/version.rb
55
57
  - tarzan.gemspec
56
- homepage: ''
58
+ homepage: https://github.com/claudiob/tarzan
57
59
  licenses:
58
60
  - MIT
59
61
  metadata: {}
@@ -63,18 +65,18 @@ require_paths:
63
65
  - lib
64
66
  required_ruby_version: !ruby/object:Gem::Requirement
65
67
  requirements:
66
- - - '>='
68
+ - - ">="
67
69
  - !ruby/object:Gem::Version
68
70
  version: '0'
69
71
  required_rubygems_version: !ruby/object:Gem::Requirement
70
72
  requirements:
71
- - - '>='
73
+ - - ">="
72
74
  - !ruby/object:Gem::Version
73
75
  version: '0'
74
76
  requirements: []
75
77
  rubyforge_project:
76
- rubygems_version: 2.1.10
78
+ rubygems_version: 2.2.0
77
79
  signing_key:
78
80
  specification_version: 4
79
- summary: AGHHHHEYEYAYAYAAAAAAR
81
+ summary: King of the Game Jungle.
80
82
  test_files: []