Commits

Sean Wilkinson committed 8ad72df

Better integration with Bundler for the Rack app

  • Participants
  • Parent commits 3753984

Comments (0)

Files changed (2)

             $(RM) $(BUILD_DIR)/rackup-app/                              ;   \
             $(RM) $(BUILD_DIR)/ruby-gem/                                ;   \
             $(RM) $(BUILD_DIR)/web-service/                             ;   \
+            if [ ! "$$($(LS) -A $(BUILD_DIR))" ]; then                      \
+                $(RM) $(BUILD_DIR)                                      ;   \
+            fi                                                          ;   \
             $(RM) $(VAR_DIR)
 
 clobber: clean
             $(CD) $(BUILD_DIR)                                          ;   \
             $(CP) browser-client rackup-app/public                      ;   \
             $(CD) rackup-app                                            ;   \
-            $(BUNDLE) exec rackup -s thin
+            $(BUNDLE) package                                           ;   \
+            $(BUNDLE) exec rackup
 
 ruby-gem: $(BUILD_DIR)/ruby-gem/README.md
 	@   $(CD) $(BUILD_DIR)/ruby-gem/                                ;   \

src/rackup-app/config.ru

 #                                                       ~~ (c) SRW, 24 Apr 2013
 #                                                   ~~ last updated 25 Apr 2013
 
-require 'json'
-require 'sqlite3'
-require 'sinatra'
+require 'rubygems'
+require 'bundler'
+
+Bundler.require
 
 configure do
     set :show_exceptions, false