[Logilogi-svn] SF.net SVN: logilogi: [252] trunk
Status: Beta
Brought to you by:
wybow
|
From: <wy...@us...> - 2007-03-18 12:25:15
|
Revision: 252
http://logilogi.svn.sourceforge.net/logilogi/?rev=252&view=rev
Author: wybow
Date: 2007-03-16 15:49:27 -0700 (Fri, 16 Mar 2007)
Log Message:
-----------
Fixed bug in homepage if all is ok (added neutral to scores in
rating), also added snapshot-generation rake task. A second commit
will follow if this one is successfull to remove diagnostic puts's
from the task_helper in lib.
Modified Paths:
--------------
trunk/app/controllers/account_controller.rb
trunk/app/models/rating.rb
trunk/config/boot.rb
trunk/config/environment.rb
trunk/config/environments/development.rb
trunk/config/environments/production.rb
trunk/config/environments/test.rb
trunk/doc/README_FOR_APP
trunk/doc/diagram.png
trunk/lib/task_helper.rb
trunk/lib/tasks/do_check_commit.rake
Added Paths:
-----------
trunk/lib/tasks/do_build_snapshot.rake
Modified: trunk/app/controllers/account_controller.rb
===================================================================
--- trunk/app/controllers/account_controller.rb 2007-03-16 12:29:49 UTC (rev 251)
+++ trunk/app/controllers/account_controller.rb 2007-03-16 22:49:27 UTC (rev 252)
@@ -15,13 +15,8 @@
require "pathname"
require "cgi"
-# load the openid library
-begin
- require "rubygems"
- require_gem "ruby-openid", ">= 1.0.2"
-rescue LoadError
- require "openid"
-end
+gem "ruby-openid"
+require "openid"
class AccountController < ApplicationController
layout 'main'
Modified: trunk/app/models/rating.rb
===================================================================
--- trunk/app/models/rating.rb 2007-03-16 12:29:49 UTC (rev 251)
+++ trunk/app/models/rating.rb 2007-03-16 22:49:27 UTC (rev 252)
@@ -35,6 +35,7 @@
SCORES = {
-2 => 'horrible',
-1 => 'bad',
+ 0 => 'neutral',
1 => 'sufficient',
2 => 'fair',
3 => 'ok',
Modified: trunk/config/boot.rb
===================================================================
--- trunk/config/boot.rb 2007-03-16 12:29:49 UTC (rev 251)
+++ trunk/config/boot.rb 2007-03-16 22:49:27 UTC (rev 252)
@@ -42,4 +42,4 @@
end
Rails::Initializer.run(:set_load_path)
-end
\ No newline at end of file
+end
Modified: trunk/config/environment.rb
===================================================================
--- trunk/config/environment.rb 2007-03-16 12:29:49 UTC (rev 251)
+++ trunk/config/environment.rb 2007-03-16 22:49:27 UTC (rev 252)
@@ -7,9 +7,12 @@
# Bootstrap the Rails environment, frameworks, and default configuration
require File.join(File.dirname(__FILE__), 'boot')
-require_gem 'tzinfo'
-require_gem 'RedCloth'
-require_gem 'rubyzip'
+require 'rubygems'
+gem 'tzinfo'
+require 'tzinfo'
+gem 'RedCloth'
+require 'redcloth'
+gem 'rubyzip'
require 'zip/zip'
module InitialGlobalConfig
@@ -285,7 +288,6 @@
# (they will stay in the source for the svn version for now)
config.load_paths += %W(
#{RAILS_ROOT}/lib/error
- #{RAILS_ROOT}/lib/extensions
#{RAILS_ROOT}/lib/language
#{RAILS_ROOT}/lib/location
#{RAILS_ROOT}/lib/modules
@@ -319,7 +321,10 @@
# Loads all monkey-patches.
#
-require 'extensions'
+# Put here instead of above inside the Initializer to prevent problems
+# with freezing rails.
+#
+require 'lib/extensions'
# Override with development- & test-configuration.
Modified: trunk/config/environments/development.rb
===================================================================
--- trunk/config/environments/development.rb 2007-03-16 12:29:49 UTC (rev 251)
+++ trunk/config/environments/development.rb 2007-03-16 22:49:27 UTC (rev 252)
@@ -3,10 +3,10 @@
# In the development environment your application's code is reloaded on
# every request. This slows down response time but is perfect for development
# since you don't have to restart the webserver when you make code changes.
-config.cache_classes = false
+config.cache_classes = false
# Log error messages when you accidentally call methods on nil.
-config.whiny_nils = true
+config.whiny_nils = true
# Enable the breakpoint server that script/breakpointer connects to
config.breakpoint_server = true
@@ -14,8 +14,8 @@
# Show full error reports and disable caching
config.action_controller.consider_all_requests_local = true
config.action_controller.perform_caching = false
+config.action_view.cache_template_extensions = false
+config.action_view.debug_rjs = true
# Don't care if the mailer can't send
config.action_mailer.raise_delivery_errors = false
-
-config.action_view.debug_rjs = true
Modified: trunk/config/environments/production.rb
===================================================================
--- trunk/config/environments/production.rb 2007-03-16 12:29:49 UTC (rev 251)
+++ trunk/config/environments/production.rb 2007-03-16 22:49:27 UTC (rev 252)
@@ -5,9 +5,8 @@
config.cache_classes = true
# Use a different logger for distributed setups
-# config.logger = SyslogLogger.new
+# config.logger = SyslogLogger.new
-
# Full error reports are disabled and caching is turned on
config.action_controller.consider_all_requests_local = false
config.action_controller.perform_caching = true
@@ -15,5 +14,5 @@
# Enable serving of images, stylesheets, and javascripts from an asset server
# config.action_controller.asset_host = "http://assets.example.com"
-# Disable delivery errors if you bad email addresses should just be ignored
+# Disable delivery errors, bad email addresses will be ignored
# config.action_mailer.raise_delivery_errors = false
Modified: trunk/config/environments/test.rb
===================================================================
--- trunk/config/environments/test.rb 2007-03-16 12:29:49 UTC (rev 251)
+++ trunk/config/environments/test.rb 2007-03-16 22:49:27 UTC (rev 252)
@@ -7,7 +7,7 @@
config.cache_classes = true
# Log error messages when you accidentally call methods on nil.
-config.whiny_nils = true
+config.whiny_nils = true
# Show full error reports and disable caching
config.action_controller.consider_all_requests_local = true
@@ -16,4 +16,4 @@
# Tell ActionMailer not to deliver emails to the real world.
# The :test delivery method accumulates sent emails in the
# ActionMailer::Base.deliveries array.
-config.action_mailer.delivery_method = :test
+config.action_mailer.delivery_method = :test
\ No newline at end of file
Modified: trunk/doc/README_FOR_APP
===================================================================
--- trunk/doc/README_FOR_APP 2007-03-16 12:29:49 UTC (rev 251)
+++ trunk/doc/README_FOR_APP 2007-03-16 22:49:27 UTC (rev 252)
@@ -34,11 +34,38 @@
=== Step 1: Getting it
-You can get the code from our
+First install the stable ruby version (1.8.2 or 1.8.4), and mysql. If you
+are using Ubuntu or Debian as your OS see the notes at the bottom.
+
+There are two ways to install Manta itself:
+* Developer snapshots - one single archive that contains most
+ dependencies, also handy in case the server(s) from which to get
+ a dependency is temporally down.
+* Normal subversion installation - laborous, conventional and flexible
+
+(Note that LogiLogi Manta is still in pre-alpha state, and thus we
+have no user-releases yet)
+
+==== Way a: Developer snapshots
+
+Download the most recent snapshot from
+{here}[http://www.logilogi.org/pub/mantasnapshots/logilogi-trunk.tgz]. This
+contains Manta, Ruby on Rails, and all gems and plugins that Manta needs
+in one convenient directory-tree that you can use as non-root.
+
+This snapshot contains a subversion checkout, and you can update it
+normally by issuing svn update inside the project dir after you
+unpacked it to make sure you are using the newest version.
+
+Note that this snapshot does not contain the ferret gem, because it
+requires the compilation of C++ code. But manta works well without
+it as long as you don't visit the search page.
+
+=== Way b: Normal subversion installation
+
+You can also get Manta directly from our
{Subversion repository}[http://sourceforge.net/svn/?group_id=78643]
-If you are using Ubuntu or Debian as your OS see the notes at the bottom.
-
LogiLogi Manta requires Rails[http://www.rubyonrails.org]
and the tzinfo[http://tzinfo.rubyforge.org],
daemons[http://svn.kylemaxwell.com/rails_plugins/daemon_generator],
@@ -54,7 +81,8 @@
=== Step 2: Configuring it
Copy the template database.yml.tmpl in the config dir to
-database.yml, and add your database-username and -password.
+database.yml, and add your database-username and -password. This is
+only needed if you did set a root-password for your database.
To initialize the database you should run rake do_dev_db (or rake
redo_dev_db if you download a new version).
@@ -64,18 +92,16 @@
0.0.0.0 www.logi-manta.org en.logi-manta.org de.logi-manta.org
-To show the GoogleMaps you need to get Google API keys and set them in
-gmaps_api_key.yml (rename from template).
+If you use a different name in your hosts file you need to get Google
+API keys yourself and set them in gmaps_api_key.yml (rename from
+template) for correctly showing the maps.
-=== Step 3: Enjoying it
+=== Step N3: Enjoying it
Then you can point your browser to www.logi-manta.org:3000/
You're all set.
-Note however that LogiLogi Manta is not fully functional yet, it's
-currently for developers only.
-
=== Installation Notes
If you are on Ubuntu you need to install the following packages to get
Modified: trunk/doc/diagram.png
===================================================================
(Binary files differ)
Modified: trunk/lib/task_helper.rb
===================================================================
--- trunk/lib/task_helper.rb 2007-03-16 12:29:49 UTC (rev 251)
+++ trunk/lib/task_helper.rb 2007-03-16 22:49:27 UTC (rev 252)
@@ -21,18 +21,18 @@
output = `#{shell_line}`
process = $?
if process.exitstatus != 0
- puts output
-# ErrorNotifier.deliver_failure(output, task)
+ ErrorNotifier.deliver_failure(output, task)
break
end
end
# Methods
def failure(error, task)
+ puts 'error: ' + error.inspect + ' ' + task
@subject = "#{task} broken"
@body = error
- @recipients = 'log...@li...'
- @from = 'ad...@lo...'
- @sent_on = Time.now
+# @recipients = 'log...@li...'
+# @from = 'ad...@lo...'
+# @sent_on = Time.now
end
end
Added: trunk/lib/tasks/do_build_snapshot.rake
===================================================================
--- trunk/lib/tasks/do_build_snapshot.rake (rev 0)
+++ trunk/lib/tasks/do_build_snapshot.rake 2007-03-16 22:49:27 UTC (rev 252)
@@ -0,0 +1,24 @@
+task :do_build_snapshot do
+ require File.join(File.dirname(__FILE__), '../task_helper.rb')
+
+ branch = 'trunk'
+
+ pre_runs = ["cd /tmp; svn co https://svn.sourceforge.net/svnroot/logilogi/#{branch} logilogi",
+ "cp -f config/database.yml.tmpl /tmp/logilogi/config/database.yml",
+ "cp -f config/gmaps_api_key.yml.tmpl /tmp/logilogi/config/gmaps_api_key.yml",
+ "cd /tmp/logilogi; rake rails:freeze:gems"
+ ]
+ pre_runs.each do |run|
+ ErrorNotifier.run_and_report_if_erred(run, 'Snapshot')
+ end
+
+ requirements = ['RedCloth','ruby-openid','rubyzip','tzinfo', 'daemons']
+ requirements.each do |req_gem|
+ ErrorNotifier.run_and_report_if_erred("cd /tmp/logilogi; rake gems:freeze GEM=#{req_gem}", 'Snapshot gem freezing')
+ end
+
+ post_runs = ["cd /tmp; tar -czvf logilogi-#{branch}.tgz logilogi"]
+ post_runs.each do |run|
+ ErrorNotifier.run_and_report_if_erred(run, 'Snapshot packaging')
+ end
+end
Modified: trunk/lib/tasks/do_check_commit.rake
===================================================================
--- trunk/lib/tasks/do_check_commit.rake 2007-03-16 12:29:49 UTC (rev 251)
+++ trunk/lib/tasks/do_check_commit.rake 2007-03-16 22:49:27 UTC (rev 252)
@@ -2,8 +2,8 @@
require File.join(File.dirname(__FILE__), '../task_helper.rb')
runs = [
"cd /tmp; svn co https://svn.sourceforge.net/svnroot/logilogi/trunk logilogi-test",
- "cp -f config/database.yml /tmp/logilogi-test/config/database.yml.tmpl",
- "cp -f config/gmaps_api_key.yml /tmp/logilogi-test/config/gmaps_api_key.yml.tmpl",
+ "cp -f config/database.yml.tmpl /tmp/logilogi-test/config/database.yml",
+ "cp -f config/gmaps_api_key.yml.tmpl /tmp/logilogi-test/config/gmaps_api_key.yml",
"cd /tmp/logilogi-test; rake test:units"]
runs.each do |run|
ErrorNotifier.run_and_report_if_erred(run, 'Build')
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|