glimmer_klondike_solitaire 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (136) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE.txt +7 -0
  3. data/README.md +41 -0
  4. data/VERSION +1 -0
  5. data/app/glimmer_klondike_solitaire.rb +34 -0
  6. data/app/glimmer_klondike_solitaire/launch.rb +3 -0
  7. data/app/glimmer_klondike_solitaire/model/column_pile.rb +60 -0
  8. data/app/glimmer_klondike_solitaire/model/dealing_pile.rb +33 -0
  9. data/app/glimmer_klondike_solitaire/model/dealt_pile.rb +25 -0
  10. data/app/glimmer_klondike_solitaire/model/foundation_pile.rb +40 -0
  11. data/app/glimmer_klondike_solitaire/model/game.rb +37 -0
  12. data/app/glimmer_klondike_solitaire/model/playing_card.rb +50 -0
  13. data/app/glimmer_klondike_solitaire/view/action_panel.rb +34 -0
  14. data/app/glimmer_klondike_solitaire/view/app_view.rb +84 -0
  15. data/app/glimmer_klondike_solitaire/view/column_pile.rb +56 -0
  16. data/app/glimmer_klondike_solitaire/view/dealing_pile.rb +36 -0
  17. data/app/glimmer_klondike_solitaire/view/dealt_pile.rb +38 -0
  18. data/app/glimmer_klondike_solitaire/view/empty_playing_card.rb +45 -0
  19. data/app/glimmer_klondike_solitaire/view/foundation_pile.rb +59 -0
  20. data/app/glimmer_klondike_solitaire/view/hidden_playing_card.rb +23 -0
  21. data/app/glimmer_klondike_solitaire/view/playing_card.rb +23 -0
  22. data/app/glimmer_klondike_solitaire/view/tableau.rb +41 -0
  23. data/bin/glimmer_klondike_solitaire +13 -0
  24. data/config/warble.rb +183 -0
  25. data/images/glimmer-klondike-solitaire.png +0 -0
  26. data/images/original/10C.png +0 -0
  27. data/images/original/10D.png +0 -0
  28. data/images/original/10H.png +0 -0
  29. data/images/original/10S.png +0 -0
  30. data/images/original/11C.png +0 -0
  31. data/images/original/11D.png +0 -0
  32. data/images/original/11H.png +0 -0
  33. data/images/original/11S.png +0 -0
  34. data/images/original/12C.png +0 -0
  35. data/images/original/12D.png +0 -0
  36. data/images/original/12H.png +0 -0
  37. data/images/original/12S.png +0 -0
  38. data/images/original/13C.png +0 -0
  39. data/images/original/13D.png +0 -0
  40. data/images/original/13H.png +0 -0
  41. data/images/original/13S.png +0 -0
  42. data/images/original/1C.png +0 -0
  43. data/images/original/1D.png +0 -0
  44. data/images/original/1H.png +0 -0
  45. data/images/original/1S.png +0 -0
  46. data/images/original/2C.png +0 -0
  47. data/images/original/2D.png +0 -0
  48. data/images/original/2H.png +0 -0
  49. data/images/original/2S.png +0 -0
  50. data/images/original/3C.png +0 -0
  51. data/images/original/3D.png +0 -0
  52. data/images/original/3H.png +0 -0
  53. data/images/original/3S.png +0 -0
  54. data/images/original/4C.png +0 -0
  55. data/images/original/4D.png +0 -0
  56. data/images/original/4H.png +0 -0
  57. data/images/original/4S.png +0 -0
  58. data/images/original/5C.png +0 -0
  59. data/images/original/5D.png +0 -0
  60. data/images/original/5H.png +0 -0
  61. data/images/original/5S.png +0 -0
  62. data/images/original/6C.png +0 -0
  63. data/images/original/6D.png +0 -0
  64. data/images/original/6H.png +0 -0
  65. data/images/original/6S.png +0 -0
  66. data/images/original/7C.png +0 -0
  67. data/images/original/7D.png +0 -0
  68. data/images/original/7H.png +0 -0
  69. data/images/original/7S.png +0 -0
  70. data/images/original/8C.png +0 -0
  71. data/images/original/8D.png +0 -0
  72. data/images/original/8H.png +0 -0
  73. data/images/original/8S.png +0 -0
  74. data/images/original/9C.png +0 -0
  75. data/images/original/9D.png +0 -0
  76. data/images/original/9H.png +0 -0
  77. data/images/original/9S.png +0 -0
  78. data/images/original/BACK.png +0 -0
  79. data/images/resized/10C.png +0 -0
  80. data/images/resized/10D.png +0 -0
  81. data/images/resized/10H.png +0 -0
  82. data/images/resized/10S.png +0 -0
  83. data/images/resized/11C.png +0 -0
  84. data/images/resized/11D.png +0 -0
  85. data/images/resized/11H.png +0 -0
  86. data/images/resized/11S.png +0 -0
  87. data/images/resized/12C.png +0 -0
  88. data/images/resized/12D.png +0 -0
  89. data/images/resized/12H.png +0 -0
  90. data/images/resized/12S.png +0 -0
  91. data/images/resized/13C.png +0 -0
  92. data/images/resized/13D.png +0 -0
  93. data/images/resized/13H.png +0 -0
  94. data/images/resized/13S.png +0 -0
  95. data/images/resized/1C.png +0 -0
  96. data/images/resized/1D.png +0 -0
  97. data/images/resized/1H.png +0 -0
  98. data/images/resized/1S.png +0 -0
  99. data/images/resized/2C.png +0 -0
  100. data/images/resized/2D.png +0 -0
  101. data/images/resized/2H.png +0 -0
  102. data/images/resized/2S.png +0 -0
  103. data/images/resized/3C.png +0 -0
  104. data/images/resized/3D.png +0 -0
  105. data/images/resized/3H.png +0 -0
  106. data/images/resized/3S.png +0 -0
  107. data/images/resized/4C.png +0 -0
  108. data/images/resized/4D.png +0 -0
  109. data/images/resized/4H.png +0 -0
  110. data/images/resized/4S.png +0 -0
  111. data/images/resized/5C.png +0 -0
  112. data/images/resized/5D.png +0 -0
  113. data/images/resized/5H.png +0 -0
  114. data/images/resized/5S.png +0 -0
  115. data/images/resized/6C.png +0 -0
  116. data/images/resized/6D.png +0 -0
  117. data/images/resized/6H.png +0 -0
  118. data/images/resized/6S.png +0 -0
  119. data/images/resized/7C.png +0 -0
  120. data/images/resized/7D.png +0 -0
  121. data/images/resized/7H.png +0 -0
  122. data/images/resized/7S.png +0 -0
  123. data/images/resized/8C.png +0 -0
  124. data/images/resized/8D.png +0 -0
  125. data/images/resized/8H.png +0 -0
  126. data/images/resized/8S.png +0 -0
  127. data/images/resized/9C.png +0 -0
  128. data/images/resized/9D.png +0 -0
  129. data/images/resized/9H.png +0 -0
  130. data/images/resized/9S.png +0 -0
  131. data/images/resized/BACK.png +0 -0
  132. data/package/linux/Glimmer Klondike Solitaire.png +0 -0
  133. data/package/macosx/Glimmer Klondike Solitaire.icns +0 -0
  134. data/package/windows/Glimmer Klondike Solitaire.ico +0 -0
  135. data/vendor/jars/org/yaml/snakeyaml/1.28/snakeyaml-1.28.jar +0 -0
  136. metadata +251 -0
@@ -0,0 +1,56 @@
1
+ require 'glimmer_klondike_solitaire/model/column_pile'
2
+
3
+ require_relative 'playing_card'
4
+
5
+ class GlimmerKlondikeSolitaire
6
+ module View
7
+ class ColumnPile
8
+ include Glimmer::UI::CustomShape
9
+
10
+ options :pile_x, :pile_y, :model
11
+
12
+ after_body {
13
+ observe(model, 'playing_cards.last.hidden') do
14
+ build_column_pile(model.playing_cards)
15
+ end
16
+ build_column_pile(model.playing_cards)
17
+ }
18
+
19
+ body {
20
+ shape(pile_x, pile_y) {
21
+ on_drop do |drop_event|
22
+ begin
23
+ card_shape = drop_event.dragged_shape.get_data('custom_shape')
24
+ card = card_shape.model
25
+ model.add!(card)
26
+ card_parent_pile = card_shape.parent_pile
27
+ card_source_model = card_parent_pile.model
28
+ cards = card_source_model.remove!(card)
29
+ if cards.is_a?(Array) # if it is a column pile
30
+ cards[1..-1].each do |card|
31
+ model.add!(card)
32
+ end
33
+ end
34
+ drop_event.dragged_shape.dispose(dispose_images: false)
35
+ rescue => e
36
+ # pd e
37
+ drop_event.doit = false
38
+ end
39
+ end
40
+ }
41
+ }
42
+
43
+ def build_column_pile(playing_cards)
44
+ body_root.shapes.to_a.dup.each {|shape| shape.dispose(dispose_images: false)}
45
+ current_parent = body_root
46
+ playing_cards.each_with_index do |card, i|
47
+ current_parent.content {
48
+ current_parent = playing_card(card_x: 0, card_y: PLAYING_CARD_COLUMN_SPACING, model: card, parent_pile: self) {
49
+ drag_source true unless card.hidden?
50
+ }.body_root
51
+ }
52
+ end
53
+ end
54
+ end
55
+ end
56
+ end
@@ -0,0 +1,36 @@
1
+ require 'glimmer_klondike_solitaire/model/dealing_pile'
2
+
3
+ require_relative 'empty_playing_card'
4
+ require_relative 'hidden_playing_card'
5
+
6
+ class GlimmerKlondikeSolitaire
7
+ module View
8
+ class DealingPile
9
+ include Glimmer::UI::CustomShape
10
+
11
+ options :pile_x, :pile_y, :model
12
+
13
+ after_body {
14
+ observe(model, 'playing_cards.empty?') do |empty_value|
15
+ body_root.shapes.to_a.dup.each {|shape| shape.dispose(dispose_images: false)}
16
+ if empty_value
17
+ body_root.content {
18
+ empty_playing_card
19
+ }
20
+ else
21
+ body_root.content {
22
+ hidden_playing_card
23
+ }
24
+ end
25
+ end
26
+ }
27
+
28
+ body {
29
+ shape(pile_x, pile_y) {
30
+ hidden_playing_card
31
+ }
32
+ }
33
+
34
+ end
35
+ end
36
+ end
@@ -0,0 +1,38 @@
1
+ require 'glimmer_klondike_solitaire/model/dealt_pile'
2
+
3
+ require_relative 'empty_playing_card'
4
+ require_relative 'playing_card'
5
+
6
+ class GlimmerKlondikeSolitaire
7
+ module View
8
+ class DealtPile
9
+ include Glimmer::UI::CustomShape
10
+
11
+ options :pile_x, :pile_y, :model
12
+
13
+ after_body do
14
+ observe(model, 'playing_cards.empty?') do |empty_value|
15
+ if empty_value
16
+ body_root.shapes.to_a.dup.each {|shape| shape.dispose(dispose_images: false)}
17
+ body_root.content {
18
+ empty_playing_card
19
+ }
20
+ else
21
+ body_root.content {
22
+ playing_card(model: model.playing_cards.last, parent_pile: self) {
23
+ drag_source true
24
+ }
25
+ }
26
+ end
27
+ end
28
+ end
29
+
30
+ body {
31
+ shape(pile_x, pile_y) {
32
+ empty_playing_card
33
+ }
34
+ }
35
+
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,45 @@
1
+ class GlimmerKlondikeSolitaire
2
+ module View
3
+ class EmptyPlayingCard
4
+ include Glimmer::UI::CustomShape
5
+
6
+ options :card_x, :card_y, :suit
7
+
8
+ before_body {
9
+ self.card_x ||= 0
10
+ self.card_y ||= 0
11
+ }
12
+
13
+ body {
14
+ rectangle(card_x, card_y, PLAYING_CARD_WIDTH - 2, PLAYING_CARD_HEIGHT - 2, 15, 15) {
15
+ foreground :gray
16
+
17
+ if suit
18
+ text {
19
+ string suit_text(suit)
20
+ x :default
21
+ y :default
22
+ is_transparent true
23
+ foreground [:spades, :clubs].include?(suit) ? :black : rgb(206, 35, 21)
24
+ font height: 35
25
+ }
26
+ end
27
+ }
28
+ }
29
+
30
+ def suit_text(suit)
31
+ case suit
32
+ when :spades
33
+ "♤"
34
+ when :hearts
35
+ "♡"
36
+ when :clubs
37
+ "♧"
38
+ when :diamonds
39
+ "♢"
40
+ end
41
+ end
42
+
43
+ end
44
+ end
45
+ end
@@ -0,0 +1,59 @@
1
+ require 'glimmer_klondike_solitaire/model/playing_card'
2
+ require 'glimmer_klondike_solitaire/model/foundation_pile'
3
+
4
+ class GlimmerKlondikeSolitaire
5
+ module View
6
+ class FoundationPile
7
+ include Glimmer::UI::CustomShape
8
+
9
+ options :pile_x, :pile_y, :game, :suit
10
+
11
+ attr_accessor :current_image, :model
12
+
13
+ before_body {
14
+ self.current_image = image(PLAYING_CARD_WIDTH, PLAYING_CARD_HEIGHT) {empty_playing_card(suit: suit)}
15
+ self.model = game.foundation_piles[Model::PlayingCard::SUITS.index(suit)]
16
+ }
17
+
18
+ after_body {
19
+ observe(model, 'playing_cards.last') do |last_card|
20
+ if last_card
21
+ body_root.content {
22
+ playing_card(model: last_card)
23
+ }
24
+ else
25
+ body_root.shapes.to_a.dup.each {|shape| shape.dispose(dispose_images: false)}
26
+ body_root.content {
27
+ empty_playing_card(suit: suit)
28
+ }
29
+ end
30
+ end
31
+ }
32
+
33
+ body {
34
+ shape(pile_x, pile_y) {
35
+ empty_playing_card(suit: suit)
36
+
37
+ on_drop do |drop_event|
38
+ begin
39
+ # TODO make sure one cannot drag a column pile of cards here
40
+ card_shape = drop_event.dragged_shape.get_data('custom_shape')
41
+ card = card_shape.model
42
+ card_parent_pile = card_shape.parent_pile
43
+ card_source_model = card_parent_pile.model
44
+ raise 'Cannot accept multiple cards' if card_source_model.playing_cards.index(card) != (card_source_model.playing_cards.size - 1)
45
+ model.add!(card)
46
+ card_source_model.remove!(card)
47
+ drop_event.dragged_shape.dispose(dispose_images: false)
48
+ rescue => e
49
+ # pd e
50
+ drop_event.doit = false
51
+ end
52
+ end
53
+ }
54
+ }
55
+ end
56
+
57
+ end
58
+
59
+ end
@@ -0,0 +1,23 @@
1
+ class GlimmerKlondikeSolitaire
2
+ module View
3
+ class HiddenPlayingCard
4
+ include Glimmer::UI::CustomShape
5
+
6
+ options :card_x, :card_y
7
+
8
+ before_body {
9
+ self.card_x ||= 0
10
+ self.card_y ||= 0
11
+ }
12
+
13
+ body {
14
+ image {
15
+ image IMAGE_BACK
16
+ x card_x
17
+ y card_y
18
+ }
19
+ }
20
+
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,23 @@
1
+ class GlimmerKlondikeSolitaire
2
+ module View
3
+ class PlayingCard
4
+ include Glimmer::UI::CustomShape
5
+
6
+ options :card_x, :card_y, :model, :parent_pile
7
+
8
+ before_body {
9
+ self.card_x ||= 0
10
+ self.card_y ||= 0
11
+ }
12
+
13
+ body {
14
+ image {
15
+ image model.hidden ? IMAGE_BACK : IMAGES[model.suit][model.rank]
16
+ x card_x
17
+ y card_y
18
+ }
19
+ }
20
+
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,41 @@
1
+ require_relative 'dealing_pile'
2
+ require_relative 'dealt_pile'
3
+ require_relative 'column_pile'
4
+ require_relative 'foundation_pile'
5
+
6
+ require 'glimmer_klondike_solitaire/model/game'
7
+
8
+ class GlimmerKlondikeSolitaire
9
+ module View
10
+ class Tableau
11
+ include Glimmer::UI::CustomWidget
12
+
13
+ option :game
14
+
15
+ body {
16
+ canvas {
17
+ background :dark_green
18
+
19
+ # row 1
20
+ @foundation_piles = Model::PlayingCard::SUITS.each_with_index.map do |suit, i|
21
+ foundation_pile(pile_x: PLAYING_CARD_MARGIN + i*(PLAYING_CARD_WIDTH + PLAYING_CARD_SPACING), pile_y: 0, game: game, suit: suit)
22
+ end
23
+ @dealt_pile = dealt_pile(pile_x: PLAYING_CARD_MARGIN + 5*(PLAYING_CARD_WIDTH + PLAYING_CARD_SPACING), pile_y: 0, model: game.dealt_pile)
24
+ @dealing_pile = dealing_pile(pile_x: PLAYING_CARD_MARGIN + 6*(PLAYING_CARD_WIDTH + PLAYING_CARD_SPACING), pile_y: 0, model: game.dealing_pile)
25
+
26
+ # row 2
27
+ @column_piles = 7.times.map do |n|
28
+ column_pile(pile_x: PLAYING_CARD_MARGIN + n*(PLAYING_CARD_WIDTH + PLAYING_CARD_SPACING), pile_y: PLAYING_CARD_HEIGHT - 4*PLAYING_CARD_SPACING, model: game.column_piles[n])
29
+ end
30
+
31
+ on_mouse_up do |event|
32
+ if @dealing_pile.body_root.include?(event.x, event.y)
33
+ game.dealing_pile.deal!
34
+ end
35
+ end
36
+ }
37
+ }
38
+
39
+ end
40
+ end
41
+ end
@@ -0,0 +1,13 @@
1
+ #!/usr/bin/env jruby
2
+
3
+ runner = File.expand_path('../../app/glimmer_klondike_solitaire/launch.rb', __FILE__)
4
+
5
+ # Detect if inside a JAR file or not
6
+ if runner.include?('uri:classloader')
7
+ require runner
8
+ else
9
+ require 'glimmer/launcher'
10
+
11
+ launcher = Glimmer::Launcher.new([runner] + ARGV)
12
+ launcher.launch
13
+ end
data/config/warble.rb ADDED
@@ -0,0 +1,183 @@
1
+
2
+ # Disable Rake-environment-task framework detection by uncommenting/setting to false
3
+ # Warbler.framework_detection = false
4
+
5
+ # Warbler web application assembly configuration file
6
+ Warbler::Config.new do |config|
7
+ # Features: additional options controlling how the jar is built.
8
+ # Currently the following features are supported:
9
+ # - *gemjar*: package the gem repository in a jar file in WEB-INF/lib
10
+ # - *executable*: embed a web server and make the war executable
11
+ # - *runnable*: allows to run bin scripts e.g. `java -jar my.war -S rake -T`
12
+ # - *compiled*: compile .rb files to .class files
13
+ # config.features = %w(gemjar)
14
+
15
+ # Application directories to be included in the webapp.
16
+ config.dirs = %w(app bin config db docs fonts icons images lib package script sounds vendor videos)
17
+
18
+ # Additional files/directories to include, above those in config.dirs
19
+ config.includes = FileList['LICENSE.txt', 'VERSION']
20
+
21
+ # Additional files/directories to exclude
22
+ # config.excludes = FileList["lib/tasks/*"]
23
+
24
+ # Additional Java .jar files to include. Note that if .jar files are placed
25
+ # in lib (and not otherwise excluded) then they need not be mentioned here.
26
+ # JRuby and JRuby-Rack are pre-loaded in this list. Be sure to include your
27
+ # own versions if you directly set the value
28
+ # config.java_libs += FileList["lib/java/*.jar"]
29
+
30
+ # Loose Java classes and miscellaneous files to be included.
31
+ # config.java_classes = FileList["target/classes/**.*"]
32
+
33
+ # One or more pathmaps defining how the java classes should be copied into
34
+ # the archive. The example pathmap below accompanies the java_classes
35
+ # configuration above. See http://rake.rubyforge.org/classes/String.html#M000017
36
+ # for details of how to specify a pathmap.
37
+ # config.pathmaps.java_classes << "%{target/classes/,}p"
38
+
39
+ # Bundler support is built-in. If Warbler finds a Gemfile in the
40
+ # project directory, it will be used to collect the gems to bundle
41
+ # in your application. If you wish to explicitly disable this
42
+ # functionality, uncomment here.
43
+ # config.bundler = false
44
+
45
+ # An array of Bundler groups to avoid including in the war file.
46
+ # Defaults to ["development", "test", "assets"].
47
+ # config.bundle_without = []
48
+
49
+ # Other gems to be included. If you don't use Bundler or a gemspec
50
+ # file, you need to tell Warbler which gems your application needs
51
+ # so that they can be packaged in the archive.
52
+ # For Rails applications, the Rails gems are included by default
53
+ # unless the vendor/rails directory is present.
54
+ # config.gems += ["activerecord-jdbcmysql-adapter", "jruby-openssl"]
55
+ # config.gems << "tzinfo"
56
+
57
+ # Uncomment this if you don't want to package rails gem.
58
+ # config.gems -= ["rails"]
59
+
60
+ # The most recent versions of gems are used.
61
+ # You can specify versions of gems by using a hash assignment:
62
+ # config.gems["rails"] = "4.2.5"
63
+
64
+ # You can also use regexps or Gem::Dependency objects for flexibility or
65
+ # finer-grained control.
66
+ # config.gems << /^sinatra-/
67
+ # config.gems << Gem::Dependency.new("sinatra", "= 1.4.7")
68
+
69
+ # Include gem dependencies not mentioned specifically. Default is
70
+ # true, uncomment to turn off.
71
+ # config.gem_dependencies = false
72
+
73
+ # Array of regular expressions matching relative paths in gems to be
74
+ # excluded from the war. Defaults to empty, but you can set it like
75
+ # below, which excludes test files.
76
+ # config.gem_excludes = [/^(test|spec)\//]
77
+
78
+ # Pathmaps for controlling how application files are copied into the archive
79
+ # config.pathmaps.application = ["WEB-INF/%p"]
80
+
81
+ # Name of the archive (without the extension). Defaults to the basename
82
+ # of the project directory.
83
+ # config.jar_name = "mywar"
84
+
85
+ # File extension for the archive. Defaults to either 'jar' or 'war'.
86
+ # config.jar_extension = "jar"
87
+
88
+ # Destionation for the created archive. Defaults to project's root directory.
89
+ config.autodeploy_dir = "dist/"
90
+
91
+ # Name of the MANIFEST.MF template for the war file. Defaults to a simple
92
+ # MANIFEST.MF that contains the version of Warbler used to create the war file.
93
+ # config.manifest_file = "config/MANIFEST.MF"
94
+
95
+ # When using the 'compiled' feature and specified, only these Ruby
96
+ # files will be compiled. Default is to compile all \.rb files in
97
+ # the application.
98
+ # config.compiled_ruby_files = FileList['app/**/*.rb']
99
+
100
+ # Determines if ruby files in supporting gems will be compiled.
101
+ # Ignored unless compile feature is used.
102
+ # config.compile_gems = false
103
+
104
+ # When set it specify the bytecode version for compiled class files
105
+ # config.bytecode_version = "1.6"
106
+
107
+ # When set to true, Warbler will override the value of ENV['GEM_HOME'] even it
108
+ # has already been set. When set to false it will use any existing value of
109
+ # GEM_HOME if it is set.
110
+ # config.override_gem_home = true
111
+
112
+ # Allows for specifing custom executables
113
+ # config.executable = ["rake", "bin/rake"]
114
+
115
+ # Sets default (prefixed) parameters for the executables
116
+ # config.executable_params = "do:something"
117
+
118
+ # If set to true, moves jar files into WEB-INF/lib. Prior to version 1.4.2 of Warbler this was done
119
+ # by default. But since 1.4.2 this config defaults to false. It may need to be set to true for
120
+ # web servers that do not explode the WAR file.
121
+ # Alternatively, this option can be set to a regular expression, which will
122
+ # act as a jar selector -- only jar files that match the pattern will be
123
+ # included in the archive.
124
+ # config.move_jars_to_webinf_lib = false
125
+
126
+ # === War files only below here ===
127
+
128
+ # Embedded webserver to use with the 'executable' feature. Currently supported
129
+ # webservers are:
130
+ # - *jetty* - Embedded Jetty from Eclipse
131
+ # config.webserver = 'jetty'
132
+
133
+ # Path to the pre-bundled gem directory inside the war file. Default
134
+ # is 'WEB-INF/gems'. Specify path if gems are already bundled
135
+ # before running Warbler. This also sets 'gem.path' inside web.xml.
136
+ # config.gem_path = "WEB-INF/vendor/bundler_gems"
137
+
138
+ # Files for WEB-INF directory (next to web.xml). This contains
139
+ # web.xml by default. If there is an .erb-File it will be processed
140
+ # with webxml-config. You may want to exclude this file via
141
+ # config.excludes.
142
+ # config.webinf_files += FileList["jboss-web.xml"]
143
+
144
+ # Files to be included in the root of the webapp. Note that files in public
145
+ # will have the leading 'public/' part of the path stripped during staging.
146
+ # config.public_html = FileList["public/**/*", "doc/**/*"]
147
+
148
+ # Pathmaps for controlling how public HTML files are copied into the .war
149
+ # config.pathmaps.public_html = ["%{public/,}p"]
150
+
151
+ # Value of RAILS_ENV for the webapp -- default as shown below
152
+ # config.webxml.rails.env = ENV['RAILS_ENV'] || 'production'
153
+
154
+ # Public ROOT mapping, by default assets are copied into .war ROOT directory.
155
+ # config.public.root = ''
156
+
157
+ # Application booter to use, either :rack or :rails (autodetected by default)
158
+ # config.webxml.booter = :rails
159
+
160
+ # When using the :rack booter, "Rackup" script to use.
161
+ # - For 'rackup.path', the value points to the location of the rackup
162
+ # script in the web archive file. You need to make sure this file
163
+ # gets included in the war, possibly by adding it to config.includes
164
+ # or config.webinf_files above.
165
+ # - For 'rackup', the rackup script you provide as an inline string
166
+ # is simply embedded in web.xml.
167
+ # The script is evaluated in a Rack::Builder to load the application.
168
+ # Examples:
169
+ # config.webxml.rackup.path = 'WEB-INF/hello.ru'
170
+ # config.webxml.rackup = %{require './lib/demo'; run Rack::Adapter::Camping.new(Demo)}
171
+ # config.webxml.rackup = require 'cgi' && CGI::escapeHTML(File.read("config.ru"))
172
+
173
+ # Control the pool of Rails runtimes. Leaving unspecified means
174
+ # the pool will grow as needed to service requests. It is recommended
175
+ # that you fix these values when running a production server!
176
+ # If you're using threadsafe! mode, you probably don't want to set these values,
177
+ # since 1 runtime(default for threadsafe mode) will be enough.
178
+ # config.webxml.jruby.min.runtimes = 2
179
+ # config.webxml.jruby.max.runtimes = 4
180
+
181
+ # JNDI data source name
182
+ # config.webxml.jndi = 'jdbc/rails'
183
+ end