Are you on MS Windows?
El miércoles, 5 de agosto de 2015, 1:06:35 (UTC-4:30), venkata sai Reddy
escribió:
caught RestClient::SSLCertificateNotVerified: SSL_connect returned=1
errno=0 state=SSLv3 read server certificate B: certificate verify failed:
--
You received this message because
, it works.
Is accepts_nested_attributes_for missing the role option from
attr_accessible?
---
Kristian Rasmussen
@iamkristian | iamkristian.com
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group.
To post to this group, send email
::Template.
The #render method takes arguments view and a locals, which I think is
a Hash.
Is this what I should be aiming to use? Any examples of this kind of
usage outside Rails?
Kristian
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group
I found the file 'actionpack/template/template_test.rb', which shows
how to run simple templates:
def test_basic_template
@template = new_template
assert_equal Hello, render
end
def test_locals
@template = new_template(%= my_local %)
assert_equal I'm a local,
After a lot of experimentation and reverse engineering the Rails 3
ActionView code, I figured out this solution: http://gist.github.com/549965
Hope it can help others with a similar need ;)
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group.
I have been thinking that there must be some better ways of doing
Rails plugin development than my current approach. currently I tend to
have my plugin in one location as a gem and then link to it from my
Rails 3 app vendor plugins folder with a symlink. Then I have to carry
around the whole Rails
I have been thinking that there must be some better ways of doing
Rails plugin development than my current approach. currently I tend to
have my plugin in one location as a gem and then link to it from my
Rails 3 app vendor plugins folder with a symlink. Then I have to carry
around the whole Rails
I have recently upgraqded to Ruby 1.9.2-rc1 and reinstalled rails 3
beta 4 with all the dependencies. I have run bundle install in my
rails project. Now I am trying to run some tests...
My test_helper.rb file looks like this:
# test_helper.rb
require 'rubygems'
require 'test/unit'
require
rodrigo3n wrote:
Hello Hiroshi, just as I did, you can fix this problem by uncommenting
the line 6 of your application's Gemfile. It worked for Ruby
1.9.1p378. It remains buggy on 1.9.2.
Thanks.
What is line 6 in the Gemfile?
Is it a particular gem that causes the problem?
--
Posted via
I suddenly have a major problem in all my Rails 3 apps:
$ rake db:migrate --trace
rake aborted!
Don't know how to build task 'db:migrate'
/Users/kristianconsult/.rvm/gems/ruby-1.9.1-p378/gems/rake-0.8.7/lib/
rake.rb:1728:in `[]'
kristian-mandrups-macbook-pro:edgier kristianconsult$ rake db:migrate
(in /Users/kristianconsult/my_rails/rails3_apps/edgier)
WARNING: #NoMethodError: undefined method `' for nil:NilClass
# -*- encoding: utf-8 -*-
Gem::Specification.new do |s|
s.name = %q{abstract}
...
WARNING: Invalid
Found the bug and solution here:
https://rails.lighthouseapp.com/projects/8994/tickets/3865-invalid-gemspec-format-in-and-already-initialized-constant-warnings-with-ruby-192dev
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group.
To post to
In the root of a rails 3 app:
$ rails
env: ruby1.9: No such file or directory
$ script/rails
env: ruby1.9: No such file or directory
$ script/rails generate
env: ruby1.9: No such file or directory
$ ruby -v
ruby 1.9.1p378 (2010-01-10 revision 26273) [i386-darwin10.2.0]
$ mate script/rails
on underneath and how it all
connects. There are also the :in and :as options for hook_for. How are
they used?
There is also rules for how the hooks are resolved
Thanks for any info ;)
Kristian
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk
Installing ffi (0.5.4) from rubygems repository at http://gemcutter.org
with native extensions /usr/local/Cellar/ruby/1.9.1-p378/lib/ruby/
site_ruby/1.9.1/rubygems/installer.rb:504:in `rescue in block in
build_extensions': ERROR: Failed to build gem native extension.
Been working a bit lately on implementing Rails app. templates and
generators. It is clear there is a lot of overlap and that features
from generators could be used in app. templates and vice versa.
I will try to port some of the generator features such as the template
function (executing an .erb
(schemaless
DB). I have created a few generators to facilitate this kind of
approach...
Good luck!
Kristian
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group.
To post to this group, send email to rubyonrails-t...@googlegroups.com.
To unsubscribe from
There are several blog posts on how to use jQuery unobtrusively with
Rails. Yeah, don't use the js helpers and RJS if you can avoid it!
I'm currently in the process of creating a jQuery application template
to install/configure jQuery widgets, jQuery UI and unobtrusive jQuery
in a Rails app.
Check
kristian-mandrups-macbook-pro:~ kristianconsult$
nifty_app_template_local tryme blip
create
create README
...
create app
create app/controllers/application_controller.rb
create app/helpers/application_helper.rb
create tmp/pids
create
http://www.gotripod.com/2007/10/07/tip-running-command-line-shell-commands-in-ruby-using-x/
Try this instead:
f.each_line do |page|
%x[script/generate controller #{page}]
end
file.close
;)
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk
I remember having stumbled upon a tutorial or blog, describing how to
mount multiple web apps in a single rails/rack application.
Does anyone have any idea where I can find info on how to do this?
Thanks!
--
You received this message because you are subscribed to the Google Groups Ruby
on
Could not find README in source paths.
module Nifty
module Generators
class AppGenerator Base
def self.source_root
@source_root ||= File.expand_path(File.join(File.dirname
(__FILE__), 'templates'))
end
def initialize(*args)
super
end
def
Works with this in my Rakefile :)
gem.files=FileList['lib/**/*', 'bin/*']
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group.
To post to this group, send email to rubyonrails-t...@googlegroups.com.
To unsubscribe from this group, send
be possible with migrations.
Also see: http://guides.rails.info/generators.html for more details ;)
Good luck!
Kristian
On Jan 29, 9:54 pm, szimek szi...@gmail.com wrote:
Hi,
I'd like to add Rails 3 compatible generator to acts_as_taggable_on
gem (all it does is call migration_template method
the executable passing in any defined arguments as per the
generator
Commens, ideas, suggestions?
Thanks!
Kristian
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group.
To post to this group, send email to rubyonrails-t...@googlegroups.com
'
--
Is there a nice way to fix this? Do I have to create a non-frozen
custom options collection or someone has a better idea?
Kristian
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group.
To post to this group, send email to rubyonrails-t
simply do, somewhere in your controller:
local_addresses.clear
Tried this?
/Kristian
2010/1/24 Craig White craigwh...@azapple.com:
I don't seem to be happening here...
config/environments/development.rb set...
config.action_controller.consider_all_requests_local = false
Check http://recaptcha.net/
2010/1/25 Tom Mac li...@ruby-forum.com:
Hi
I would like to know which is the latest captcha gem or plugin in
rails. I need to implement one in my registration page Is there any
screencasts available for the same
Thanks in advance
Tom
--
Posted via
Do you really need the flexible and dynamic scheme of option 2?
As long as you only have a few settings I would stick to option 1. You
can always migrate your data and move to scheme 2 if required.
/K
2010/1/25 Matt Jones al2o...@gmail.com:
On Jan 25, 1:28 am, Taylor Strait
You can check your rails logs. There you will find out how long time
your request took in db, rendering views and the total time.
/K
2010/1/25 Hemant Bhargava li...@ruby-forum.com:
Champs,
Is there any way to find out that how much time a page had taken to load
itself ? Googled for it but no
You could also check up document oriented and schema free databases
like couchdb and mongodb if you would like to see your design problem
from another perspective.
Good luck,
Kristian
2010/1/25 Alpha Blue li...@ruby-forum.com:
I would look into understanding how to normalize your databases
I personally use ResourceController,
http://github.com/jamesgolick/resource_controller, for controllers
using the REST-pattern, but
http://github.com/josevalim/inherited_resources seems very nice too.
/K
2010/1/25 Alpha Blue li...@ruby-forum.com:
You probably should extend your code by
I just ran the gem bundle on the third_rails demo app, but for some
reason rails can't be loaded!?
kristian-mandrups-macbook-pro:third_rails kristianconsult$ rails -v
Rails 3.0.pre
kristian-mandrups-macbook-pro:third_rails kristianconsult$ script/
generate model Post name:string
/Users
kristian-mandrups-macbook-pro:rails3_apps kristianconsult$ rails my_r3
create
create README
create .gitignore
create Rakefile
create config.ru
create Gemfile
create app
...
kristian-mandrups-macbook-pro:my_r3 kristianconsult$ script/console
Turns out the problem was with the old version of the json gem! Just
needed to upgrade it :)
kristian-mandrups-macbook-pro:my_r3 kristianconsult$ sudo gem install
json
Password:
Building native extensions. This could take a while...
Successfully installed json-1.2.0
1 gem installed
Installing ri
have you tried to connect to your mysql server by the mysql-client?
mysql -h localhost -P 3306 -p dbname
2010/1/20 Andrew Perkins li...@ruby-forum.com:
Hello all, I've been trying to get ruby on rails to work with my local
install of mysql(its with wamp). Windows XP, Ruby 1.8.6, rails
try to add `require zip/zipfilesystem' in the ruby file that
requires the rubyzip gem
2010/1/19 giorgio george.pever...@gmail.com:
Hi,
I have installed rubyzip successfully(see output below)
Successfully installed rubyzip-0.9.1
1 gem installed
Installing ri documentation for
See the gem restful-authentication
2010/1/19 Tom Mac li...@ruby-forum.com:
Hi
in the login page i have a check ox which says Keep me looged in for
1 week .
Please guide how can I do this..I am planning to use authlogic
Thanks
Tom
--
Posted via http://www.ruby-forum.com/.
--
You
I installed the bundler, no problem - but it seems to have screwed up
my gem repository in both cases!?
What to do?
kristian-mandrups-macbook-pro:~ kristianconsult$ sudo gem install thor
/Users/kristianconsult/.rvm/gems/ruby/1.9.1/gems/bundler-0.8.1/lib/
rubygems_plugin.rb:2:in `require
kristian-mandrups-macbook-pro:~ kristianconsult$ gem install thor
Successfully installed thor-0.12.2
1 gem installed
Installing ri documentation for thor-0.12.2...
ERROR: While executing gem ... (Errno::EACCES)
Permission denied - /Users/kristianconsult/.ri/cache/.doc_dirs
--
Actually I did
Joins can only be used in one database AFAIK. I dont know how rails
will handle it, if the connection used doing the join doesn't have the
referenced tables you will probably get an error.
Kristian
2009/12/16 mrmanishs man...@acceleweb.com:
We have two environments, sandbox and production, each
I haven't tested this myself, but it looks promising:
http://timetobleed.com/memprof-a-ruby-level-memory-profiler/
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group.
To post to this group, send email to rubyonrails-t...@googlegroups.com.
To
2009/12/11 pankaj pankajbhage...@gmail.com:
Hi,
Lets assume we have an url, /controller1/action1.
In the before filter, under certain conditions, I want to route it
to /controller2/action2. without changing the url at the client side
ie I donot want to use redirect. Please help.
class
Maybe you're looking for 'request.env' ?
2009/12/10 ct9a anexi...@gmail.com:
hi, guys
I was wondering what sort of methods there are to get request
information in rails?
In Perl, when using mason, we can use $m-request() or something
similar. How about rails? thanks
--
You received
Test the entire stack. Do not just test models. Test/spec models,
controllers, and use integration tests/specs. This will give you
confidence when developing and literally makes your work 1000 times
less stressful. Yes, it takes more time, but it is the ONLY way to
develop a reliable app that
You could read the desired data from a file or database and update
your ActionMailer::Base.configuration before you send a mail.
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group.
To post to this group, send email to
2009/12/11 pepe p...@betterrpg.com:
Thanks Kristian.
I've thought about this and what I would probably do is store the
information for ActionMailer in a YAML file. Getting the data is not a
problem, the problem is how to make ActionMailer use the changed
configuration without restarting
Cant you just do `request.server_port' in controller?
2009/12/9 Thomas thomas.net...@gmail.com:
For debugging purpose I find it helpful to see which mongrel out of an
upstream cluster, specifically which port number, handles an actual
request. For example, let the load balancer operate on
Does request.env.inspect gives you any hint?
2009/12/9 Thomas thomas.net...@gmail.com:
Hi Kristian, this also results in port number '3000', and not in the
port number of the upstream mongrel.
On 9 Dez., 09:46, Kristian Hellquist kristian.hellqu...@gmail.com
wrote:
Cant you just do
assert_redirected_to category_path(assigns(:category))
this line for example..when i use it in my code
def test_should_create_category
login_as :admin
assert_difference Category, :count, 1 do
post :create, :category = { }
end
assert_redirected_to
We are running libxml-ruby 1.1.3 and 2.6.32.dfsg-5ubuntu4.2 of libxml2,
running on Ubuntu 9.04.
Does anyone have any suggestions on how to proceed with fixing the issue?
Test with another xml-lib? REXML or Nokogiri, there are probably more
that you can try.
--
You received this message
Tried this
http://kl93.blogspot.com/2008/08/add-and-remove-remote-source-from-gem.html
?
--
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group.
To post to this group, send email to rubyonrails-t...@googlegroups.com.
To unsubscribe from this
8, 2009 at 1:17 AM, Kristian Hellquist
kristian.hellqu...@gmail.com wrote:
Tried this
http://kl93.blogspot.com/2008/08/add-and-remove-remote-source-from-gem.html
?
--
You received this message because you are subscribed to the Google Groups
Ruby on Rails: Talk group.
To post
--
Atenciosamente,
Paulo Coutinho.
Blog: www.prsolucoes.com/blog
Site: www.prsolucoes.com
Msn: pa...@prsolucoes.com
2009/12/6 Kristian Hellquist kristian.hellqu...@gmail.com
But local and on my server(passenger) it is ok, and function normal, but
on
JRUBY i get an error because it is thinking
But my system is an ERP, i have more than 20 controllers.
I have to make it for all controllers and actions?
I have an application with something like 20 controllers and make all
routes explicit for each controller.
My actions is in portuguese, not edit but alterar... i put here an
example
But local and on my server(passenger) it is ok, and function normal, but on
JRUBY i get an error because it is thinking that admin is a controller and
clients is a action of admin.
My controllers is not restfull, so what i have to do, to correct it? Or what
the best method to make the admin?
in functional tests.
If you dont trust your test-suite, you are not testing enough :)
Good luck,
Kristian Hellquist
2009/12/5 sanjanad d_sanja...@yahoo.com:
my tests are running with no errors..
but how do i check whether the functional tests i wrote are working..i
need please..
require
In test_helper.rb you usually put all the global methods and data
required, so it looks typically fine to me.
Kristian Hellquist
2009/12/5 sanjanad d_sanja...@yahoo.com:
is it ok if i define my login_as in test_helper.rb ???
def login_as(admin)
@request.session[:admins] = admin ? admins
It doesnt looks like the form has the id parameter for the Post.
Kristian
2009/12/5 RubyonRails_newbie craigwest...@googlemail.com:
Hello there,
I am looking to be able to delete posts from within my account page.
I have a destroy action within the posts controller, which looks like
I am just getting started with Rake. I am trying to create a rake task
from within a rails plugin to copy some asset files (inside /assets in
my plugin folder) to my rails application /public folder.
How can I achieve this?
I am not sure whether to use FileUtils or File. Where AM I in rake
Why not try Hobo, a rails extension. It includes a pretty decent
permission based system using roles... that u can set declaratively for your
application. Hobo also include a host of other realy cool features.
http://hobocentral.net/
--~--~-~--~~~---~--~~
You
61 matches
Mail list logo