« Back to channel list

#RubyOnRails - 23 December 2015

« Back 1 day Forward 1 day »
[00:00:18] Miron_: has joined #RubyOnRails
[00:06:40] qejk: has joined #RubyOnRails
[00:06:53] Pazician: has joined #RubyOnRails
[00:07:26] kpollich: has joined #RubyOnRails
[00:11:54] cassioscabral: has joined #RubyOnRails
[00:12:18] ur5us: has joined #RubyOnRails
[00:13:35] ElFerna: has joined #RubyOnRails
[00:15:19] mary5030: has joined #RubyOnRails
[00:15:38] djbkd: has joined #RubyOnRails
[00:21:10] smathy: ORDER("SUBSTRING(name,7)")
[00:22:55] DLSteve: has joined #RubyOnRails
[00:34:34] ElFerna: has joined #RubyOnRails
[00:36:31] devuser: has joined #RubyOnRails
[00:38:12] doodlehaus: has joined #RubyOnRails
[00:40:58] yashinbasement: has joined #RubyOnRails
[00:41:51] yashinbasement: Hi I pushed a rails app from linux box to github, when I pulled it on mac, there is no data in database, any comment !
[00:42:33] FailBit: what, do you expect it to magically transfer?
[00:42:50] darrik: has joined #RubyOnRails
[00:44:00] yashinbasement: so it does not transfer the database , but when I pulled in the same machine in different folder data was there
[00:45:02] smathy: yashinbasement, I'm assuming you're using sqlite, so expected your DB files to be pushed up to GH, and then pulled back down. For a start, that's a terrible idea, you don't want a pull from GH to overwrite things in your DB. For that reason the sqlite files in the db folder are, by default, in the .gitignore that Rails generates, so won't have been added to your index unless you explicitly named the files.
[00:48:17] yashinbasement: here is one more question I am having , how to convert ztime ( http://www.theweatherprediction.com/basic/ztime/ ) to localtime
[00:48:44] gambl0re: has joined #RubyOnRails
[00:51:07] jbrhbr: has joined #RubyOnRails
[00:52:09] jbrhbr: hey guys, do any of you run into the issue where trying to suspend (ctrl+z) a rails console renders it irrecoverably screwed? this within the OSX Terminal app, not sure if it applies to other terminals
[00:52:12] shibabu: has joined #RubyOnRails
[00:53:56] gizless: has joined #RubyOnRails
[00:54:36] jbrhbr: https://gist.github.com/jerryhebert/4d9ff322f8b25ad9102e
[00:55:04] jbrhbr: for example. on line 39 i typed "pressing ctrl+c a bunch of times now" and that garble came out
[00:56:05] ElFerna: has joined #RubyOnRails
[00:56:08] gizmore|2: has joined #RubyOnRails
[00:56:12] Cervajz: has joined #RubyOnRails
[00:57:05] jbrhbr: happens with ITerm2 as well
[00:58:10] smathy: jbrhbr, yes.
[00:59:27] gizmore: has joined #RubyOnRails
[00:59:45] jbrhbr: is there some resolution that i'm unaware of or is it a "deal with it" kind of situation?
[01:00:28] gizless: has joined #RubyOnRails
[01:02:26] Papierkorb: jbrhbr: Ctrl+Z completely breaks the shell.
[01:02:51] Papierkorb: So, in that context, it's the "deal with it" thing
[01:03:15] Papierkorb: (If you figure out a patch I'm one of those who'd be happy to have it)
[01:03:19] jbrhbr: i have never seen a suspend kill a process like this
[01:03:24] havenwood: jbrhbr: DISABLE_SPRING=1 rails c
[01:03:33] havenwood: jbrhbr: Spring doesn't play nice.
[01:04:01] jbrhbr: that does the trick
[01:04:02] allcentury: has joined #RubyOnRails
[01:04:21] jbrhbr: spring only causes me headaches anyway, my rails c alias is actually 'spring stop; rails c' lol
[01:04:29] Papierkorb: jbrhbr: though, you can always use the prefix-dot in pry to call out to shell tools, including ncurses ones ;)
[01:04:30] jbrhbr: so i'll just disable it entirely, thanks
[01:04:35] Papierkorb: jbrhbr: like: .ls
[01:05:13] maletor_: has joined #RubyOnRails
[01:05:31] pwnd_nsfw: has joined #RubyOnRails
[01:06:50] Papierkorb: I like spring mostly for rspec tests. else running a single one takes ages
[01:07:51] smathy: I like spring too, but it's definitely a PITA unless you understand when it doesn't work.
[01:09:33] jbrhbr: i heard there's a gem to make it more to my liking but i'm waiting to dig into that when i don't have more important things to learn. still pretty new to rubyland
[01:09:41] Papierkorb: YES. The interesting moment when your code burns more than hell for absolutely no reason. except that you did something that spring didn't get and thus decided to run screaming in a circle
[01:09:50] jbrhbr: this console suspend corruption thing is pretty surprising though
[01:10:29] Spami: has joined #RubyOnRails
[01:10:30] jbrhbr: before i learned about the spring magic, i was pulling my hair out when my console testing wasn't responding to my changes consistently
[01:10:48] Papierkorb: jbrhbr: do: reload!
[01:11:13] jbrhbr: is that reliable?
[01:11:20] Papierkorb: in the shell? Yup
[01:11:52] Papierkorb: Except that time when I was messing with activesupport autoloading dependencies. That's not what you usually do though so it's fine.
[01:11:54] jbrhbr: wouldn't old instances be potentially corrupt?
[01:12:16] jbrhbr: i don't know how ruby handles that under the hood but it can get messy
[01:12:17] Papierkorb: of your existing objects? They'll point to the old version of their class, yes.
[01:12:53] Papierkorb: Well, a class ist just an object. it will get GC'd if no longer needed. but as long an object refers to it, it'll stick around.
[01:13:11] Papierkorb: Just make sure to not reuse variables whose class you've just changed
[01:14:08] jbrhbr: thanks, i'll play with it
[01:17:43] Spami_: has joined #RubyOnRails
[01:18:01] pr1meshock: has joined #RubyOnRails
[01:19:41] paradisaeidae: has joined #RubyOnRails
[01:20:39] Oliphaunte: has joined #RubyOnRails
[01:22:52] Spami: has joined #RubyOnRails
[01:25:29] tuelz: has joined #RubyOnRails
[01:27:36] run_kmc: has joined #RubyOnRails
[01:28:48] lessless: has joined #RubyOnRails
[01:31:40] ElFerna: has joined #RubyOnRails
[01:33:30] guytws: has joined #RubyOnRails
[01:35:13] agent_white: has left #RubyOnRails: ()
[01:36:48] sevenseacat: has joined #RubyOnRails
[01:38:17] run_kmc: has joined #RubyOnRails
[01:38:32] run_kmc: has left #RubyOnRails: ()
[01:38:57] shibly: has joined #RubyOnRails
[01:40:27] shibly: <%= javascript_include_tag 'defaults', 'data-turbolinks-track' => true %>
[01:40:41] shibly: application to defaults, then it works
[01:40:47] shibly: otherwise got errors
[01:40:49] Oliphaunte: has joined #RubyOnRails
[01:41:26] Trynemjoel: has joined #RubyOnRails
[01:43:04] shibly: sevenseacat: How are you?
[01:43:13] sevenseacat: not bad, just rolled out of bed >_>
[01:44:34] Miron_: has joined #RubyOnRails
[01:45:03] shibly: sevenseacat: What does it mean by "roll out of bed" ?
[01:45:25] shibly: It's 12:45 PM
[01:45:27] alex88: has joined #RubyOnRails
[01:46:09] sevenseacat: its 9:45 am :)
[01:51:04] FailBit: it's 20:51
[01:51:54] joshkovach: has joined #RubyOnRails
[01:52:10] djbkd: has joined #RubyOnRails
[01:52:21] sevenseacat: wow. timezones. such difference. many timez.
[01:54:16] pr1meshock: has joined #RubyOnRails
[01:56:33] atomical: has joined #RubyOnRails
[01:57:57] pontiki_: has left #RubyOnRails: ()
[01:58:38] twilling: has joined #RubyOnRails
[01:58:43] pontiki: has joined #RubyOnRails
[01:59:51] Trynemjoel: has joined #RubyOnRails
[02:01:02] mrbubbles: has joined #RubyOnRails
[02:01:55] lbotos: has joined #RubyOnRails
[02:02:32] erichu: has joined #RubyOnRails
[02:03:22] VeryBewitching: Happy holidays to everyone, in the case that I'm not around later on this week.
[02:03:42] RegulationD: has joined #RubyOnRails
[02:04:09] czetter: has joined #RubyOnRails
[02:05:03] mjc_: has joined #RubyOnRails
[02:05:24] shibly: Is it installed by default? coffee-script (2.4.1)
[02:05:29] shibly: with bundle install
[02:05:34] smathy: Not good enough VeryBewitching, I expect well wishes on Christmas Day itself!
[02:05:35] shibly: or gem install rails
[02:05:42] sevenseacat: shibly: check if its in your Gemfile.
[02:06:03] benlieb: has joined #RubyOnRails
[02:06:05] shibly: gem 'coffee-rails', '~> 4.1.0'
[02:06:10] shibly: in Gemfile
[02:06:12] VeryBewitching: smathy: Year end is a very busy time for me, haven't been here all month pretty much.
[02:06:33] VeryBewitching: smathy: But I will endeavor to, just for you
[02:06:34] sevenseacat: shibly: then there you go
[02:06:45] one_zero: has joined #RubyOnRails
[02:07:38] Pazician: has joined #RubyOnRails
[02:07:53] shibly: 'coffee-rails' and coffee-script same?
[02:08:15] sevenseacat: no, but coffee-rails will depend on coffee-script - in your Gemfile.lock, you'll see that
[02:08:20] smathy: VeryBewitching, uh oh, I just realized that means now *I* have to be online too!
[02:08:23] sevenseacat: coffee-script will be indented under coffee-rails
[02:08:26] smathy: That'll be a paddlin'
[02:09:27] hardtail: has joined #RubyOnRails
[02:09:54] rubyonrails342: has joined #RubyOnRails
[02:12:45] yashinbasement: Hi can any one tell how to use utc_to_local method to convert time
[02:13:06] sevenseacat: you call it on atimestamp?
[02:13:19] yashinbasement: i have a model called DayFile which has a date field
[02:13:37] hardtail: has joined #RubyOnRails
[02:13:38] yashinbasement: I want to convert that date field to local time
[02:13:42] VeryBewitching: DayFile.date.localtime
[02:13:56] Oliphaunte: has joined #RubyOnRails
[02:14:21] VeryBewitching: But you need to set the time zone in the request that localtime should use.
[02:14:22] owenjones: has joined #RubyOnRails
[02:15:33] Trynemjoel: has joined #RubyOnRails
[02:15:36] Surt_Q: has joined #RubyOnRails
[02:15:56] yashinbasement: rails store date in UTC
[02:16:10] ElFerna: has joined #RubyOnRails
[02:16:40] VeryBewitching: yashinbasement: See https://gist.github.com/bewitchingme/473ae113eabdabfce3d8
[02:17:04] VeryBewitching: Gives an example with a signed in user or not.
[02:17:15] shibly: What's the command to list system wise gems?
[02:17:31] sevenseacat: shibly: gem list ;)
[02:17:34] shibly: "gem list" lists application wise
[02:17:49] VeryBewitching: bundle show does that I think
[02:17:53] shibly: sevenseacat: How did you install ruby
[02:17:54] VeryBewitching: for the application
[02:18:09] sevenseacat: with ruby-install. that was a random question.
[02:18:18] yashinbasement: VeryBewitching, what's the member in the gist,
[02:18:30] VeryBewitching: yashinbasement: A Member object
[02:18:49] yashinbasement: so what does that function do actually
[02:18:57] VeryBewitching: current_member ?
[02:19:13] yashinbasement: the set_user_tz
[02:19:42] VeryBewitching: yashinbasement: On each request I set the time zone applicable to the visitor; if they're not signed in, time is displayed in UTC
[02:19:44] yashinbasement: is that wrong in doing , as you said before DayFile.date.localtime
[02:20:11] sevenseacat: yeah I wasnt touching thata discussion.
[02:20:19] dextertzu: has joined #RubyOnRails
[02:20:47] VeryBewitching: yashinbasement: Try it out.
[02:21:55] cassioscabral: has joined #RubyOnRails
[02:21:55] VeryBewitching: brb, need to take baked things out of the oven
[02:23:37] akshat_: has joined #RubyOnRails
[02:23:45] B1n4r10: has joined #RubyOnRails
[02:24:27] shibly: sevenseacat: Oh, rvm maintains system wide gems and application wide gems, right?
[02:24:53] sevenseacat: rvm allows you to use gemsets if you so wish to segregate gems - i find them to be a waste of time
[02:26:12] tuelz: has joined #RubyOnRails
[02:27:25] shibly: sevenseacat: Did you use rvm before?
[02:27:37] sevenseacat: a few years ago, yes
[02:27:46] shibly: sevenseacat: Why is it waste of time?
[02:28:18] sevenseacat: gemsets are a waste of time because theres no need to use them
[02:28:56] sevenseacat: its my personal opinion that using rvm is like using a sledgehammer when an ordinary hammer is sufficient
[02:29:33] shibly: Got error for http://localhost:3000/welcome/index = https://bpaste.net/show/85be5e288551
[02:30:20] sevenseacat: did you remove jquery-rails from your Gemfile ?
[02:30:26] Trynemjoel: has joined #RubyOnRails
[02:31:42] VeryBewitching: yashinbasement: This article http://brendankemp.com/essays/dealing-with-time-zones-using-rails-and-postgres/ cleared a lot up for me when I first did this, should apply to any other database I think.
[02:31:53] shibly: ACTION is going to eat
[02:32:15] yashinbasement: yeah thanks VeryBewitching
[02:33:20] VeryBewitching: yashinbasement: It's a bit of a read, but it's thorough
[02:37:34] Bloomer: has joined #RubyOnRails
[02:38:05] Oliphaunte: has joined #RubyOnRails
[02:38:09] shibly: ACTION is back
[02:38:17] shibly: sevenseacat: Why did i get this error?
[02:38:24] B1n4r10: has joined #RubyOnRails
[02:38:36] sevenseacat: shibly: i have zero information that would tell me why.
[02:38:51] sevenseacat: shibly: I am also not a replacement for googling an error yourself.
[02:39:08] shibly: Did you see this? https://bpaste.net/show/85be5e288551
[02:39:31] sevenseacat: its an error message.
[02:41:28] VeryBewitching: shibly: http://stackoverflow.com/questions/22582097/sprocketsfilenotfound-in-staticpageshome
[02:41:41] VeryBewitching: Only because I was bored enough to search Google for you.
[02:42:14] mostlybadfly: has joined #RubyOnRails
[02:42:28] sevenseacat: seems VeryBewitching is willing to be google today
[02:42:40] VeryBewitching: sevenseacat: Let's not get carried away ;)
[02:46:50] shibly: http://stackoverflow.com/questions/22582097/sprocketsfilenotfound-in-staticpageshome , this didn't help
[02:47:02] shibly: //= require jquery is there
[02:47:52] sevenseacat: we know, thats whats causing the error.
[02:48:00] sevenseacat: please read through the entire question and answer.
[02:48:12] sevenseacat: it may help you, it may not.
[02:48:45] VeryBewitching: shibly: !gist the /app/assets/javascripts/application.js, Gemfile, /app/views/layouts/application.(erb|haml|slim)
[02:48:45] helpa: shibly: http://gist.github.com - Put your codes online with pretty syntax highlighting and the ability to embed it into other pages.
[02:49:07] VeryBewitching: And post the files separately please, not in one glump
[02:49:32] knite: has joined #RubyOnRails
[02:50:44] shibly: VeryBewitching: https://gist.github.com/anonymous/f9e58e7fc1d5a34a629d
[02:51:15] VeryBewitching: shibly: That's not what I asked for.
[02:51:24] VeryBewitching: That + Gemfile + your layout
[02:52:25] crunk_bear: has joined #RubyOnRails
[02:52:31] sevenseacat: VeryBewitching: you also asked for them not in one clump, so i have a feeling you're going to get them in separate gists :P
[02:52:37] ElFerna: has joined #RubyOnRails
[02:52:49] VeryBewitching: sevenseacat: I'
[02:52:58] shibly: https://gist.github.com/anonymous/e07d4299496025ca6e0b
[02:53:02] VeryBewitching: jfklsjl typing sucks when I've baked 200 cookies
[02:53:07] shibly: VeryBewitching: ^
[02:53:36] havenwood: shibly: You can add multiple files to a single gist. Use the correct extension for syntax highlighting.
[02:53:43] sevenseacat: or just all in one clump.
[02:54:09] shibabu: has joined #RubyOnRails
[02:54:48] VeryBewitching: shibly: Out of curiosity, which OS are you running this under?
[02:54:55] thejamespinto: has joined #RubyOnRails
[02:55:19] shibly: So there is no solution for me?
[02:56:09] sevenseacat: shibly: you're not doing anything to help your own cause here.
[02:56:51] sevenseacat: shibly: you've stated your problem with supporting code, now you can research it, and we can research it. don't just sit and wait to be spoonfed a solution.
[03:03:16] sevenseacat: its not an error i've seen before. i'd recommend trying the usual things - bundle; rm Gemfile.lock (safe because this is a brand new app)' bundle again
[03:10:43] Scriptonaut: has left #RubyOnRails: ()
[03:10:54] ascarter: has joined #RubyOnRails
[03:13:15] syzygy_: has joined #RubyOnRails
[03:14:07] paulf__: has joined #RubyOnRails
[03:14:43] Rodya_: has joined #RubyOnRails
[03:24:10] DLSteve: has joined #RubyOnRails
[03:25:36] atomical: has joined #RubyOnRails
[03:26:21] idefine: has joined #RubyOnRails
[03:27:01] tuelz: has joined #RubyOnRails
[03:27:18] Oliphaunte: has joined #RubyOnRails
[03:35:17] krz: has joined #RubyOnRails
[03:37:26] chouhoulis: has joined #RubyOnRails
[03:38:13] ^CrYpto^: has joined #RubyOnRails
[03:38:55] ElFerna: has joined #RubyOnRails
[03:41:48] Megamos: has joined #RubyOnRails
[03:45:37] cassioscabral: has joined #RubyOnRails
[03:46:36] n1lo: has joined #RubyOnRails
[03:52:06] bronson: has joined #RubyOnRails
[03:53:10] diggitydane: has joined #RubyOnRails
[03:55:59] atomical: has joined #RubyOnRails
[04:05:10] Axy: has joined #RubyOnRails
[04:05:11] Axy: has joined #RubyOnRails
[04:06:46] syzygy_: has joined #RubyOnRails
[04:08:33] Pazician: has joined #RubyOnRails
[04:08:50] Megamos: has joined #RubyOnRails
[04:08:53] wldcordeiro: has joined #RubyOnRails
[04:09:57] sankaber: has joined #RubyOnRails
[04:11:08] braincras: has joined #RubyOnRails
[04:11:32] kp666: has joined #RubyOnRails
[04:15:43] ascarter: has joined #RubyOnRails
[04:18:52] owenjones: has joined #RubyOnRails
[04:19:07] ^CrYpto^: has left #RubyOnRails: ("Leaving")
[04:21:13] dionysus69: has joined #RubyOnRails
[04:21:50] hardtail: has joined #RubyOnRails
[04:22:06] wethu: has joined #RubyOnRails
[04:22:39] Bloomer: has joined #RubyOnRails
[04:24:31] tectonic: has joined #RubyOnRails
[04:25:03] idefine: has joined #RubyOnRails
[04:29:18] tuelz: has joined #RubyOnRails
[04:32:30] Cervajz: has joined #RubyOnRails
[04:34:46] _Tariq: has joined #RubyOnRails
[04:35:34] syzygy_: has joined #RubyOnRails
[04:38:37] stevenw: has joined #RubyOnRails
[04:40:02] twilling: has joined #RubyOnRails
[04:42:31] Megamos: Q: I have and each loop creating li elements. When I now want to extract some code in each li outputed to a helper method. How to I call the current object being itterated from the array? The code breaks when I put it in healper method, caouse it does not understand the d in @discounts.each do |d|
[04:43:35] chouhoulis: has joined #RubyOnRails
[04:44:07] Megamos: I could put the whole itteration in a function that outputs each list item and all its data. Then I could use @discount in the helper method. But if I jsut wanna exract that small piece...
[04:44:44] Megamos: d.ends - Date.today).to_s.split("/")[0]
[04:44:46] idefine: has joined #RubyOnRails
[04:45:05] Megamos: (d.ends - Date.today).to_s.split("/")[0]
[04:48:12] Megamos: Found a better solution. Still wanna know how ppl normly solves this
[04:49:54] Bloomer: has joined #RubyOnRails
[04:50:39] shinnya: has joined #RubyOnRails
[04:53:33] baash05: Hey guys/girls..
[04:53:49] baash05: in rspec with a subject.. is there a way to test string length?
[04:53:59] baash05: it { is_expected.to have_length(11)}
[04:54:05] baash05: or something like that?
[04:55:02] sevenseacat: if you wrote a custom matcher for that, sure
[04:55:55] baash05: How would you do that in a one liner? I can do an it 'should be 11 characters long' do.. but I'm giving the other paradigm a shot
[04:57:08] shibabu: has joined #RubyOnRails
[04:58:44] baash05: This would work.. but it's ugly... is_expected.to match(/^.{11}$/)
[04:59:17] treaki__: has joined #RubyOnRails
[04:59:27] the_nick_me: has joined #RubyOnRails
[05:00:43] sevenseacat: if you were using rspec_its you could do its(:length) { is_expected.to eq 11 }
[05:01:27] baash05: but without that? Just vanilla rspec?
[05:01:43] sevenseacat: again, you could write a custom matcher
[05:01:45] baash05: multi line is fine, and already in play.. just wondering if.
[05:01:59] baash05: Meh.. multi line will stay.
[05:04:45] KennethSteel: has joined #RubyOnRails
[05:07:54] Megamos: has joined #RubyOnRails
[05:08:31] VeryBewitching: baash05: Take a look at the last one here: https://www.relishapp.com/rspec/rspec-expectations/v/2-14/docs/built-in-matchers/have-n-items-matcher
[05:08:45] sevenseacat: thats been removed in rspec 3
[05:08:59] sevenseacat: moved to rspec-collection-matchers
[05:10:26] VeryBewitching: sevenseacat: First Google hit ;)
[05:12:09] tvw: has joined #RubyOnRails
[05:19:11] LambdaSource: has joined #RubyOnRails
[05:19:48] owenjones: has joined #RubyOnRails
[05:21:50] Megamos: I have a table "Venue", that has a "city" collumn. How do I use simple_form to show a collection of all cities available?
[05:21:56] baash05: Yeah.. that was a custom matcher.. I don't want to heisnburge the model
[05:22:18] bronson: has joined #RubyOnRails
[05:23:22] Oliphaunte: has joined #RubyOnRails
[05:23:23] sevenseacat: Megamos: is city a foreign key to a cities table, or something similar?
[05:23:32] dextertzu: has joined #RubyOnRails
[05:28:16] baash05: cool link.. Didn't work for a string.
[05:29:25] sevenseacat: "didnt work" is the most useless error message
[05:29:45] baash05: undefined method `items' for #<RSpec::Matchers::BuiltIn::Has:0x0000000b5b0350>
[05:29:45] baash05: # ./spec/services/bids/accepter_spec.rb:84:in `block (4 levels) in <top (required)>'
[05:29:49] brupm: has joined #RubyOnRails
[05:30:13] baash05: same thing when I put chars.. which would be an array
[05:30:30] tuelz: has joined #RubyOnRails
[05:30:46] VeryBewitching: baash05: Have you tried respond_to(:length).with(11)
[05:30:54] sevenseacat: right, because you're using rspec 3 I'm guessing
[05:31:41] Megamos: sevenseacat: No just a column with strings
[05:32:00] sevenseacat: then you probably want something like f.input :city, collection: City.all
[05:32:00] baash05: it { is_expected.to respond_to(:length).with(11) } I don't think that would work ...
[05:32:14] sevenseacat: baash05: !try
[05:32:14] helpa: baash05: Why don't you try it and find out for yourself?
[05:32:25] VeryBewitching: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers/respond-to-matcher
[05:32:37] VeryBewitching: The docs seem to suggest it will.
[05:32:48] tlarevo: has joined #RubyOnRails
[05:33:03] baash05: expected "W0000011857" to respond to :length with 11 arguments
[05:33:23] sevenseacat: .and_return, not .with
[05:34:18] baash05: undefined method `and_return' for #<RSpec::Matchers::BuiltIn::RespondTo:0x0000000ae77020>
[05:35:05] sevenseacat: personally, I'd just use one of the two methods I outlined a long time ago
[05:35:43] baash05: Yeah.. that's what I've done.. this became an academic conversation after you said you didn't know how..
[05:35:43] Megamos: sevenseacat: This "f.collection_select :city, Local.all, :id, :city" Almost gave me what I wanted... but there are multiple entries of some of the cities
[05:36:10] baash05: I googled around for a way, but didn't see it either.
[05:36:10] sevenseacat: Megamos: ok, thats nothing to do with simple form
[05:36:20] sevenseacat: baash05: I never said i didnt know how -_-
[05:36:41] sevenseacat: I gave you multiple ways of doing what you wanted
[05:37:00] sevenseacat: Megamos: but if you've got the same city listed multiple times in Local.all, that will happen
[05:37:03] baash05: Yeah.. totally true.. but I meant without vanilla.. the easy one liner
[05:37:12] sevenseacat: without vanilla?
[05:37:26] sevenseacat: last i checked, a custom matcher made for easy one-liner specs
[05:37:29] baash05: with vanilla rspec.. without gems and modifing
[05:37:44] emilkarl: has joined #RubyOnRails
[05:37:56] baash05: Yeah.. but then I've got to have a custom matcher which would (just assuming here) be more than one line :)
[05:38:09] sevenseacat: now you're just putting in artificial restrictions for the fun of it
[05:38:12] baash05: It seems overkill for this singe use case.
[05:38:19] Miron_: has joined #RubyOnRails
[05:38:22] baash05: No I'm trying to write it simple as..
[05:38:33] baash05: To save one line I
[05:38:40] baash05: add three.
[05:38:59] sevenseacat: depends on how often you use it
[05:39:01] VeryBewitching: Or one line to your Gemfile
[05:39:08] sevenseacat: if its a test you want to add often, it becomes totally worth it
[05:39:12] sevenseacat: VeryBewitching: +1
[05:39:14] VeryBewitching: rspec-its will let you use the line sevenseacat provided earlier
[05:39:17] baash05: Yeah.. but one line in the gemfile is not one line in code.
[05:39:23] sevenseacat: i would always go for readable specs over 'vanilla'
[05:39:44] baash05: it 'should be at least 11 characters long' do
[05:39:45] baash05: expect(subject.length).to eq 11
[05:39:52] baash05: that's easy as to read.
[05:40:14] sevenseacat: its also repetitive
[05:40:23] sevenseacat: you're saying the exact same thing twice
[05:40:33] sevenseacat: and i guarantee you they will get out of sync at some point
[05:40:39] matthewd: .. if you make the string into less of a lie
[05:40:50] sevenseacat: matthewd: hahaha didnt even notice that
[05:40:58] VeryBewitching: matthewd: True.
[05:41:05] sevenseacat: i dont often write spec descriptions, and thats why
[05:41:46] baash05: true.. if the string was 12 then the description would be wrong..
[05:42:08] VeryBewitching: So would the test. At least 11 characters long does not equal 11
[05:42:16] VeryBewitching: It equals 11 or more characters.
[05:43:50] VeryBewitching: Unless there's a specific need to not add another gem for your test environment that would make your life easier, add the gem. :)
[05:44:42] chouhoulis: has joined #RubyOnRails
[05:46:09] shibly: has joined #RubyOnRails
[05:46:15] shibly: Anyone there?
[05:46:36] sevenseacat: shibly: there are 530 users in the channel, including you.
[05:46:43] shibly: http://stackoverflow.com/questions/34427834/sprocketsfilenotfound-in-welcomeindex , can't get good answers.
[05:46:52] tlarevo: has joined #RubyOnRails
[05:46:59] Megamos: sevenseacat: So I need to do a query and collect an array of all different cities outside of the form? Like in the ctrl for now.
[05:47:25] sevenseacat: Megamos: [13:31:59] sevenseacat: then you probably want something like f.input :city, collection: City.all
[05:47:36] sevenseacat: shibly: did you try what I suggested hours ago?
[05:47:52] shibly: What did you suggested?
[05:48:53] VeryBewitching: shibly: Remove Gemfile.lock and then run (in the project folder): bundle install
[05:49:08] VeryBewitching: If it's a new app you just created today.
[05:49:10] sevenseacat: shibly: [11:03:16] sevenseacat: its not an error i've seen before. i'd recommend trying the usual things - bundle; rm Gemfile.lock (safe because this is a brand new app)' bundle again
[05:49:26] Megamos: sevenseacat: That gives me the Venues, not the cities column of Venues
[05:49:41] sevenseacat: Megamos: I didn't mention nything about Venues?
[05:50:10] sevenseacat: Megamos: where should this list of cities come from?
[05:50:43] Megamos: sevenseacat: The table(model) Venues has an attribute(column) cities.
[05:50:52] sevenseacat: yes, we established that already
[05:51:07] sevenseacat: you also said city before, not cities
[05:51:17] Megamos: sorry, city
[05:51:33] PedramT: has joined #RubyOnRails
[05:51:35] sevenseacat: [13:21:50] Megamos: I have a table "Venue", that has a "city" collumn. How do I use simple_form to show a collection of all cities available?
[05:51:44] sevenseacat: so, where does this collection of cities come from?
[05:52:43] Megamos: sevenseacat: Not sure if I follow. User input... they input where there venue is located
[05:52:56] sevenseacat: you want to show a collection of all cities available
[05:53:06] sevenseacat: so I presume you have a list of all cities available, somewhere
[05:53:29] sevenseacat: otherwise I have no idea what you want to put in this collection
[05:53:31] shibly: sevenseacat, http://stackoverflow.com/questions/22582097/sprocketsfilenotfound-in-staticpageshome , here i don't see that someone told to rm Gemfile.lock, where did you find it?
[05:53:48] Megamos: Well, that was my first thought. Would be easy. But then if someone adds a new city, some small one?
[05:54:01] sevenseacat: shibly: i found it in my head
[05:54:21] sevenseacat: Megamos: when you work out what you want to put in that collection, then we can figure out how to get it there
[05:54:29] shibly: http://stackoverflow.com/questions/22582097/sprocketsfilenotfound-in-staticpageshome , this won't help i think, currently i am using windows,
[05:54:42] sevenseacat: shibly: you said you were using debian 8 before
[05:54:44] shibly: So i have to check when i will use debian
[05:54:54] brupm: has joined #RubyOnRails
[05:55:14] Megamos: sevenseacat: Guess I'll make a query outside of simple_form to collect all cities then give simple_form that array
[05:55:24] shibly: sevenseacat, It's not the answer: http://stackoverflow.com/questions/22582097/sprocketsfilenotfound-in-staticpageshome
[05:55:26] sevenseacat: Megamos: sounds good.
[05:55:32] sevenseacat: shibly: what on earth are you talking about
[05:56:16] malkav: has joined #RubyOnRails
[05:56:20] shibly: There it says to include //= require jquery and //= require jquery_ujs, that's not solution
[05:56:34] shibly: Those are already included.
[05:56:45] sevenseacat: shibly: again, did you try what ive now suggested twice to you?
[05:57:04] shibly: sevenseacat, You said to rm Gemfile.lock, isn't it?
[05:57:11] VeryBewitching: shibly: In my personal experience, if you're running Ruby on Windows, I blame Windows for anything you experience that you don't expect.
[05:57:13] sevenseacat: yes, and bundle again.
[05:57:38] sevenseacat: did you try that, or are you hung up on a stackoverflow answer you refuse to read past the first line of?
[05:57:41] shibly: I will try that when i will use debian
[05:58:23] sevenseacat: you came to seek answers but you won't actually try to fix your problem now?
[05:58:44] shibly: I am at job with windows
[05:58:56] shibly: I will try when i will use debian at home
[05:59:05] lxsameer: has joined #RubyOnRails
[05:59:14] sevenseacat: i'll make a note of my suggestion to remind you yet again when you get home.
[05:59:18] VeryBewitching: shibly: You need to delete Gemfile.lock and then run, in a console in the project folder: bundle install
[05:59:32] VeryBewitching: shibly: But if that doesn't work, I blame Windows.
[05:59:52] sevenseacat: VeryBewitching: they're developing on debian.
[06:00:03] VeryBewitching: sevenseacat: Yes, but he's not doing *this* on Debian
[06:00:09] VeryBewitching: That's where it's going to run.
[06:00:11] sevenseacat: he's not doing *this* at all right now
[06:00:46] shibly: I tested before one thing before, <%= javascript_include_tag 'defaults'', 'data-turbolinks-track' => true %> instead of <%= javascript_include_tag 'application', 'data-turbolinks-track' => true %> works
[06:01:03] shibly: Why is this?
[06:01:06] sevenseacat: it will "work" but now you have no javascript on your page
[06:01:10] sevenseacat: because you've removed it
[06:01:16] sevenseacat: you have no defaults file
[06:05:05] shibly: sevenseacat, How old are you? Is your photo available on internet?
[06:05:13] shibly: in twitter?
[06:05:16] sevenseacat: shibly: i dont see how thats relevant to the conversation.
[06:05:25] shibly: Yes, that is offtopic
[06:05:56] sevenseacat: then again, if you want to know something, try and find it yourself instead of getting spoonfed answers.
[06:07:04] PedramT: has joined #RubyOnRails
[06:07:22] shibly: Do you love cat?
[06:07:33] sevenseacat: i'm a cat person, yes.
[06:07:38] shibly: All i get in internet is a cat's photo.
[06:08:20] sevenseacat: indeed, thats the avatar i use everywhere.
[06:09:01] shibly: I am good at php, sometimes rails looks difficult to configure, run and develop websites
[06:09:14] shibly: I work with php
[06:09:43] shibly: But i used rails 3 before
[06:12:39] Oliphaunte: has joined #RubyOnRails
[06:13:40] idefine: has joined #RubyOnRails
[06:13:48] shibly: Can anyone give me some idea to develop something with rails 4?
[06:14:00] shibly: What should i develop?
[06:14:04] moeabdol: has joined #RubyOnRails
[06:14:10] VeryBewitching: Start with a blog.
[06:14:33] shibly: I have developed my personal blog with rails 3 before, something new?
[06:15:45] VeryBewitching: If you're just looking to learn Rails 4, develop anything. A Twitter or Pinterest clone should be pretty easy to create in the most basic form.
[06:15:51] dmarr: a darknet market
[06:16:38] sevenseacat: ACTION starting to form Opinions
[06:17:01] VeryBewitching: ACTION gives sevenseacat a freshly baked Fruit Funkit
[06:17:16] sevenseacat: i dont know what that is but it sounds tasty. ta :)
[06:17:32] VeryBewitching: It's a cookie with nutmeg, cinnamon, cherries and dates.
[06:17:38] VeryBewitching: I've made 200 today
[06:18:13] VeryBewitching: I have a neighbour who made 200 dozen cookies for the holiday season.
[06:18:26] VeryBewitching: And she's pregnant. Go her.
[06:18:48] sevenseacat: ive done nothing for the holiday season. win.
[06:20:12] PedramT: has joined #RubyOnRails
[06:22:19] VeryBewitching: At least I got to play with trailblazer today while waiting for things to bake.
[06:26:57] VeryBewitching: Uh, I think there's a lot of cooks in those kitchen(s?)
[06:27:24] sevenseacat: which is weird because its all run by one guy
[06:27:34] brupm: has joined #RubyOnRails
[06:28:23] VeryBewitching: Well the trailblazer README specifies three gems to be added to your Gemfile, but doesn't mention that you need (in my case) cells-haml or things blow up. This is after examples are displayed using HAML
[06:28:35] Oliphaunte: has joined #RubyOnRails
[06:28:52] VeryBewitching: Not a big deal, just wasn't obvious for the first 30 minutes what was going wrong.
[06:29:21] VeryBewitching: Other than that, I like the syntax, but opinion-wise I won't know until I've used it for a while.
[06:29:24] krz: has joined #RubyOnRails
[06:29:25] nbdy: has joined #RubyOnRails
[06:29:45] VeryBewitching: smathy and tubbo have said good things, though.
[06:30:06] sevenseacat: i looked at trailblazer briefly some time ago, but i think its matured a lot since then
[06:30:49] VeryBewitching: I like that the cells you create are autonomous of the framework you're using, so I could use them with Rails, Roda, Volt, Sinatra, etc.
[06:31:04] sevenseacat: heard good things about roda (and rodakase) lately
[06:31:41] tuelz: has joined #RubyOnRails
[06:31:42] VeryBewitching: I looked at that a while ago too, Roda seems mature, but I'm about 50% through what I want to know about Rails so it's on a shelf for now.
[06:32:13] sevenseacat: my spare time (like today) is spent tinkering with phoenix, so
[06:32:43] michaeldeol: has joined #RubyOnRails
[06:33:21] sevenseacat: an elixir web framework
[06:33:23] idefine: has joined #RubyOnRails
[06:33:56] VeryBewitching: Ah. Enjoying it?
[06:35:43] bronson: has joined #RubyOnRails
[06:38:14] tagrudev: has joined #RubyOnRails
[06:41:40] VeryBewitching: For the heck of it, I tried installing elixir, but there's a dep issue with 15.10 it seems.
[06:41:57] VeryBewitching: Off topic here, though.
[06:42:21] PedramT: has joined #RubyOnRails
[06:43:09] lessless: has joined #RubyOnRails
[06:43:36] bronson: has joined #RubyOnRails
[06:45:26] chouhoulis: has joined #RubyOnRails
[06:45:29] baweaver: has joined #RubyOnRails
[06:45:46] emilkarl: has joined #RubyOnRails
[06:47:17] lemur: has joined #RubyOnRails
[06:47:36] lacuna_: has joined #RubyOnRails
[06:48:18] pawnbox: has joined #RubyOnRails
[06:49:40] solars: has joined #RubyOnRails
[06:54:29] brupm: has joined #RubyOnRails
[06:56:30] _3dwardsharp: has joined #RubyOnRails
[06:56:58] Radar: GOOD AFTERNOON
[06:57:22] Radar: First Christmas guest has checked in to the Bigg B&B.
[06:57:22] sevenseacat: how was xmas party yesterday?
[06:57:27] Radar: oh my hangover
[06:57:31] sevenseacat: guests? oy vey
[06:57:53] Radar: Yeah, we're hosting this year
[06:58:48] emilkarl: has joined #RubyOnRails
[06:58:53] shanemcd: has joined #RubyOnRails
[06:59:02] shibabu: has joined #RubyOnRails
[07:00:43] Kn|t3: has joined #RubyOnRails
[07:01:42] Cervajz: has joined #RubyOnRails
[07:03:02] idefine: has joined #RubyOnRails
[07:03:07] Cervajz_: has joined #RubyOnRails
[07:04:42] Cervajz__: has joined #RubyOnRails
[07:05:23] nocontrol: has joined #RubyOnRails
[07:07:22] Pazician: has joined #RubyOnRails
[07:07:25] dmarr: i'd think this wouldn't run the `set_picture` method inside pictures_controller https://github.com/marr/localpic2/issues/1
[07:08:23] dmarr: routes is setting :index as the handler for get /api/v1/pictures according to https://github.com/marr/localpic2/blob/master/config/routes.rb, right?
[07:09:12] sevenseacat: dmarr: do you want us to dig through your entire repo to find the problem?
[07:09:26] dmarr: sevenseacat: no but is the second question I ask valid?
[07:09:35] sevenseacat: then let's start with the failing spec
[07:10:12] sevenseacat: its defining a /api/v1/pictures/index route
[07:10:20] sevenseacat: for reasons unknown
[07:10:47] dmarr: sure, I replaced get '/api/v1/pictures'
[07:11:05] dmarr: s/ /get pictures_path with:/
[07:11:35] sevenseacat: let's start with your failing spec and work backwards, no?
[07:11:46] sevenseacat: so what's the spec?
[07:12:31] dmarr: I originally had get pictures_path instead of get '/api/v1/pictures' but that is because the generator i used (rails g integration_test picture) had generated it
[07:12:52] dmarr: um the spec is just trying to hit the index route
[07:13:03] sevenseacat: would you like to show the failing spec?
[07:13:13] dmarr: https://github.com/marr/localpic2/blob/master/spec/requests/pictures_spec.rb
[07:13:36] PedramT: has joined #RubyOnRails
[07:13:37] sevenseacat: so now match that URL to a controller/action with rake routes
[07:14:03] dmarr: first one: api_v1_pictures GET /api/v1/pictures/index(.:format) api/v1/pictures#index
[07:14:09] sevenseacat: no, thats not the same URL
[07:14:37] dmarr: GET /api/v1/pictures(.:format) api/v1/pictures#show
[07:14:57] sevenseacat: now the error is pretty clear, yeah?
[07:15:37] dmarr: that routes file is clearly wrong
[07:15:58] yardenbar: has joined #RubyOnRails
[07:16:08] dmarr: or at least should expect an id for the show route
[07:16:34] sevenseacat: https://github.com/marr/localpic2/blob/master/config/routes.rb#L4 is the problem line.
[07:16:57] sevenseacat: you've defined that you have a single picture in your system
[07:17:08] sevenseacat: therefore it doesnt need an ID
[07:18:05] dmarr: i should have modeled it after https://github.com/hiromipaw/localpic/blob/master/config/routes.rb
[07:18:30] sevenseacat: thats... very repetitive
[07:18:48] sevenseacat: and not a good example of restricting created routes
[07:18:51] dmarr: working through this book http://www.amazon.com/RESTful-Rails-Development-Building-Applications/dp/1491910852?tag=duckduckgo-d-20
[07:19:31] mary5030: has joined #RubyOnRails
[07:19:34] sevenseacat: first review, two stars, oh yeah
[07:20:03] treaki: has joined #RubyOnRails
[07:21:26] dmarr: yeah its like finding an easter egg every time you get through a chapter
[07:21:45] sevenseacat: ACTION checks... yep... R4IA still five stars
[07:21:58] Radar: only 5 star rated Rails book
[07:22:06] quazimodo: has joined #RubyOnRails
[07:22:59] idefine: has joined #RubyOnRails
[07:24:04] edwinvdgraaf: has joined #RubyOnRails
[07:24:17] dextertzu: has joined #RubyOnRails
[07:25:01] PedramT: has joined #RubyOnRails
[07:29:38] dmarr: lol that its an otter on the cover, reminds me of that oatmeal raisin meme
[07:30:00] kies^: has joined #RubyOnRails
[07:32:23] tuelz: has joined #RubyOnRails
[07:32:41] dmarr: http://cl.ly/3P0O2d1L3F2d
[07:35:32] dmarr: sevenseacat: /shrug https://github.com/marr/localpic2/commit/f93a9d01df7646a1d7463fa69bca8484f7672f98
[07:37:43] tvon: has joined #RubyOnRails
[07:38:22] comrad: has joined #RubyOnRails
[07:39:01] dmarr: wtf https://github.com/badges/shields
[07:39:57] sevenseacat: whats so wtf?
[07:40:05] dmarr: http://badges.github.io/http://badges.github.io/
[07:40:21] dmarr: sorry, that url was broken for me, the /badges/shields one
[07:41:14] yfeldblum: has joined #RubyOnRails
[07:41:44] dmarr: does it work for you?
[07:42:03] sevenseacat: i have no idea what you're talking about
[07:42:23] dmarr: https://github.com/badges/shields
[07:42:29] idefine: has joined #RubyOnRails
[07:42:37] dmarr: like, github just crashes on that url for me
[07:42:39] sevenseacat: what about it?
[07:43:09] dmarr: hmm, weird my browser is dying
[07:43:30] dmarr: on just that gh repo it seems
[07:46:10] chouhoulis: has joined #RubyOnRails
[07:47:28] lessless: has joined #RubyOnRails
[07:49:06] Axilla: has joined #RubyOnRails
[07:49:17] Cervajz: has joined #RubyOnRails
[07:49:58] quazimodo: has joined #RubyOnRails
[07:50:31] Cervajz_: has joined #RubyOnRails
[07:51:33] DoubleMalt: has joined #RubyOnRails
[07:52:36] ubiks: has joined #RubyOnRails
[07:56:28] pawnbox: has joined #RubyOnRails
[07:57:27] relix: has joined #RubyOnRails
[07:59:27] Kn|t3: has joined #RubyOnRails
[08:02:48] shibly: has joined #RubyOnRails
[08:03:50] Trynemjoel: has joined #RubyOnRails
[08:05:58] tyrbo: has joined #RubyOnRails
[08:06:16] Hazim: has joined #RubyOnRails
[08:06:27] Jasaka: has joined #RubyOnRails
[08:07:08] shibly: has left #RubyOnRails: ()
[08:09:26] dmarr: is it possible to link an image in an rdoc?
[08:10:12] brupm: has left #RubyOnRails: ("Textual IRC Client: www.textualapp.com")
[08:13:23] Palsson: has joined #RubyOnRails
[08:13:29] Hazim: has joined #RubyOnRails
[08:14:02] darutoko: has joined #RubyOnRails
[08:14:09] VeryBewitching: dmarr: I think it's possible, see: https://github.com/rdoc/rdoc/issues/93
[08:15:23] VeryBewitching: OK, sleepy time, night folks.
[08:17:26] dnewkerk: has joined #RubyOnRails
[08:17:48] lalalaaa: has joined #RubyOnRails
[08:18:16] agit0: has joined #RubyOnRails
[08:19:07] dmarr: night. that doesn't seem to work on GH// oh well
[08:19:30] owenjones: has joined #RubyOnRails
[08:22:03] idefine: has joined #RubyOnRails
[08:23:02] ibouvousaime: has joined #RubyOnRails
[08:25:05] Kn|t3: has joined #RubyOnRails
[08:31:16] Cervajz: has joined #RubyOnRails
[08:32:50] tuelz: has joined #RubyOnRails
[08:37:58] Kn|t3: has joined #RubyOnRails
[08:38:40] mices: i was thinking about using this jquery plugin for dropdown menu but when i hover over their demo link the menu disappears when i move the cursor over them http://dev7studios.com/dropit/#
[08:39:09] mices: maybe this plugin doesn't work
[08:40:11] ibouvousaime: has joined #RubyOnRails
[08:40:23] tbuehlmann: mices, I bet that's because of the space between the button and the menu
[08:40:51] mices: how'd it get there
[08:42:41] mices: it's a blank <ul> tag
[08:43:30] mary5030: has joined #RubyOnRails
[08:43:47] mices: there's a nested list inside the <li> containing the hover me button
[08:44:11] mices: it's there if you wanna add sub-menus i guess
[08:46:03] blackmesa: has joined #RubyOnRails
[08:46:05] tvw: has joined #RubyOnRails
[08:46:19] mices: how do jquery drop down lists behave on mobile touch screen browsers?
[08:46:34] mices: maybe popups are better
[08:46:54] chouhoulis: has joined #RubyOnRails
[08:46:55] sevenseacat: what are you actually trying to do?
[08:47:18] srinidhi: has joined #RubyOnRails
[08:47:43] Kn|t3: has joined #RubyOnRails
[08:47:51] mices: when the user is logged in his name should appear on top as a link to a menu with choices like Profile, Account, Messages
[08:48:25] mices: it just occurred to me, touchscreen devices don't have hover
[08:48:48] Cervajz: has joined #RubyOnRails
[08:48:54] sevenseacat: correct, but a good plugin will use a click for touchscreen devices - look at how bootstrap does their dropdown menus in their navigation bars
[08:49:25] mices: why is bootstrap always referred to as twitter bootstrap
[08:49:38] mices: that's been scaring me away
[08:49:45] sevenseacat: because thats what it used to be called when its creators worked at twitter
[08:50:17] sevenseacat: now one's at github iirc and i dont know where the other is
[08:52:05] edwinvdgraaf: has joined #RubyOnRails
[08:53:27] tibra: has joined #RubyOnRails
[08:55:42] relix: has joined #RubyOnRails
[08:59:09] artto: has joined #RubyOnRails
[09:02:08] shibabu: has joined #RubyOnRails
[09:02:43] ibouvousaime: has joined #RubyOnRails
[09:06:20] tuelz: has joined #RubyOnRails
[09:06:50] LetItSnow-y: has joined #RubyOnRails
[09:07:47] thejamespinto: has joined #RubyOnRails
[09:08:09] agoldboi: has joined #RubyOnRails
[09:09:03] PedramT: has joined #RubyOnRails
[09:10:11] emilkarl_: has joined #RubyOnRails
[09:11:26] jbrhbr: has joined #RubyOnRails
[09:12:23] jbrhbr: has joined #RubyOnRails
[09:17:09] Palsson: has joined #RubyOnRails
[09:17:51] Hazim: has joined #RubyOnRails
[09:23:36] jsrn_: has joined #RubyOnRails
[09:24:11] emilkarl_: has joined #RubyOnRails
[09:25:03] dextertzu: has joined #RubyOnRails
[09:25:27] ur5us: has joined #RubyOnRails
[09:26:08] codehotter: has joined #RubyOnRails
[09:26:45] codehotter: Can I configure log rotation if I have multiple worker processes all writing to the same production.log? How does rotation avoid confusing the other worker processes?
[09:28:22] dnewkerk: has joined #RubyOnRails
[09:28:32] Kn|t3: has joined #RubyOnRails
[09:29:21] waka: has joined #RubyOnRails
[09:30:07] DoubleMalt: has joined #RubyOnRails
[09:30:54] artto: has joined #RubyOnRails
[09:33:47] quazimodo: has joined #RubyOnRails
[09:34:16] alphaatom: has joined #RubyOnRails
[09:34:54] marr: has joined #RubyOnRails
[09:35:45] emilkarl: has left #RubyOnRails: ()
[09:36:04] callumbarratt: has joined #RubyOnRails
[09:41:34] Kn|t3: has joined #RubyOnRails
[09:44:19] bronson: has joined #RubyOnRails
[09:45:54] htmldrum: has joined #RubyOnRails
[09:47:31] codehotter: OK, found it. It locks the file before rotating.
[09:47:39] chouhoulis: has joined #RubyOnRails
[09:48:21] rhizome: has joined #RubyOnRails
[09:50:55] idefine: has joined #RubyOnRails
[09:51:59] blackmesa: has joined #RubyOnRails
[09:52:06] ElFerna: has joined #RubyOnRails
[09:59:25] Sylario: has joined #RubyOnRails
[09:59:26] krz: has joined #RubyOnRails
[10:00:39] krz: has joined #RubyOnRails
[10:01:36] krz: has joined #RubyOnRails
[10:01:43] GreatDanton: has joined #RubyOnRails
[10:01:56] GreatDanton: has joined #RubyOnRails
[10:02:09] srinidhi: has joined #RubyOnRails
[10:03:57] krz: has joined #RubyOnRails
[10:06:16] Kn|t3: has joined #RubyOnRails
[10:07:08] Sceko: has joined #RubyOnRails
[10:07:12] tuelz: has joined #RubyOnRails
[10:07:16] lacrymology: has joined #RubyOnRails
[10:07:52] krz: has joined #RubyOnRails
[10:10:32] pawnbox: has joined #RubyOnRails
[10:11:52] ElFerna: has joined #RubyOnRails
[10:13:05] ibouvousaime: has joined #RubyOnRails
[10:13:20] emilkarl: has joined #RubyOnRails
[10:13:41] ewnd9: has joined #RubyOnRails
[10:15:07] emilkarl_: has joined #RubyOnRails
[10:18:01] dextertzu: has joined #RubyOnRails
[10:18:04] Shlok: has joined #RubyOnRails
[10:20:37] idefine: has joined #RubyOnRails
[10:21:25] rodfersou: has joined #RubyOnRails
[10:21:27] Kn|t3: has joined #RubyOnRails
[10:23:21] shanemcd: has joined #RubyOnRails
[10:24:16] ElFerna: has joined #RubyOnRails
[10:25:18] the_nick_me: has joined #RubyOnRails
[10:27:10] norc: has joined #RubyOnRails
[10:29:37] lubekpl: has joined #RubyOnRails
[10:33:32] ElFerna: has joined #RubyOnRails
[10:37:44] Kn|t3: has joined #RubyOnRails
[10:38:19] nfk|laptop: has joined #RubyOnRails
[10:40:21] idefine: has joined #RubyOnRails
[10:41:08] shibabu: has joined #RubyOnRails
[10:41:40] pawnbox: has joined #RubyOnRails
[10:42:13] Secretmapper: has joined #RubyOnRails
[10:42:34] rgtk: has joined #RubyOnRails
[10:43:47] AzaToth: has joined #RubyOnRails
[10:47:59] moeabdol: has joined #RubyOnRails
[10:48:22] chouhoulis: has joined #RubyOnRails
[10:48:33] Secretmapper: has joined #RubyOnRails
[10:49:32] Detch: has joined #RubyOnRails
[10:50:03] Mia: has joined #RubyOnRails
[10:50:04] Mia: has joined #RubyOnRails
[10:54:30] ql6wlld: has joined #RubyOnRails
[10:54:42] zamerick_: has joined #RubyOnRails
[10:56:26] moeabdol: has joined #RubyOnRails
[10:58:50] greengriminal: has joined #RubyOnRails
[11:01:15] rgtk: has joined #RubyOnRails
[11:03:12] gavit: can anyone help me figure out what's wrong here? https://gist.github.com/gavit/8447bb6528c05696aec7#file-irb-L13
[11:05:41] Cervajz: has joined #RubyOnRails
[11:06:52] blackmesa: has joined #RubyOnRails
[11:07:47] pawnbox: has joined #RubyOnRails
[11:07:57] tuelz: has joined #RubyOnRails
[11:08:49] FooMunki: has joined #RubyOnRails
[11:09:12] Cervajz_: has joined #RubyOnRails
[11:09:16] quazimodo: has joined #RubyOnRails
[11:11:16] pawnbox: has joined #RubyOnRails
[11:11:34] pawnbox: has joined #RubyOnRails
[11:14:20] ElFerna: has joined #RubyOnRails
[11:14:20] htmldrum: has joined #RubyOnRails
[11:19:42] sandstrom: has joined #RubyOnRails
[11:19:59] nfk|laptop: has joined #RubyOnRails
[11:20:11] rubyldn77: has joined #RubyOnRails
[11:20:19] rickmasta: has joined #RubyOnRails
[11:20:43] tibra: has joined #RubyOnRails
[11:23:00] hmarr: has joined #RubyOnRails
[11:23:20] cold_zero: has joined #RubyOnRails
[11:25:13] FooMunki: has joined #RubyOnRails
[11:28:04] mdw: has joined #RubyOnRails
[11:28:38] davout: anyone ever got /Users/david/.rvm/rubies/ruby-2.2.2/lib/ruby/site_ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require': cannot load such file -- bundler/setup (LoadError) ?
[11:28:54] davout: bundler is installed, bundled, rvm reinstalled for the third time
[11:30:12] tbuehlmann: I have no idea, but I'd blame rvm
[11:31:14] PedramT: has joined #RubyOnRails
[11:32:59] Cervajz: has joined #RubyOnRails
[11:35:04] andywww: has joined #RubyOnRails
[11:36:02] emilkarl: has joined #RubyOnRails
[11:37:09] davout: seems like spring's fault
[11:38:16] sevenseacat: i think my laptop is about to catch fire from running my advent of code tests that i just wrote in ruby
[11:38:35] gavit: I blame I dont know who to blame :( https://trac.osgeo.org/geos/ticket/535#comment:36
[11:39:50] wethu: has joined #RubyOnRails
[11:42:34] Hates_: davout: you didn't install bundler in a gemset or anything?
[11:42:59] wopi: has joined #RubyOnRails
[11:44:07] wopi: Hi, How I can get a translation with a passed locale ? I mean something like 'get from I18n the "DE" translation for "sausage"' - without changing the current locale
[11:44:15] c355E3B: has joined #RubyOnRails
[11:45:02] davout: Hates_: nah
[11:45:28] davout: wopi: did you try I18n.t('foods.sausage', locale: :de) ?
[11:46:46] wopi: davout: thx, this optiion is not documented on Apidock (http://apidock.com/rails/v4.2.1/ActionView/Helpers/TranslationHelper/translate), nice.
[11:47:05] PedramT: has joined #RubyOnRails
[11:47:27] Ainieco: has joined #RubyOnRails
[11:47:50] artto: has joined #RubyOnRails
[11:48:38] grn: has joined #RubyOnRails
[11:49:05] chouhoulis: has joined #RubyOnRails
[11:49:11] Ainieco: i'd like to try https://github.com/apotonick/trailblazer but not sure if this is ready for production, what do you think?
[11:51:06] pawnbox: has joined #RubyOnRails
[11:51:10] cold_zero: has joined #RubyOnRails
[11:52:30] tetraktys: has joined #RubyOnRails
[11:52:35] lalalaaa: has joined #RubyOnRails
[11:53:50] sevenseacat: its fairly mature by now
[11:55:05] gavit: when installing the rgeo gem, how do I specify where the header files are?
[11:56:04] norc: How would you name a text column that uniquely identifies a physical network port? "port_identifier?
[11:56:30] sevenseacat: seems reasonable
[11:56:58] pawnbox: has joined #RubyOnRails
[11:57:27] norc: Alright, think Ill go with it then. The underlying protocol calls this "port-id", but I don't really want to break rails naming conventions here. :)
[11:57:54] sevenseacat: definitely a good idea, re: not breaking conventions for the fun of it
[11:58:36] matthewd: Yeah, +1 to not using "_id" for something that isn't an FK
[11:58:50] matthewd: We have some of those in our app, and they can be quite confusing when looking at the schema
[11:59:23] PedramT: has joined #RubyOnRails
[11:59:40] sevenseacat: i've managed to confuse a people when i named a field external_id, meaning it was an identifier from an external db
[11:59:48] sevenseacat: 'but theres no external association!!!! guh!!!!!'
[11:59:56] norc: Yeah. I have an application working with a legacy database schema - I ended up wrapping all tables in views to give them an actual naming convention, following rails style to make Rails magic work out of the box. :)
[12:00:51] norc: The only price I did get for wrapping each table in a view, is that Rails could no longer deduce the primary key for the table in question, but that was a small price to pay. Nothing a simple concern couldn't fix.
[12:00:58] steffkes: has joined #RubyOnRails
[12:00:58] steffkes: has joined #RubyOnRails
[12:01:00] arBmind: has joined #RubyOnRails
[12:01:48] blackhuey: has joined #RubyOnRails
[12:01:52] blackmesa: has joined #RubyOnRails
[12:03:27] gavit: https://gist.github.com/gavit/d93916098648e44f335d#file-gem-install-rgeo-L10 <- how do I specify that the header files are here: ./capi/geos_c.h
[12:03:50] PedramT: has joined #RubyOnRails
[12:04:19] pawnbox: has joined #RubyOnRails
[12:06:22] jsrn_: has joined #RubyOnRails
[12:09:04] tuelz: has joined #RubyOnRails
[12:09:16] idefine: has joined #RubyOnRails
[12:09:16] matthewd: gavit: --with-geos-dir is something else?
[12:10:07] matthewd: gavit: Does mkmf.log contain any clues?
[12:10:30] gavit: matthewd: I'm installing geos from source since the one in my distro has an error
[12:10:50] cold_zero: Hi to all of you. I have a question about environments. I assume that when I write and run migrations, my current environment is development and DB that I'm changing is 'development.sqlite3' (assuming I'm suing it).
[12:10:56] cold_zero: Is it right that when I'm running rspec tests all they running against test.sqlite3 ?
[12:11:10] gavit: --with-geos-dir specifies where the 'compiled' version is
[12:11:12] pawnbox: has joined #RubyOnRails
[12:11:37] matthewd: cold_zero: Yes (assuming nothing weird)
[12:12:07] matthewd: gavit: Check mkmf.log, but I think you'll find it's expecting to find both the headers and the compiled libs there
[12:12:41] cold_zero: matthewd: When i do some changes using migration should I do something like this rake db:migration RAILS_ENV=test ?
[12:12:44] gavit: matthewd: where would I find the mkmf.log? I thought those only got created on succesful installation
[12:13:04] cold_zero: or rake db:seed RAILS_ENV=test ?
[12:13:14] lalalaaa: matthewd: Any relation? https://soundcloud.com/matthewdavid
[12:13:39] sevenseacat: cold_zero: rails will handle that automatically for you. you should never need to manage your test db manually.
[12:13:42] matthewd: cold_zero: Assuming a recent version (4.2?) the test environment should be automatically maintained to keep it in sync with development
[12:13:54] sevenseacat: i think it was 4.1 or 4.2, yeah
[12:14:07] matthewd: lalalaaa: Nope
[12:14:21] zpe: has joined #RubyOnRails
[12:16:31] cold_zero: let me say it again just to make it clear for me. Suppose I did some changes using migration, so I've updated by data model. Next I running rspec to test all I've done. All rspec specs will be ran again test.sqlite3 and this test.sqlite3 is correspond with what I have in development.sqlite3 ?
[12:17:18] matthewd: cold_zero: Yes.
[12:17:24] ElFerna: has joined #RubyOnRails
[12:17:25] sevenseacat: yes, before the tests are run, Rails will make sure the schema of your test db matches your dev db.
[12:17:41] gavit: matthewd: https://gist.github.com/gavit/d93916098648e44f335d#file-mkmf-log-L1 which do you think I should check?
[12:17:51] matthewd: ACTION braces for "ha! but it's not doing that"
[12:17:59] pawnbox: has joined #RubyOnRails
[12:18:18] cold_zero: matthewd and sevenseacat thank you for help :0
[12:18:33] sevenseacat: well to be fair its quite easy to confuse rails so it doesnt do that
[12:18:45] sevenseacat: eg. roll back, edit, then roll forward again
[12:18:58] gavit: based on timestamps its /usr/local/rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/extensions/x86_64-linux/2.2.0/rgeo-0.5.2/mkmf.log
[12:19:11] carlosd: has joined #RubyOnRails
[12:20:03] gavit: matthewd: https://gist.github.com/gavit/d93916098648e44f335d <- maybe its using the wrong dev :(
[12:20:17] damireh: has joined #RubyOnRails
[12:23:08] matthewd: gavit: So, it's looking in /usr/local/include for the headers
[12:23:25] matthewd: *Why* aren't the headers installed next to the lib?
[12:27:57] Hazim: has joined #RubyOnRails
[12:29:06] idefine: has joined #RubyOnRails
[12:30:37] zanzarel: has joined #RubyOnRails
[12:32:57] artto: has joined #RubyOnRails
[12:33:41] alphaatom: has joined #RubyOnRails
[12:33:57] koprom: has joined #RubyOnRails
[12:34:38] sandstrom: has joined #RubyOnRails
[12:36:22] FailBit: what's an ABI without an API
[12:37:01] Papierkorb: a JMP instruction.
[12:40:20] ruid: has joined #RubyOnRails
[12:40:21] ruid: has joined #RubyOnRails
[12:40:23] norc: Mhm, the more I look at ransackers, it seems like there just is not a way to hack DISTINCT ON from PostgreSQL into it. Or has anyone here had success in this area?
[12:42:21] ruid: how can I set an integer limit when I run 'generate scaffold' ? I want to do something like 'rails g scaffhold Model name:string bigvalue:integer{limit: 8}'
[12:44:18] cassioscabral: has joined #RubyOnRails
[12:44:39] norc: ruid: Not sure whether its implemented for integer, but try integer{8}
[12:45:18] damireh: has joined #RubyOnRails
[12:45:36] threeminutemonta: has joined #RubyOnRails
[12:45:44] tetraktys: has joined #RubyOnRails
[12:45:45] gavit: matthewd: cause make install doesn't do that
[12:47:14] bronson: has joined #RubyOnRails
[12:49:53] chouhoulis: has joined #RubyOnRails
[12:50:16] PedramT: has joined #RubyOnRails
[12:52:01] FooMunki: has joined #RubyOnRails
[12:54:33] pawnbox: has joined #RubyOnRails
[12:56:25] pawnbox: has joined #RubyOnRails
[12:58:46] idefine: has joined #RubyOnRails
[12:59:05] tetraktys: has joined #RubyOnRails
[12:59:30] Spami: has joined #RubyOnRails
[12:59:37] emilkarl: has joined #RubyOnRails
[13:03:54] blackmesa: has joined #RubyOnRails
[13:04:38] shlok_: has joined #RubyOnRails
[13:04:57] conta: has joined #RubyOnRails
[13:05:12] PlasmaStar: has joined #RubyOnRails
[13:05:17] wethu: has joined #RubyOnRails
[13:06:52] symbol: has joined #RubyOnRails
[13:07:58] nocd: has joined #RubyOnRails
[13:08:33] tetraktys: has joined #RubyOnRails
[13:09:29] crunk_bear: has joined #RubyOnRails
[13:09:51] yardenbar: has joined #RubyOnRails
[13:09:52] tuelz: has joined #RubyOnRails
[13:11:56] dideler: has joined #RubyOnRails
[13:14:24] Megamos: has joined #RubyOnRails
[13:15:47] bbrowning: has joined #RubyOnRails
[13:16:03] dstarh: has joined #RubyOnRails
[13:18:16] d0nn1e: has joined #RubyOnRails
[13:18:31] idefine: has joined #RubyOnRails
[13:22:23] Kn|t3: has joined #RubyOnRails
[13:23:45] atomical: has joined #RubyOnRails
[13:24:16] Palsson: has joined #RubyOnRails
[13:24:42] Encapsulation: has joined #RubyOnRails
[13:27:01] tuelz: has joined #RubyOnRails
[13:27:27] tetraktys: has joined #RubyOnRails
[13:28:06] norc: How can I eager load an association with ransack?
[13:29:17] norc: Ahh, nevermind. Figured it out, just appending .includes to the result does the trick. :)
[13:29:36] the_nick_me: has joined #RubyOnRails
[13:31:15] corioliss: has joined #RubyOnRails
[13:36:51] owenjones: has joined #RubyOnRails
[13:37:14] mdw7: has joined #RubyOnRails
[13:37:56] ruid: has joined #RubyOnRails
[13:37:57] ruid: has joined #RubyOnRails
[13:39:42] rickmasta: has joined #RubyOnRails
[13:40:23] zpe: has joined #RubyOnRails
[13:40:40] _Tariq: has joined #RubyOnRails
[13:43:57] mlangenberg: has joined #RubyOnRails
[13:44:36] LambdaSource: has joined #RubyOnRails
[13:47:03] hardtail: has joined #RubyOnRails
[13:48:10] idefine: has joined #RubyOnRails
[13:48:39] tetraktys: has joined #RubyOnRails
[13:49:13] ramortegui: has joined #RubyOnRails
[13:49:43] Pazician: has joined #RubyOnRails
[13:50:38] chouhoulis: has joined #RubyOnRails
[13:53:28] sandstrom: has joined #RubyOnRails
[13:54:46] shanemcd: has joined #RubyOnRails
[13:55:19] johnnegron: has joined #RubyOnRails
[13:57:49] cassioscabral: has joined #RubyOnRails
[13:58:49] rejeep: has joined #RubyOnRails
[14:02:39] snowy: has joined #RubyOnRails
[14:03:59] shibabu: has joined #RubyOnRails
[14:04:01] rodfersou|lunch: has joined #RubyOnRails
[14:05:43] lacrymology: has joined #RubyOnRails
[14:07:35] ubiks: Hi, I'm getting "ActionController::ParameterMissing (param is missing or the value is empty" and can't figure how to solve the update function. It is a custom controller calling to the User model. I gisted the form, the methods and the error prompt: https://gist.github.com/UbikTransmedia/e1ed548aabaf5b92edbe May you please help me? Going to look for a solution in the menawhile...
[14:07:53] idefine: has joined #RubyOnRails
[14:08:17] shibly: has joined #RubyOnRails
[14:10:30] Kn|t3: has joined #RubyOnRails
[14:13:09] ubiks: this line is triggering the err: params.require(current_user).permit(:name)
[14:13:55] ddv: ubiks, because you are not a providing a model object to form_for
[14:14:17] ubiks: ddv, I changed the line now by form_for @user, :url => user_edit_path, :html => {:method => :post}
[14:14:20] ubiks: same result
[14:14:45] ddv: ubiks, yes because thats totally wrong
[14:14:58] shibly: ActionView::Template::Error (couldn't find file 'jquery' with type 'application/javascript'):
[14:15:46] shibly: Removed Gemfile.lock
[14:15:49] shibly: sevenseacat: ^
[14:16:13] ubiks: shibly, have you checked that the template tags point to 'application'?
[14:16:18] sevenseacat: shibly: do you have the app up on github somewhere we can check out?
[14:16:58] shibly: https://gist.github.com/anonymous/d2a8d82311a070c85d27
[14:17:18] PedramT: has joined #RubyOnRails
[14:18:04] pyemkey: has joined #RubyOnRails
[14:18:28] ubiks: ddv, it works in many ways; the issue happens when it comes to eval params.require
[14:19:04] doodlehaus: has joined #RubyOnRails
[14:19:24] shibly: https://gist.github.com/anonymous/1e6c1ae35113d89c2a53
[14:19:52] shibly: sevenseacat: It's empty app
[14:20:05] sevenseacat: shibly: saying that doesnt help us replicate your problem.
[14:20:23] carlosd: has joined #RubyOnRails
[14:20:43] jmignault: has joined #RubyOnRails
[14:21:52] shibly: None get a solution of my problem?
[14:22:21] shibly: I have jquery installed
[14:22:23] sevenseacat: shibly: can you put your app up on github for us to check out?
[14:23:35] sevenseacat: because I just created a brand new rails 4.2.5 app, and am not getting that problem. so it's something in your app or something in your environment. us seeing your code would rule out one of those two things.
[14:26:27] darutoko: has joined #RubyOnRails
[14:27:10] moeabdol: has joined #RubyOnRails
[14:27:20] shibly: sevenseacat: Can you give me your email account? git configuration will take time
[14:27:50] pawnbox: has joined #RubyOnRails
[14:28:21] pyemkey: heello :) What is efficient way to check if one range of time contains a subset of another one. I'm not sure if my desciption is clear enough. Let's make my code speak more :) https://gist.github.com/pyemkey/40f2cc7f0ceb82b6431e
[14:28:42] artto: has joined #RubyOnRails
[14:29:57] the_nick_me: has joined #RubyOnRails
[14:32:00] Ainieco: has joined #RubyOnRails
[14:33:59] Ainieco: naming convention in trailblazer is horrible when it's used with rails because its names conflict with model names...
[14:34:00] Hates_: pyemkey: maybe overlaps? http://apidock.com/rails/Range/overlaps
[14:34:13] Ainieco: that stuff simply wont work http://trailblazer.to/gems/operation/collection.html because of that
[14:34:33] rodfersou: has joined #RubyOnRails
[14:34:38] sevenseacat: how does that work? given trailblazer is supposed to sit on top of rails
[14:35:26] matthewd: Ainieco: Looks fine to me ??\_(???)_/??
[14:35:39] the_nick_me: has joined #RubyOnRails
[14:35:48] Ainieco: sevenseacat: it doesn't work, there are workaround like https://github.com/apotonick/gemgem-trbrb/blob/master/app/concepts/comment/operation.rb#L1 but in rails 4.2.5 it give superclass mismatch for some reason
[14:36:01] pawnbox: has joined #RubyOnRails
[14:36:10] ubiks: Okay, I found a solution to my problem passing arguments from a form_for into a different controller than the model it updated ^__^ https://gist.github.com/UbikTransmedia/a9e3aa230b72752f2eee
[14:38:12] tuelz: has joined #RubyOnRails
[14:38:51] agoldboi: has joined #RubyOnRails
[14:39:35] zanzarel: sevenseacat: I did as you told me and avoided generating scaffolds, in case you where wondering
[14:39:46] sevenseacat: good-o :) glad to hear it
[14:40:13] pyemkey: Hates_: thanks a lot. This is what I looked for.
[14:41:12] crunk_bear: has joined #RubyOnRails
[14:41:21] conta: has joined #RubyOnRails
[14:49:10] Megamos: has joined #RubyOnRails
[14:50:08] shanemcd: has joined #RubyOnRails
[14:50:42] bronson: has joined #RubyOnRails
[14:51:22] chouhoulis: has joined #RubyOnRails
[14:53:37] gaustin_: has joined #RubyOnRails
[14:54:06] Pazician: has joined #RubyOnRails
[14:54:44] krz: has joined #RubyOnRails
[14:56:56] atomical_: has joined #RubyOnRails
[15:02:56] cornerman: has joined #RubyOnRails
[15:06:50] smathy: has joined #RubyOnRails
[15:06:51] shanemcd: has joined #RubyOnRails
[15:07:52] zanzarel: I'm using the 'twitter' gem, I would like to create a first instance of the client in the config/initializers/twitter.rb and then re-use the bearer token obtained in this way. Is it a good practice/is it feasible to do it this way?
[15:09:50] mices: i'm trying to get the jquery plugin dropit to work, i got a long list of errors from the console https://gist.github.com/mices/fd162ba87c24957f8359
[15:10:17] ibouvousaime: has joined #RubyOnRails
[15:10:28] atomical: has joined #RubyOnRails
[15:13:47] tibra: has joined #RubyOnRails
[15:15:00] zanzarel: more generically, in order for an object created in config/initializers/something.rb must the variable be global or is there another way that I'm not aware of?
[15:16:33] owenjones: has joined #RubyOnRails
[15:17:26] axl_: has joined #RubyOnRails
[15:20:30] norc: Okay, so is there any reason to use HAML over slim?
[15:20:54] greenhat: has joined #RubyOnRails
[15:24:57] steffkes: has joined #RubyOnRails
[15:24:57] steffkes: has joined #RubyOnRails
[15:25:49] StevenXL: has joined #RubyOnRails
[15:25:49] StevenXL: has joined #RubyOnRails
[15:26:05] stannard: has joined #RubyOnRails
[15:27:15] B1n4r10: has joined #RubyOnRails
[15:27:33] ibouvousaime_: has joined #RubyOnRails
[15:29:04] shibly: sevenseacat: https://github.com/shiblystory/rails-test
[15:29:32] sevenseacat: k, let me have a look
[15:31:04] sevenseacat: shibly: ok, so the problem isnt in your code, because i dont get that error. so its somewhere in your environment.
[15:31:32] shibly: sevenseacat: Is it running on your machine corrctly?
[15:31:38] sevenseacat: thats what i just said, yes.
[15:31:43] sevenseacat: shibly: what js runtime are you using?
[15:31:45] mrtomme: has joined #RubyOnRails
[15:31:54] shibly: run http://localhost:3000/welcome/index
[15:32:29] shibly: It's gem 'jquery-rails'
[15:32:38] sevenseacat: thats not a js runtime.
[15:32:47] sevenseacat: you must have something like nodejs installed
[15:32:55] shibly: Any problem with http://localhost:3000/welcome/index
[15:33:01] sevenseacat: shibly: for the fourth time, no.
[15:33:16] sevenseacat: can you answer *my* question now?
[15:33:22] CornishPasty: Hey sevenseacat
[15:33:22] shibly: How would i know about js runtime?
[15:33:29] sevenseacat: shibly: well, you installed it, so
[15:33:33] CornishPasty: How many cats do you have out of the sea?
[15:33:33] sevenseacat: CornishPasty: evening
[15:33:36] sevenseacat: CornishPasty: two.
[15:33:41] shibly: How did i install it?
[15:33:51] sevenseacat: shibly: how on earth should i know?
[15:33:54] sevenseacat: its your machine
[15:34:07] sandstrom: has joined #RubyOnRails
[15:34:17] CornishPasty: sevenseacat: is this a regular occurrence? :(
[15:34:24] sevenseacat: CornishPasty: sadly, yes.
[15:34:34] sevenseacat: this problem has been going on for about three days now.
[15:35:46] cassioscabral: has joined #RubyOnRails
[15:35:56] shibly: How would i know which js runtime has been installed?
[15:36:02] the_nick_me: has joined #RubyOnRails
[15:36:05] shibly: Where is it installed on my machine?
[15:36:36] sevenseacat: https://github.com/sstephenson/execjs#execjs you installed one of these things. i do not know which one, or where you installed it.
[15:36:49] JakFrist: has joined #RubyOnRails
[15:36:51] sevenseacat: i suspect the problem lies there, however.
[15:36:52] idefine: has joined #RubyOnRails
[15:37:06] sevenseacat: shibly: i cannot teach you how to use a computer.
[15:37:06] MaDErroR123: has joined #RubyOnRails
[15:37:51] shibly: I didn't run: gem install execjs
[15:37:52] smathy: shibly, what's your issue?
[15:38:00] sevenseacat: no, you didnt. thats a dependency of rails.
[15:38:59] shibly: smathy: http://stackoverflow.com/questions/34427834/sprocketsfilenotfound-in-welcomeindex?noredirect=1#comment56608657_34427834
[15:39:14] shibly: http://stackoverflow.com/questions/34427834/sprocketsfilenotfound-in-welcomeindex
[15:39:18] shibly: smathy: ^
[15:41:01] zpe: has joined #RubyOnRails
[15:41:58] Kn|t3: has joined #RubyOnRails
[15:43:00] smathy: shibly, do you have any files under public/assets ?
[15:43:24] conta: has joined #RubyOnRails
[15:43:31] shibly: smathy: No
[15:45:16] lacrymology: has joined #RubyOnRails
[15:45:51] adavia: has joined #RubyOnRails
[15:48:37] yardenbar: has joined #RubyOnRails
[15:49:18] Bloomer: has joined #RubyOnRails
[15:49:27] smathy: shibly, what output do you get if you run: bundle list jquery-rails
[15:51:12] shibly: smathy: /home/shibly/.gem/ruby/2.2.4/gems/jquery-rails-4.0.5
[15:51:29] shibly: smathy: But it looks jquery-rails-4.0.5 has empty code
[15:52:08] chouhoulis: has joined #RubyOnRails
[15:52:21] sevenseacat: 'empty code in lib'?
[15:52:36] smathy: shibly, you mean there's nothing in /home/shibly/.gem/ruby/2.2.4/gems/jquery-rails-4.0.5/lib ?
[15:53:20] smathy: shibly, if so then: `rm -rf /home/shibly/.gem/ruby/2.2.4/gems/jquery-rails-4.0.5` and then `bundle install` again.
[15:54:05] shibly: smathy: There is files in vendor/assets/ , but they are empty, no code in those files
[15:54:10] shibly: jquery.js is empty
[15:54:56] smathy: shibly, ok, remove the whole dir as I explained above and `bundle install` again.
[15:55:15] mag42c: has joined #RubyOnRails
[15:56:07] sevenseacat: so how does bundler work out that a gem is 'installed' then, if it either got installed incorrectly (or got stuffed with by a user)?
[15:56:27] shibly: smathy: This time jquery-rails is not there: https://gist.github.com/shiblystory/54343491209692a93816
[15:56:39] sevenseacat: https://gist.github.com/shiblystory/54343491209692a93816#file-gistfile1-txt-L50
[15:57:02] conta: has joined #RubyOnRails
[15:57:02] smathy: shibly, you didn't remove the dir as I explained to do.
[15:57:13] smathy: shibly, please FIRST run: rm -rf /home/shibly/.gem/ruby/2.2.4/gems/jquery-rails-4.0.5
[15:57:17] Cervajz: has joined #RubyOnRails
[15:57:22] smathy: shibly, and THEN run `bundle install`
[15:57:23] shibly: rm -rf jquery-rails-4.0.5/
[15:57:39] smathy: shibly, that's not what I said to run, I don't know what dir you're in.
[15:59:07] shibly: jquery-rails is not in /home/shibly/.gem/ruby/2.2.4/gems now
[15:59:40] shibly: bundle install isn't downloading and installing jquery-rails but it is listing jquery-rails 4.0.5, interesting
[16:00:12] smathy: shibly, so now re-run `bundle list jquery-rails` and what dir is output?
[16:01:05] shanemcd_: has joined #RubyOnRails
[16:01:09] shibly: The gem jquery-rails has been deleted. It was installed at:
[16:01:10] shibly: /home/shibly/.gem/ruby/2.2.4/gems/jquery-rails-4.0.5
[16:01:44] shibly: There is no folder named jquery-rails-4.0.5 in /home/shibly/.gem/ruby/2.2.4/gems
[16:01:53] smathy: shibly, not what I asked.
[16:02:01] smathy: shibly, oh, is that what was output?
[16:02:16] smathy: shibly, ah, sorry, I misunderstood.
[16:02:44] agit0: has joined #RubyOnRails
[16:02:59] smathy: shibly, just run `spring stop` for me, I can't imagine how it would impact this, but just inc ase.
[16:03:52] PedramT: has joined #RubyOnRails
[16:04:35] shibly: shibly@mybox:~/blog$ gem install jquery-rails
[16:04:36] shibly: ERROR: Error installing jquery-rails: invalid gem: package metadata is missing in /home/shibly/.gem/ruby/2.2.4/cache/jquery-rails-4.0.5.gem
[16:04:39] shibabu: has joined #RubyOnRails
[16:05:02] shibly: Spring is not running
[16:05:46] smathy: shibly, delete that cached .gem file.
[16:06:08] lacuna: has joined #RubyOnRails
[16:06:09] lacuna: has joined #RubyOnRails
[16:06:22] shibly: Are you telling me to delete /home/shibly/.gem
[16:07:19] Abhijit: has joined #RubyOnRails
[16:07:25] Abhijit: can i ask gem install question?
[16:07:32] Abhijit: ruby is not active.
[16:07:48] smathy: shibly, no, delete /home/shibly/.gem/ruby/2.2.4/cache/jquery-rails-4.0.5.gem
[16:08:03] Yomero3: has joined #RubyOnRails
[16:08:24] shibly: smathy: I did, still bundle install listing jquery-rails
[16:08:39] smathy: shibly, what about gem install ?
[16:09:54] shibly: smathy: gem install jquery-rails has installed it successfully
[16:10:13] smathy: shibly, ok cool, and you don't get that error you described in your SO post now?
[16:11:20] smathy: shibly, tell me, do you have either a .bundle or vendor/cache directory in your app directory?
[16:11:47] shanemcd: has joined #RubyOnRails
[16:11:57] shibly: Now i am getting error with turbolink, couldn't find file 'turbolinks' with type 'application/javascript'
[16:12:13] sevenseacat: probably the same issue.
[16:12:24] ElFerna: has joined #RubyOnRails
[16:12:36] agit0: has joined #RubyOnRails
[16:14:13] doodlehaus: has joined #RubyOnRails
[16:15:07] smathy: shibly, yeah, check the contents of the `bundle list turbolinks` directory.
[16:15:37] smathy: shibly, at this point you may want to just delete all your gems, looks like you downloaded some duds somehow.
[16:17:01] tubbo: ^ usually what i do when i have major confusion
[16:17:19] tubbo: happens all the time when you change ruby versions, because some gems have their native extensions compiled for an older version, and then havoc (segfaults) ensues
[16:17:36] smathy: I still don't understand why bundler was confused, I never got an answer to my questions about .bundle or vendor/cache dirs.
[16:17:42] tubbo: which is why my BUNDLE_PATH is set to vendor/bundle, so i can rm -rf vendor/bundle when i want to blow away my gems and reinstall everything
[16:17:58] smathy: tubbo, huh? The native extensions should be in the versioned gems dir.
[16:18:22] tubbo: not the json gem
[16:18:25] tubbo: that comes with ruby
[16:18:36] smathy: tubbo, you're just using your system ruby?
[16:18:39] tubbo: which is typically the one that segfaults
[16:18:58] franzip: has joined #RubyOnRails
[16:19:00] tbuehlmann: what am I doing differently? never had problems with native extensions or messed up gems between ruby versions
[16:19:17] tbuehlmann: you and your fun times..
[16:19:18] tubbo: nah, it's when like i generate a rails app on e.g. 2.1, then i upgrade to 2.2.2 without reinstalling gems.
[16:19:22] shibly: Now got new error: Could not find a JavaScript runtime. See https://github.com/rails/execjs for a list of available runtimes
[16:19:32] FailBit: I understand that AS has a .ago thing for dates (e.g. 10.days.ago)
[16:19:32] tubbo: tbuehlmann: it's purely a PEBKAC error, don't get me wrong :P
[16:19:35] FailBit: does it have one for future dates?
[16:19:40] tubbo: FailBit: .from_now
[16:19:51] smathy: tubbo, if I didn't reinstall the gems then the app wouldn't work because rbenv wouldn't have the gems in the 2.2.2 directory.
[16:19:51] tbuehlmann: you and your PEBKAC fun times..
[16:20:11] smathy: tubbo, ie. my JSON native stuff is under ~/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/json-1.8.3/ext for this version of ruby.
[16:20:22] tubbo: smathy: ah, ok. i don't install gems to the global GEM_HOME when i use bundler.
[16:20:25] havenwood: shibly: Did you follow those instructions and install on one of the supported runtimes?
[16:20:46] tubbo: i prefer having everything in the same dir as my app
[16:20:49] smathy: tubbo, yeah, if you package your gems you'd need to redo them.
[16:20:54] FailBit: shibly: you have to have node installed or therubyracer gem'd
[16:21:03] kies^: has joined #RubyOnRails
[16:21:04] tubbo: i don't package them, i just changed the BUNDLE_PATH to always be relative to my working dir
[16:21:16] smathy: shibly, I assume you don't need our help to click on that link?
[16:21:31] tubbo: it just uses the same dir name as `bundle install --deployment` so i can add 1 dir to my gitignore
[16:21:56] tubbo: the other advantage i get from doing that is my `ctags -R .` command includes not only my app, but all of my installed gems as well.
[16:21:58] smathy: tubbo, right, which is basically what packaging gems does :)
[16:22:14] shibly: FailBit: Do i have to add gem 'therubyracer' in Gemfile then bundle install or gem install therubyracer ?
[16:22:25] FailBit: it has to be in your gemfile
[16:22:43] tubbo: smathy: sort-of, but `bundle package` itself will copy the .gem files into vendor/cache and install from there as if it was the gem *server*.
[16:23:03] shibly: FailBit: It's commented: # gem 'therubyracer', platforms: :ruby
[16:23:19] FailBit: so then what do you do...
[16:23:20] havenwood: shibly: Or install Node or one of the other supported runtims.
[16:23:28] tubbo: shibly: i typically stay away from rubyracer because i never need it. if you're on OS X or Windows, you don't need it. if you have nodejs installed, you don't need it.
[16:23:30] smathy: tubbo, heh, I just added `bundle list --paths` to my ctags alias :)
[16:23:45] arup_r: has joined #RubyOnRails
[16:23:45] tubbo: smathy: ah, that's not a bad idea
[16:23:54] havenwood: shibly: Do you have a reason to not install Node?
[16:24:06] smathy: (actually a function, not an alias)
[16:24:32] shibly: gem install nodejs?
[16:24:42] FailBit: no, system package manager
[16:24:47] FailBit: apt-get install nodejs
[16:24:49] smathy: tubbo, https://github.com/smathy/.dotfiles/blob/master/.functions#L44-L56
[16:24:54] havenwood: shibly: Install it with your package manager. Read up here: https://nodejs.org/en/
[16:26:15] tubbo: smathy: yeah baby https://github.com/smathy/.dotfiles/blob/master/.rails/template.rb#L25
[16:26:24] tubbo: foundation > bootstrap
[16:27:41] atomical_: has joined #RubyOnRails
[16:28:05] tbuehlmann: with that statement you convinced me to try foundation for the next app I'm writing
[16:28:35] lacuna: has joined #RubyOnRails
[16:28:35] lacuna: has joined #RubyOnRails
[16:28:56] tubbo: tbuehlmann: living that thought leader life
[16:29:00] Hates_: I find foundation and bootstrap seem to leepfrog each other
[16:29:02] fox_mulder_cp: tbuehlmann: you can see at http://www.apppie.org/pages/toolkit/components.html
[16:29:22] fox_mulder_cp: i think use it in my app
[16:29:38] tubbo: yeah they do, it's all good i just don't meet a lot of people who know about it/use it
[16:29:38] sevenseacat: i find bootstrap the lesser (and better looking) of two evils.
[16:29:59] shibly: I have installed nodejs: sudo aptitude install nodejs then gem install execjs, that solves the problem.
[16:30:23] tubbo: yeah so, bootstrap has a lot more people working on it and they have actually evolved much faster than foundation, because foundation is mostly just zurb.
[16:30:35] shibly: But i didn't add gem 'execjs' in Gemfile
[16:30:47] sevenseacat: shibly: again, execjs is a dependency of rails.
[16:30:52] tbuehlmann: shibly, when nodejs is installed on your system, you don't need anything else, you're done
[16:30:53] shibly: smathy: Thank you for your answers
[16:30:58] polishdub: has joined #RubyOnRails
[16:30:58] tubbo: when foundation came out, it was way beyond bootstrap's capabilities, the responsive-first design was really cool. bootstrap (before the rewrite) always felt clunky implementing responsive CSS.
[16:31:18] tubbo: but there's been so much work done on bootstrap and it's in use in so many places
[16:31:33] shibly: tbuehlmann: Without execjs i got error: Loading problem execjs
[16:31:38] tubbo: i still think foundation is more "complete", but bootstrap is what i would start with to build my own UI framework.
[16:31:45] sevenseacat: smathy: i'm glad you sorted that out - i was quite tired of hearing about it. now can you fix gavit's rgeo problem? :D
[16:32:13] fox_mulder_cp: so, about bootstrap - i know very good admin panel - adminlte.
[16:32:28] fox_mulder_cp: but bootstrap has one minus - jquery
[16:32:36] chouhoulis: has joined #RubyOnRails
[16:32:45] tubbo: shibly: you seem to be missing quite a few gems. i feel like you should try reinstalling with `bundle install` or something.
[16:32:47] sevenseacat: i like bootswatch theming.
[16:33:05] shibly: tubbo: What am i missing?
[16:33:09] havenwood: I'd swear I said to install Node days ago!
[16:33:19] sevenseacat: you probably did.
[16:33:21] havenwood: shibly: Did you install Node?
[16:33:30] tubbo: shibly: well execjs comes with rails. getting a LoadError on execjs means that something went really wrong.
[16:33:41] chouhoulis: has joined #RubyOnRails
[16:33:50] havenwood: shibly: Turn it off and turn it back on again.
[16:34:08] tubbo: fox_mulder_cp: what's wrong with jquery? :)
[16:34:30] tubbo: also, foundation uses jquery IIRC so that argument is kinda moot anyway
[16:34:44] andrmrtmr: has joined #RubyOnRails
[16:34:45] sevenseacat: most frameworks do.
[16:35:17] smathy: shibly, you're welcome.
[16:35:36] tubbo: MS needs to just push an update to IE8 that crashes it every time so people will update and we can stop arguing about frameworks ;)
[16:36:03] tubbo: document.querySelectorAll(), fetch(), grid/flexbox ftw
[16:36:17] shibly: tubbo: Istalling execjs with gem install execs solves the problem of "LoadError on execjs"
[16:36:38] tubbo: shibly: i know that, but it doesn't solve the problem of why that happened in the first place.
[16:36:44] nfk|laptop: has joined #RubyOnRails
[16:36:53] sevenseacat: shibly: something is very wrong with your system.
[16:37:01] tubbo: which seems to be the root issue here
[16:37:16] tubbo: (that is, some gems didn't install correctly)
[16:37:50] fox_mulder_cp: tubbo: now i see tendetion to drop jquery from projects. plain js/coffee/type ..
[16:37:56] shibly: sevenseacat: jquery-rails and turbolinks were there but they have no code in files, it is blank file
[16:38:00] Oliphaunte: has joined #RubyOnRails
[16:38:07] sevenseacat: shibly: yes, i know.
[16:38:18] shibly: That was strange problem
[16:38:37] smathy: shibly, yes, feels like your bundler is broken somehow.
[16:38:56] smathy: shibly, I wonder what version of bundler you have installed?
[16:39:38] tubbo: fox_mulder_cp: i have not noticed that in projects designed to be run on most browsers. unfortunately, the DOM APIs are still too fragmented to work with directly, hence the use of frameworks
[16:40:04] tubbo: jQuery isn't the only one, but most people use *some* framework unless they're building for 1 platform only, like if you're using Electron to make an OS X/iOS app.
[16:40:42] Contigi: has joined #RubyOnRails
[16:42:45] shibly: sevenseacat: You blindly downvoted this: http://stackoverflow.com/questions/34427834/sprocketsfilenotfound-in-welcomeindex , you can upvote that now.
[16:42:58] shibly: I have added comment for future help
[16:43:09] smathy: shibly, not just downvoted, but closed as a duplicate of something it wasn't. Welcome to SO.
[16:43:12] owenjones: has joined #RubyOnRails
[16:43:48] bradleyprice: has joined #RubyOnRails
[16:43:55] sevenseacat: I voted to close it and downvoted it days ago, because you refused to give any information aobut your problem that wasnt in the existing question
[16:43:56] smathy: shibly, your bundler is still broken, FWIW.
[16:44:02] sevenseacat: you refused to even read the answer to the other question
[16:44:48] Rodya_: has joined #RubyOnRails
[16:44:57] shibly: I have these bundle (0.0.1)
[16:44:58] shibly: bundler (1.11.2)
[16:45:12] shibly: smathy: What's the difference between bundle and bundler?
[16:45:36] CornishPasty: I don't like chruby as much as rbenv :(
[16:45:37] smathy: shibly's original question showed they had jquery in their manifest, it was never a dupe of the one linked.
[16:45:51] sevenseacat: and the downvote comment says 'this question does not show any research effort' which pretty much sums up the entire last three days.
[16:45:54] smathy: shibly, bundle is the command, bundler is the gem.
[16:46:25] _Tariq: has joined #RubyOnRails
[16:46:30] shibly: smathy: gem list lists bundle, it is also a gem i think.
[16:46:44] havenwood: CornishPasty: Then keep tending your garden of shims!
[16:46:45] qejk: has joined #RubyOnRails
[16:46:47] sevenseacat: smathy: the dupe also says that.
[16:47:02] smathy: shibly, oh I see, https://rubygems.org/gems/bundle looks like someone added it to help people who typo'd the name. You should remove it.
[16:47:06] shibly: smathy: "bundle install" doing that do we run bundle or bundler?
[16:47:31] smathy: sevenseacat, no it doesn't.
[16:47:50] sevenseacat: couldn't find file 'jquery' (in /Users/azimmer/rails_projects/sample_app/app/assets/javascripts/application.js:13)
[16:48:11] tuelz: has joined #RubyOnRails
[16:48:32] CornishPasty: havenwood: meh, small price to pay for the ease of use of rbenv over chruby
[16:48:34] arup_r: problem with SO, there are many people do just house keeping. People having no knowledge also comes to close the question when they see in their been.. That's just a frustating..
[16:48:42] havenwood: CornishPasty: What ease?
[16:48:48] CornishPasty: chruby doesn't even seem to notice when you install a ruby...
[16:49:02] smathy: sevenseacat, we'd have so many fewer of these problems if you read what I write closer, "shibly's original question showed they had jquery in their *manifest*"
[16:49:14] disgrntld: has joined #RubyOnRails
[16:49:43] smathy: sevenseacat, the extracted source shows that they already had `//= require jquery` in the application.js - which was the error in the dupe you linked to.
[16:49:48] sevenseacat: just because i think you're wrong, doesnt mean i didnt read what you said.
[16:49:52] sevenseacat: no, it was not.
[16:49:56] sevenseacat: read the answer more carefully.
[16:50:12] rgtk: has joined #RubyOnRails
[16:50:18] claytonzaugg: has joined #RubyOnRails
[16:50:43] shibly: smathy: How can i fix bundler?
[16:50:50] Kn|t3: has joined #RubyOnRails
[16:51:20] sevenseacat: anyway, was only hanging around to see if shibly's problem finally got solved, now i can sleep :)
[16:52:04] smathy: sevenseacat, "Add the following lines to the app/assets/javascripts/application.js file" and "Update your Gemfile as below: jquery-rails..." - first was in the original, second was added 13 hours ago. Point is that it was not a duplicate unless you had confirmed the gems were missing from Gemfile, which you didn't.
[16:52:08] ascarter: has joined #RubyOnRails
[16:53:10] smathy: shibly, I asked earlier if you had .bundle or vendor/cache directories in your app?
[16:53:16] smathy: (not sure if you answered)
[16:53:22] arup_r: agreed. And reopened it shibly ..
[16:53:30] Palsson: has joined #RubyOnRails
[16:53:57] CornishPasty: havenwood: Why is this a thing? https://gist.github.com/wizardfrag/cb3f847698f86f5285b3
[16:54:02] atomical: has joined #RubyOnRails
[16:54:28] shibly: arup_r: Can you upvote one?
[16:54:38] shibly: smathy: I did: gem uninstall bundle
[16:54:39] arup_r: nah.. :) Why ..
[16:54:56] shibly: arup_r: It is downvoted -1
[16:55:13] arup_r: don't look at it and look at your problem and fix it..
[16:55:16] shibly: smathy: How can i fix bundler?
[16:55:29] shibly: arup_r: http://stackoverflow.com/questions/34427834/sprocketsfilenotfound-in-welcomeindex
[16:55:51] havenwood: CornishPasty: Because we don't want interdependency between ruby-install and chruby. Do you prefer to do something every time you install a Ruby or every time you install a Gem? I install gems far more often.
[16:56:09] smathy: shibly, I can't help you if you ignore my questions. Good luck.
[16:56:17] CornishPasty: havenwood: I'd prefer chruby to look in the folder when I ask it for a list of rubies...
[16:56:20] havenwood: CornishPasty: It's possible to "fix" in a dozen lines, but that adds a tenth more code. Is it worht it?
[16:56:22] shibly: smathy: What was your question?
[16:56:22] CornishPasty: Rather than needing to restart my shell
[16:56:28] havenwood: CornishPasty: That would be slow.
[16:56:34] havenwood: CornishPasty: Speed is a priority.
[16:56:36] smathy: shibly, I've asked it twice now, I won't ask it thrice.
[16:56:39] CornishPasty: havenwood: I'm on an SSD, I don't care about slow
[16:56:44] the_nick_me: has joined #RubyOnRails
[16:56:55] shibly: smathy: .bundle or vendor/cache directories in your app? I didn't understand it.
[16:57:05] shibly: I didn't understand the question
[16:57:29] arup_r: shibly: go to your project root dir and do `ls -al` and see if it there or not
[16:57:36] smathy: shibly, so you just ignored it? Wow. So, what about the question do you not understand?
[16:57:38] conta: has joined #RubyOnRails
[16:57:50] shibly: shibly@mybox:~/blog$ bundle list bundle
[16:57:50] shibly: /home/shibly/.gem/ruby/2.2.4/gems/bundler-1.11.2
[16:57:52] smathy: arup_r, that won't answer the second dir.
[16:58:36] smathy: shibly, ok, sorry, that's so useless and so far away from what I asked that I really think you need to learn more about computers before I'll be able to help you.
[16:58:56] arup_r: shibly: then run the command `tree .` from your root dir ..
[16:59:02] arup_r: smathy: sorry :)
[16:59:17] CornishPasty: havenwood: is there a way to refresh the list of rubies?
[16:59:24] smathy: shibly, this bundler issue may be a really complex one, and if you don't understand what my question means, or how to ask for clarification, then we're just not going to get there.
[16:59:32] CornishPasty: like "rbenv rehash"
[16:59:39] CornishPasty: Erm, "chruby rehash"*
[17:01:05] tbuehlmann: CornishPasty, you could try `source /usr/local/share/chruby/chruby.sh` or simply open another terminal window
[17:01:21] havenwood: CornishPasty: I do have a branch that's tentatively planned to be merged that extracts populating RUBIES into a function. Right now re-sourcing is the only way unless you want to add it to RUBIES yourself.
[17:01:56] shibly: smathy: No vendor/cache directory in app, it's vendor/assets
[17:02:43] uberjar: has joined #RubyOnRails
[17:03:20] seantimm_: has joined #RubyOnRails
[17:04:41] CornishPasty: I guess I don't really install new rubies that often, but it sort of goes against "speed is a priority"
[17:05:32] havenwood: CornishPasty: Everyday use speed. Installing Rubies doesn't take microseconds. Again, do you install Rubies or Gems more often?
[17:05:39] havenwood: CornishPasty: Why don't rehashing bother you?
[17:05:48] CornishPasty: Why would rehashing bother me?
[17:05:51] CornishPasty: I do it in other situations
[17:06:01] havenwood: Probably offtopic for this channel. Happy to discuss in #chruby or #ruby.
[17:06:20] nertzy: has joined #RubyOnRails
[17:06:25] jaequery: has joined #RubyOnRails
[17:07:35] blackmesa: has joined #RubyOnRails
[17:07:37] cassioscabral: has joined #RubyOnRails
[17:09:11] mdw: has joined #RubyOnRails
[17:10:25] JDeen: has joined #RubyOnRails
[17:10:57] JDeen: Hi there. Any ideas to how we could test custom objects in Rails + Rspec -> ex: presenters. I got presenters in ex, app/views/presenters/order_summary_presenter.rb
[17:11:03] JDeen: Should i make a new folder like 'presenters' in spec?
[17:11:10] JDeen: and what will tye type be: i think it will be 'model' as in -> `RSpec.describe Post, :type => :model do`
[17:11:18] JDeen: Thanks in advance fr helping this noob in testing
[17:12:21] hendricius: has anyone here been using OJ?
[17:12:25] hendricius: for parsing JSON?
[17:13:00] owenjones: has joined #RubyOnRails
[17:14:17] greenhat: jdeen: Are your presenters plain ruby objects?
[17:14:28] hendricius: https://gist.github.com/hendricius/450c0a881408084d446a
[17:14:38] hendricius: question - my OJ does not like to parse my json
[17:14:44] hendricius: i am feeling stupid :D
[17:14:49] greenhat: jdeen: If so I suggest putting them in app/presenters, not app/views/presenters.
[17:15:06] hardtail: has joined #RubyOnRails
[17:15:21] RegulationD: has joined #RubyOnRails
[17:15:50] greenhat: jdeen: Then you put your tests in spec/presenters and inherit from whatever the standard unit tests inherit from (I assume. I use minitest)
[17:16:39] JDeen: greenhat: yap, they are plain ruby objects... ah yes correct, my bad, I was just typying and didn't look back.
[17:18:20] JDeen: greenhat: i will be using rspec, i see rpsec has a type defined. what will be used for it. for example a rspec test file will have: `RSpec.describe Post, :type => :model do`, in this case what will we be expecting to use insted of 'model'
[17:19:29] syzygy_: has joined #RubyOnRails
[17:20:30] arup_r: jdeen: that is called metadata.. for your preneseter class you don't need to use that
[17:20:45] JDeen: arup_r: thanks
[17:20:49] JDeen: greenhat: thanks
[17:20:57] arup_r: look https://www.relishapp.com/rspec/rspec-rails/v/3-4/docs/directory-structure
[17:21:39] JDeen: arup_r: thanks for the info
[17:21:58] arup_r: so if your spec is in the correct model all is well and give a read *Automatically Adding Metadata** ..
[17:22:07] arup_r: it will clean your doubt
[17:22:22] arup_r: correct directory**
[17:23:15] arup_r: jdeen: main idea is *It is suggested that the spec/ directory structure generally mirror both app/ and lib/. This makes it easy to locate corresponding code and spec files.*
[17:24:02] Oliphaunte: Does anyone else experience problems with typing in their terminal after exiting `rails console`?
[17:24:25] sandstrom: has joined #RubyOnRails
[17:24:25] arup_r: Oliphaunte: and the kind of problem is ??
[17:24:38] JDeen: arup_r: great, makes sense, thanks for the info! very educational...
[17:25:03] Oliphaunte: Bit difficult to explain, but my keyboard seems to be messed up after and I have to restart the terminal session
[17:25:05] JDeen: you guys have a merry christmas and a happy new year,
[17:25:15] arup_r: jdeen: same to you :)
[17:25:37] arup_r: Oliphaunte: reboot :)
[17:25:37] Oliphaunte: So if I try to type `rails console`, after quitting
[17:25:51] Oliphaunte: It's getting tedious having to quit terminal after ever rails session
[17:26:24] Oliphaunte: Anyways, if I type 'rails console' after quitting, then the keyboard types in raals coosole
[17:26:40] Oliphaunte: Effectively, it seems to be auto-typing, but I cannot tell using what
[17:27:23] konsolebox: has joined #RubyOnRails
[17:28:13] benlieb: has joined #RubyOnRails
[17:28:24] lacuna: has joined #RubyOnRails
[17:28:35] Pazician: has joined #RubyOnRails
[17:29:24] mag42c: has joined #RubyOnRails
[17:29:40] cassioscabral: has joined #RubyOnRails
[17:30:04] konsolebox: has joined #RubyOnRails
[17:31:41] ascarter: has joined #RubyOnRails
[17:32:03] bronson: has joined #RubyOnRails
[17:32:39] atomical_: has joined #RubyOnRails
[17:32:42] jaequery: has joined #RubyOnRails
[17:33:00] diegoviola: has joined #RubyOnRails
[17:38:48] fox_mulder_cp: in rails c enter this
[17:38:49] fox_mulder_cp: Rails.application.eager_load!
[17:38:49] fox_mulder_cp: ActiveRecord::Base.descendants
[17:39:29] fox_mulder_cp: and try create YourClass.new, as example
[17:40:41] rickmasta: has joined #RubyOnRails
[17:44:53] marr: has joined #RubyOnRails
[17:44:54] atomical: has joined #RubyOnRails
[17:46:27] nettoweb: has joined #RubyOnRails
[17:47:42] Oliphaunte: has joined #RubyOnRails
[17:48:19] nickjj: has joined #RubyOnRails
[17:48:58] hectortrope: has joined #RubyOnRails
[17:51:31] sleungcy: has joined #RubyOnRails
[17:54:40] the_nic__: has joined #RubyOnRails
[17:55:27] Kenrick: has joined #RubyOnRails
[17:55:35] alex88: has joined #RubyOnRails
[17:56:00] gheegh: has joined #RubyOnRails
[17:57:42] conta: has joined #RubyOnRails
[17:58:14] agit0: has joined #RubyOnRails
[17:58:19] justinweiss: has joined #RubyOnRails
[17:58:30] nettoweb: has joined #RubyOnRails
[17:58:43] mary5030: has joined #RubyOnRails
[17:59:35] mary5030: has joined #RubyOnRails
[18:03:03] shanemcd: has joined #RubyOnRails
[18:03:59] syzygy_: has joined #RubyOnRails
[18:06:29] shibabu: has joined #RubyOnRails
[18:08:16] conta: has joined #RubyOnRails
[18:08:19] cyfr0n1: has joined #RubyOnRails
[18:10:08] mdw: has joined #RubyOnRails
[18:12:03] armyriad: has joined #RubyOnRails
[18:13:21] the_nick_me: has joined #RubyOnRails
[18:14:16] malkav: has joined #RubyOnRails
[18:14:45] mlangenberg: has joined #RubyOnRails
[18:15:39] markh: has joined #RubyOnRails
[18:15:59] hardtail: has joined #RubyOnRails
[18:18:00] agoldboi: has joined #RubyOnRails
[18:18:54] ibouvousaime_: has joined #RubyOnRails
[18:19:46] lacrymology: has joined #RubyOnRails
[18:24:27] atomical: has joined #RubyOnRails
[18:27:49] ElFerna: has joined #RubyOnRails
[18:28:34] tuelz: has joined #RubyOnRails
[18:31:06] mices: trying to use dropit, getting a lot of errors from the console https://gist.github.com/mices/fd162ba87c24957f8359
[18:34:18] teaearlgraycold: has joined #RubyOnRails
[18:34:35] manfrin: has joined #RubyOnRails
[18:34:54] Spami: has joined #RubyOnRails
[18:35:31] teaearlgraycold: Hey, when I call .delete_all on a has_many relation through another model it seems AR is just setting the relavent _id column to NULL rather than actually deleting the record from the dB
[18:35:42] teaearlgraycold: What's strange is it's only doing this for one table
[18:36:06] teaearlgraycold: Could this be because the table in question has many belongs_tos?
[18:36:15] teaearlgraycold: How do I force delete it?
[18:36:43] matthewd: teaearlgraycold: foo.all.delete_all, I think?
[18:36:59] teaearlgraycold: Well I don't want to delete all foos
[18:37:07] teaearlgraycold: Just bar.foos.delete_all
[18:37:10] Trynemjoel: has joined #RubyOnRails
[18:37:16] matthewd: teaearlgraycold: whatever_you_currently_have.all.delete_all
[18:37:37] carlosd: has joined #RubyOnRails
[18:38:11] jmignault: has joined #RubyOnRails
[18:38:37] nfk|laptop: has joined #RubyOnRails
[18:39:14] teaearlgraycold: Awesome, works perfectly, matthewd
[18:39:58] Oliphaunte: has joined #RubyOnRails
[18:40:08] Hans267: has joined #RubyOnRails
[18:43:07] sleungcy: has joined #RubyOnRails
[18:48:11] bronson: has joined #RubyOnRails
[18:49:26] bronson: has joined #RubyOnRails
[18:49:32] xoke: has joined #RubyOnRails
[18:49:34] rickmasta: has joined #RubyOnRails
[18:51:07] rgtk: has joined #RubyOnRails
[18:52:15] foobar121: has joined #RubyOnRails
[18:52:56] bronson: has joined #RubyOnRails
[18:55:21] tectonic: has joined #RubyOnRails
[18:56:47] foobar121: has left #RubyOnRails: ()
[18:57:20] foobar020: has joined #RubyOnRails
[18:58:54] tuelz: has joined #RubyOnRails
[19:00:44] ziggles: has joined #RubyOnRails
[19:06:33] eldariof: has joined #RubyOnRails
[19:06:53] joshkovach: has joined #RubyOnRails
[19:06:57] shanemcd: has joined #RubyOnRails
[19:07:27] blackmesa: has joined #RubyOnRails
[19:08:52] nerium: has joined #RubyOnRails
[19:09:47] Aherin: has joined #RubyOnRails
[19:11:19] atomical_: has joined #RubyOnRails
[19:11:48] gavit: I have postgresql running on production, but I want to drop the db. do I stop httpd first?
[19:12:14] johnnegron: has joined #RubyOnRails
[19:12:21] Coldblackice: has joined #RubyOnRails
[19:14:45] smathy: Oliphaunte, you can usually reset a terminal if it's characters not behaving properly, either with just `reset` or `tput reset`.
[19:15:16] Oliphaunte: smathy: Tried that too
[19:15:18] smathy: gavit, up to you.
[19:15:36] Oliphaunte: Idk, cannot seem to type anything cohesive enough to resolve ut
[19:15:51] smathy: Oliphaunte, not sure what "keyboard seems to be messed up" means really.
[19:16:18] Oliphaunte: It's a horrible description, but I just am not sure how to fully explain it
[19:16:18] smathy: Oliphaunte, how are you quitting the rails console?
[19:16:38] Oliphaunte: Hang on, I'll repeat the error and tell you my process
[19:16:49] smathy: Oliphaunte, well, give an example of something which doesn't work as expected, and what happens instead.
[19:17:07] delsol: has joined #RubyOnRails
[19:17:12] Oliphaunte: Ok, so I do `rails c`
[19:17:20] Oliphaunte: Then ctrl + z
[19:17:29] Oliphaunte: So back to my master branch
[19:17:40] Oliphaunte: Now I try to type "reset"
[19:17:58] hardtail: has joined #RubyOnRails
[19:18:06] Oliphaunte: And it changes the s to an e
[19:18:22] Oliphaunte: And underlines the letters 'e'
[19:18:22] delsol: So, current application is in rails 3.2.9, with ruby 2.0.0, upgrading to ruby 2.2.3 breaks rails 3.2.9, upgrading to rails 3.2.22 breaks app...
[19:18:42] delsol: is there a good list of what changed between 3.2.9 and 3.2.22?
[19:19:04] Oliphaunte: Also, pressing the left arrow button just insets 0s
[19:19:05] smathy: Oliphaunte, ok, so ^Z is not how to quit console, use ^D
[19:19:56] Oliphaunte: All this time people were telling me ^Z
[19:20:10] smathy: Oliphaunte, ^Z is how to suspend something, don't listen to those people ever again.
[19:20:11] greengriminal: has joined #RubyOnRails
[19:20:28] moeabdol1: has joined #RubyOnRails
[19:20:36] smathy: Oliphaunte, suspending rails console is broken when spring is enabled because spring's autoload behavior re-foregrounds it or something bizarre.
[19:20:41] mostlybadfly: has joined #RubyOnRails
[19:21:02] Oliphaunte: Ah, that would make sense
[19:21:12] Oliphaunte: Alright then, ^D then
[19:21:17] Oliphaunte: Thanks smathy
[19:21:51] Papierkorb: I have a coworker who always types 'exit' and hits return. It's driving me nuts that he's just not hitting Ctrl+D. Typing 'exit' is inefficient Oo
[19:23:28] jobewan: has joined #RubyOnRails
[19:23:55] smathy: Oliphaunte, you're welcome.
[19:24:07] havenwood: Papierkorb: ctrl-c muscle memory is hard to break (looking at you, Spring!)
[19:24:08] sandstrom: has joined #RubyOnRails
[19:24:41] smathy: Papierkorb, alias exit="echo Please use ^D"
[19:25:04] Papierkorb: smathy: ... if he ever leaves his computer unlocked .. that's what I'll do :P
[19:26:21] havenwood: try that ^ in zsh :P
[19:26:56] agit0: has joined #RubyOnRails
[19:27:07] djbkd: has joined #RubyOnRails
[19:27:33] pyemkey: has joined #RubyOnRails
[19:27:47] havenwood: exit | wc -c #=> 6207
[19:32:00] andatche: has joined #RubyOnRails
[19:33:15] tuelz: has joined #RubyOnRails
[19:33:48] czerasz: has joined #RubyOnRails
[19:37:49] zpe: has joined #RubyOnRails
[19:38:42] rgtk: has joined #RubyOnRails
[19:38:45] Trynemjoel: has joined #RubyOnRails
[19:39:44] kies^: has joined #RubyOnRails
[19:40:09] mdw: has joined #RubyOnRails
[19:40:23] doodlehaus: has joined #RubyOnRails
[19:40:32] A124: has joined #RubyOnRails
[19:44:37] doodleha_: has joined #RubyOnRails
[19:45:37] kenrick_: has joined #RubyOnRails
[19:45:54] arup_r: has joined #RubyOnRails
[19:49:03] DoubleMalt: has joined #RubyOnRails
[19:49:26] civos: has joined #RubyOnRails
[19:50:32] manfrin: has joined #RubyOnRails
[19:51:26] JakFrist: has joined #RubyOnRails
[19:52:54] wldcordeiro: has joined #RubyOnRails
[19:54:12] delsol: has joined #RubyOnRails
[19:54:26] teaearlgraycold: So I'm trying out Postgres' JSONB column type with AR. Can I query a column by a JSON path with native Ruby code, or is my only option to download the entire JSON object and parse it locally if I'm sticking to pure Ruby only?
[19:54:43] bronson: has joined #RubyOnRails
[19:56:03] note1989: has joined #RubyOnRails
[19:56:48] teamcoltra: has joined #RubyOnRails
[19:56:55] pawnbox: has joined #RubyOnRails
[19:57:29] note1989: Hi haxors. Why is this seeds.rb so slow ? http://pastebin.com/EVeE7Ndx
[19:57:46] conta_: has joined #RubyOnRails
[19:58:59] teaearlgraycold: note1989: how slow are we talking?
[19:59:23] matthewd: teaearlgraycold: AR isn't designed to be used "with native Ruby code"; if you want something unusual, SQL is the right thing to do
[20:00:08] teaearlgraycold: matthewd: what do you mean? I've been able to do everything else natively
[20:00:10] note1989: teaearlgraycold: like 2 sek per "loopp"
[20:00:40] teaearlgraycold: note1989: do insertions go slowly in general for you? You could time different parts. That code shouldn't run slowly
[20:03:20] note1989: Hmmm i havent really felt it to be super slow when using the app. I havent written any of the backend code i just was fascinated that the seed took hours to run.
[20:03:38] note1989: when the outer loop ran 100 times aswell.
[20:03:39] mdw: has joined #RubyOnRails
[20:04:57] note1989: teaearlgraycold: Never worked with ruby. so this most likely due to postgres then
[20:05:32] teaearlgraycold: Maybe. You could just use some debug logging to see if a specific part is making it slow
[20:05:36] smathy: Your logs should tell you how much time the SQL side of things is taking note1989
[20:06:53] PlasmaStar: has joined #RubyOnRails
[20:08:03] bronson: has joined #RubyOnRails
[20:08:56] note1989: smathy: okey i need to find them then :P tnx
[20:09:42] shibabu: has joined #RubyOnRails
[20:10:14] nettoweb: has joined #RubyOnRails
[20:10:23] matthewd: teaearlgraycold: I'm not sure how to be much clearer... if you need a complex condition, you should implement it with an SQL fragment
[20:11:49] delsol: I'm trying to update some things to be rails 4 compliant, and I've got a couple scopes in activerecord.rb that apply to basically all of the models, how do I fix this to be rails 4 complaint?
[20:11:51] delsol: scope :enabled, :conditions => 'enabled'
[20:12:12] smathy: teaearlgraycold, generally you'll find that the AR API doesn't support DB-specific features.
[20:12:14] delsol: er, compliant.
[20:12:20] matthewd: delsol: What have you tried so far?
[20:12:46] owenjones: has joined #RubyOnRails
[20:12:53] delsol: matthewd: well, many of the scopes I've been able to fix, but I can't seem to find the right syntax in this case.
[20:13:00] teaearlgraycold: Alright, I suppose that makes sense
[20:14:12] ruid: has joined #RubyOnRails
[20:15:21] djbkd: has joined #RubyOnRails
[20:17:02] ponky: has joined #RubyOnRails
[20:18:22] djbkd: has joined #RubyOnRails
[20:18:23] KarolisDz: has joined #RubyOnRails
[20:18:38] owenjones: has joined #RubyOnRails
[20:18:49] hardtail: has joined #RubyOnRails
[20:19:31] atomical: has joined #RubyOnRails
[20:22:28] alex88: has joined #RubyOnRails
[20:23:11] rakm: has joined #RubyOnRails
[20:24:46] CR: has joined #RubyOnRails
[20:26:33] fwaokda: has joined #RubyOnRails
[20:26:56] markh: has joined #RubyOnRails
[20:27:57] gousuto: has joined #RubyOnRails
[20:28:22] pawnbox: has joined #RubyOnRails
[20:28:56] marcdel: has joined #RubyOnRails
[20:29:10] gousuto: to bootstrap, or not to bootstrap
[20:29:19] gousuto: i.e. the frontend framework
[20:29:36] marcdel: has joined #RubyOnRails
[20:29:57] marcdel: has joined #RubyOnRails
[20:30:19] smathy: ACTION looks around, yep, still in #ror
[20:30:22] nettoweb: has joined #RubyOnRails
[20:30:26] Synthead: gousuto: that is the case statement
[20:30:34] jessemcgilallen: has joined #RubyOnRails
[20:30:37] marcdel: has joined #RubyOnRails
[20:30:55] pramsky: has joined #RubyOnRails
[20:31:00] Synthead: ACTION end
[20:31:18] marcdel: has joined #RubyOnRails
[20:32:16] gousuto: hmm, if that's supposed to be a joke, I didn't quite get it :p
[20:34:53] DoubleMalt: has joined #RubyOnRails
[20:36:07] grn: has joined #RubyOnRails
[20:36:25] doodlehaus: has joined #RubyOnRails
[20:39:05] nertzy: has joined #RubyOnRails
[20:41:38] htmldrum: has joined #RubyOnRails
[20:41:48] Synthead: is there a way I can add a namespace to a model concern so I can do something like this_model.this_concern_group.this_concern_method?
[20:42:32] Synthead: perhaps some trickery with classes?
[20:43:33] matthewd: Synthead: With some non-trivial trickery, it certainly seems *possible* to make something like that work
[20:43:55] matthewd: [with certain constraints, around e.g. ivars]
[20:44:16] Synthead: matthewd: yeah, I suppose I could have a class with those methods in it, then create an object based on that class in the concern
[20:44:25] Synthead: matthewd: sounds like code smell, though
[20:44:45] Synthead: matthewd: what do you do here? just make sure not to use the same method names?
[20:44:49] yfeldblum: has joined #RubyOnRails
[20:45:05] PedramT: has joined #RubyOnRails
[20:45:08] diegoviola: has joined #RubyOnRails
[20:45:18] diegoviola: how well does rails plays with react
[20:45:20] diegoviola: or vice-versa
[20:45:33] diegoviola: react is just js, no?
[20:45:40] teaearlgraycold: diegoviola: well you can get the rails react gem
[20:45:49] teaearlgraycold: It works fine in my experience
[20:45:53] diegoviola: doesn't need node on the backend?
[20:46:02] diegoviola: is it just assets?
[20:46:04] ss_much: has joined #RubyOnRails
[20:46:22] teaearlgraycold: If you're using JSX (if I understand React correctly)
[20:46:39] teaearlgraycold: And compiling down .jsx to .js on the server
[20:46:51] teaearlgraycold: But I think rails requires a JS engine on the server normally anyway
[20:52:19] crdpink2: has joined #RubyOnRails
[20:58:08] [Butch]: has joined #RubyOnRails
[20:58:31] pawnbox: has joined #RubyOnRails
[20:58:41] jsrn_: has joined #RubyOnRails
[20:59:16] nocd: has joined #RubyOnRails
[20:59:19] diegoviola: I'm reasonably new with testing still, I have a bunch of methods in my models, controllers and helpers that I want to write tests for with rspec
[20:59:31] diegoviola: how do I measure what methods I want to write tests for and which ones I don't?
[20:59:38] RickJamesTheThir: has joined #RubyOnRails
[20:59:50] Cache_Money: has joined #RubyOnRails
[21:00:00] diegoviola: also, do I just test the method functionality? as in, mock the input and what the expectation (output)?
[21:00:03] RickJamesTheThir: Hi guys/gals I was hoping you can help me with the find_or_create method
[21:00:18] conta__: has joined #RubyOnRails
[21:01:27] RickJamesTheThir: Example model Person (name , contractor_id) I have 1 person in the database ( name => "Bill", contractor_id: 123)
[21:02:24] agit0: has joined #RubyOnRails
[21:02:49] bradleyprice: has joined #RubyOnRails
[21:02:57] tbuehlmann: diegoviola, how to test: https://jnoconor.github.io/images/unit-testing-chart-sandi-metz.png
[21:03:12] qwebirc588980: has joined #RubyOnRails
[21:03:16] weaksauce: has joined #RubyOnRails
[21:03:36] mrbubbles: has joined #RubyOnRails
[21:03:40] tbuehlmann: diegoviola, what to test:as always, depends. what about testing the code you are least comfortable with first?
[21:03:46] doodlehaus: has joined #RubyOnRails
[21:04:04] diegoviola: tbuehlmann: that's a good measure I guess
[21:05:03] Didac: has joined #RubyOnRails
[21:08:59] atomical_: has joined #RubyOnRails
[21:09:06] nerium: has joined #RubyOnRails
[21:12:50] DaniG2k: has joined #RubyOnRails
[21:14:05] DaniG2k: hello all. I'm trying to make a dropdown (select box) that will automatically refresh the page with a different locale onchange. The links need to be something like link_to(url_for(:locale => :ja))
[21:14:26] DaniG2k: how can I do this in Rails? I think I need to intercept with Javascript but not sure how to make the link in JS
[21:15:05] yashinbasement: has joined #RubyOnRails
[21:17:28] conta: has joined #RubyOnRails
[21:18:45] mary5030_: has joined #RubyOnRails
[21:19:35] alessandro1997: has joined #RubyOnRails
[21:19:42] hardtail: has joined #RubyOnRails
[21:20:17] bradleyprice: has joined #RubyOnRails
[21:20:47] rakm: has joined #RubyOnRails
[21:21:40] tbuehlmann: DaniG2k, you could listen to change events on the select, read the value of the selected element and change window.location accordingly (or use Turbolinks.visit if using turbolinks)
[21:21:43] mdw: has joined #RubyOnRails
[21:22:39] manfrin: has joined #RubyOnRails
[21:26:55] DaniG2k: tbuehlmann: not using turbolinks. I am doing something like:
[21:27:23] DaniG2k: <%= select_tag :locale, options_for_select([['English',:en],...],I18n.locale.to_s),:onchange => 'this.form.submit()' %>
[21:27:27] DaniG2k: but it doesn't actually submit
[21:27:33] DaniG2k: I suppose it needs to be within a form_tag
[21:27:34] Didac: has joined #RubyOnRails
[21:27:38] DaniG2k: which I'm trying to setup now :P
[21:28:21] pawnbox: has joined #RubyOnRails
[21:28:49] DaniG2k: ok....that's submitting....getting there I think
[21:28:57] moei: has joined #RubyOnRails
[21:29:56] grn: has joined #RubyOnRails
[21:31:30] conta: has joined #RubyOnRails
[21:33:35] syzygy_: has joined #RubyOnRails
[21:34:43] dmarr: for people using travis with secure credentials for testing apis, do you use env vars for all of your secrets.yml? i would like to only use env vars i think when travis runs
[21:35:57] dmarr: i have an initializer that pulls from application.secrets here https://github.com/marr/localpic2/blob/master/config/initializers/refile.rb but i think its getting overwritten when run in travis because there is no secrets file checked in
[21:37:09] jobewan: has joined #RubyOnRails
[21:38:28] blackmesa: has joined #RubyOnRails
[21:40:23] conta_: has joined #RubyOnRails
[21:40:38] Oliphaunte: has joined #RubyOnRails
[21:41:27] rgtk: has joined #RubyOnRails
[21:41:48] mary5030: has joined #RubyOnRails
[21:42:43] mary5030: has joined #RubyOnRails
[21:44:01] atomical: has joined #RubyOnRails
[21:44:10] htmldrum: has joined #RubyOnRails
[21:44:48] moei: has joined #RubyOnRails
[21:46:43] FastJack: has joined #RubyOnRails
[21:46:48] grn: has joined #RubyOnRails
[21:48:37] dnewkerk: has joined #RubyOnRails
[21:48:58] lalalaaa: has joined #RubyOnRails
[21:49:08] doodlehaus: has joined #RubyOnRails
[21:50:05] DoubleMalt: has joined #RubyOnRails
[21:51:44] camilasan: has joined #RubyOnRails
[21:51:46] yos7ph: has joined #RubyOnRails
[21:54:32] doodleha_: has joined #RubyOnRails
[21:55:00] draig: has joined #RubyOnRails
[21:55:24] atomical_: has joined #RubyOnRails
[21:56:52] doodlehaus: has joined #RubyOnRails
[21:58:33] pawnbox: has joined #RubyOnRails
[21:59:18] hardtail: has joined #RubyOnRails
[22:00:27] hardtail: has joined #RubyOnRails
[22:03:08] shanemcd: has joined #RubyOnRails
[22:03:49] kadoppe: has joined #RubyOnRails
[22:06:23] ciree: can I have two has_many's with the same name?
[22:06:27] ciree: one has a through the other doesnt
[22:07:24] faisal: has joined #RubyOnRails
[22:08:08] Radar: ciree: no
[22:08:32] ciree: any thoughts on how I could accomplish this?
[22:08:43] ciree: basically, the intermidate model doesn't need to exist anymore
[22:08:52] zpe: has joined #RubyOnRails
[22:08:53] Radar: ciree: !ncnh
[22:08:53] helpa: ciree: If you don't provide any code, it becomes really difficult for us to help you. Providing code to reproduce the problem increases your chances of getting great, accurate help immensely.
[22:08:55] ciree: but I'd like the migration to the new code to still work
[22:10:11] Papierkorb: in a controller method, is doing this safe security-wise? Article.find params[:id]
[22:10:14] ciree: https://gist.github.com/elech/e51af7a59cca0639ad7a
[22:10:27] ciree: basically, the model stuff doesn't need to exist anymore, and is just legacy
[22:10:28] Papierkorb: where the controller is a "resources :articles" route
[22:11:00] ciree: but while making the transition to the new way, I'd like the old way to still work
[22:11:28] ewnd9: has joined #RubyOnRails
[22:12:30] shibabu: has joined #RubyOnRails
[22:13:50] Radar: Papierkorb: yes, that's safe
[22:13:58] Radar: ciree: !fake
[22:13:58] helpa: ciree: Please do not use fake values, as they can be confusing or misleading. Sometimes both.
[22:14:01] Radar: ciree: !rules
[22:14:01] helpa: ciree: https://gist.github.com/996779
[22:14:12] Radar: ciree: Please familiarise yourself with your nearest exit, remembering it may be behind you.
[22:14:20] cassioscabral: has joined #RubyOnRails
[22:15:01] Radar: Call it something else?
[22:15:50] ciree: I'll figure it out, thanks
[22:16:02] markh: has joined #RubyOnRails
[22:16:42] shanemcd: has joined #RubyOnRails
[22:16:56] doodlehaus: has joined #RubyOnRails
[22:18:31] wildlander: has joined #RubyOnRails
[22:21:45] nerium: has joined #RubyOnRails
[22:27:26] shanemcd: has joined #RubyOnRails
[22:27:42] duncannz: has joined #RubyOnRails
[22:28:27] grn: has joined #RubyOnRails
[22:30:20] owenjones: has joined #RubyOnRails
[22:31:29] Oliphaunte: has joined #RubyOnRails
[22:32:29] nerium: has joined #RubyOnRails
[22:33:49] pwnd_nsfw: has joined #RubyOnRails
[22:34:14] solars: has joined #RubyOnRails
[22:36:57] rhizome: has joined #RubyOnRails
[22:37:35] shanemcd: has joined #RubyOnRails
[22:38:25] pawnbox: has joined #RubyOnRails
[22:40:19] Guest71659: has left #RubyOnRails: ()
[22:40:33] zly: has joined #RubyOnRails
[22:43:51] wethu: has joined #RubyOnRails
[22:47:19] alphaatom: has joined #RubyOnRails
[22:47:25] fschuindt: has joined #RubyOnRails
[22:47:35] shanemcd: has joined #RubyOnRails
[22:47:54] shanemcd_: has joined #RubyOnRails
[22:48:50] thezanke: has joined #RubyOnRails
[22:50:21] nerium: Does anyone knows how to use an md5 hash a the name for an image when using paperclip?
[22:52:01] dmarr: im using the aws-sdk and for some reason when I execute my app, its not pulling in the AWS_REGION value from ENV, but according to the docs it should
[22:52:02] nfk|laptop: has joined #RubyOnRails
[22:52:47] alphaatom: has joined #RubyOnRails
[22:53:15] fox_mulder_cp: Papierkorb: oh. i recommend not use it. use @article = Article.find_by(id: params[:id])
[22:53:51] fox_mulder_cp: some my taechers recommend this form
[22:54:03] Papierkorb: fox_mulder_cp: ..why?
[22:54:14] Papierkorb: Radar: thanks
[22:54:26] Radar: fox_mulder_cp: Those teachers are wrong
[22:54:35] Radar: You'd only use that form if you're fine with the article find failing
[22:54:41] FooMunki: has joined #RubyOnRails
[22:54:45] Radar: Papierkorb: It would be useful to have context to show fox_mulder_cp why they are wrong
[22:56:27] Papierkorb: fox_mulder_cp: it's a JSON-API, ArticlesController controls Article's. If not found, a 404 shall be served. With your way, I'd have to do a check like "raise ActiveSomething::ResourceNotFound if article.nil?" - Which is more to write (violates DRY), and is logic (So you have to write tests for it).
[22:56:44] Radar: ActiveRecord::RecordNotFound
[22:57:10] Papierkorb: fox_mulder_cp: however using the .find method, it's a no-brainer. If it's not found, the RecordNotFound is raised and as result, the server serves a 404 response. Great.
[22:58:33] fox_mulder_cp: i use classic server side app and when no articles after db:reset no errors showef
[22:59:13] rhizome: what does classic mean here
[22:59:13] Papierkorb: fox_mulder_cp: Sorry, I don't think I get what you're trying to say
[22:59:28] Radar: Me neither. It is in some form of English that I don't understand.
[22:59:37] Radar: I mean, those are English words, but not in an order that I can parse.
[22:59:59] axl_: has left #RubyOnRails: ()
[23:00:38] Oliphaunte: has joined #RubyOnRails
[23:00:38] fox_mulder_cp: yes, my english is bad...
[23:00:59] Radar: try again
[23:02:12] fox_mulder_cp: ook. now i write same app same as you, from manual. i add some external festures such as Devise gem, twitter bootstrap etc
[23:03:03] fox_mulder_cp: but when i try rake db:reset|migrate my database is clear
[23:03:25] Papierkorb: yeah, db:reset *resets* (which includes clearing) the database
[23:03:27] fox_mulder_cp: and no errors, when i open /articles/index
[23:04:06] Papierkorb: Is that what you want, or do you want to serve a 404 instead?
[23:04:21] Intii: has joined #RubyOnRails
[23:05:53] Intii: Hi everyone, I'm experiencing this weird issue with rails. Everytime I try to run a rails generate command, I get the following error: https://gist.github.com/dsarhadian/58ed34d4a5c32000639b
[23:06:21] fox_mulder_cp: i think, that server 404 in json quiery - best practice
[23:06:35] Radar: server 404 is a HTML response by default
[23:06:49] Radar: what you'll need to do is to catch that exception (with rescue_from) in the API controller and serve a JSON response
[23:06:57] RegulationD: has joined #RubyOnRails
[23:06:59] Radar: that way then, API clients won't try to parse the HTML 404 response as if it were JSON
[23:07:22] nertzy: has joined #RubyOnRails
[23:07:26] fox_mulder_cp: i said about 'no more html in 404 code'
[23:07:34] Cache_Money: has joined #RubyOnRails
[23:07:35] Radar: Intii: Do you have the Bundler gem installed?
[23:07:49] fox_mulder_cp: Intii: do you properly install rails?
[23:08:17] Intii: Radar: Yeah bundler is installed (version 1.11.2).
[23:08:42] pawnbox: has joined #RubyOnRails
[23:08:47] fox_mulder_cp: Intii: i today reinstall my lxc container with rails by this manual rails from here: https://gorails.com/setup/ubuntu/15.10
[23:08:52] Intii: fox_mulder_cp: Yeah I think so, I installed Ruby 2.2.3 through rbenv and installed the bundler and rails gem on top of that
[23:09:11] Spami: has joined #RubyOnRails
[23:09:16] Intii: fox_mulder_cp: That's the same exact guide I follow when I install rails
[23:09:41] fox_mulder_cp: Intii: may be you can't add path environment into your shell .rc?
[23:09:52] fox_mulder_cp: or your shell not bash
[23:09:52] Radar: Seems like it was setup fine.
[23:10:04] Radar: Shell looks bash-ish
[23:10:27] Intii: Yeah I've setup Rails every time like this and never had this problem till recently
[23:10:31] Intii: Shell is bash
[23:10:46] Radar: Intii: I'd advise removing it and trying again
[23:10:48] Radar: Intii: it being rbenv
[23:10:56] Radar: Intii: if that doesn't work, then
[23:10:59] helpa: Ubuntu, Ruby, ruby-install, chruby, Rails setup guide: http://ryanbigg.com/2014/10/ubuntu-ruby-ruby-install-chruby-and-you/ - Gauranteed to work 100% of the time or your money back!
[23:11:17] VeryBewitching: has joined #RubyOnRails
[23:11:40] Intii: Radar: Okay, I'll try it out. I've always followed the gorails.com guide and it's never failed me then... This is so weird
[23:12:04] fox_mulder_cp: Intii: relogin to this server
[23:12:08] Oliphaunte: has joined #RubyOnRails
[23:12:17] fox_mulder_cp: or reread .bashrc
[23:12:34] agit0: has joined #RubyOnRails
[23:13:47] tectonic: has joined #RubyOnRails
[23:14:32] shibabu: has joined #RubyOnRails
[23:17:58] nerium: Is there a way to rename already uploaded images to paperclip?
[23:18:25] Radar: nerium: why
[23:18:25] lipoqil: has joined #RubyOnRails
[23:18:53] nerium: Radar: Uploaded images contains strange chars I want to remove
[23:19:03] Radar: nerium: such as
[23:19:14] nerium: I???m going with an md5 name instead of the original one
[23:19:18] agit0: has joined #RubyOnRails
[23:19:20] nerium: space, ?????? and so on
[23:19:27] teamcoltra: has joined #RubyOnRails
[23:21:03] nerium: Radar: Any ide how this can be done?
[23:21:21] Radar: nerium: http://stackoverflow.com/questions/2708115/paperclip-renaming-files-after-theyre-saved
[23:21:51] nerium: Radar: Read that one a while back. Its a bit old so was hoping for a better solution by now
[23:23:08] Radar: I don't have an answer besides htat.
[23:23:59] rikkipitt: has joined #RubyOnRails
[23:24:34] VeryBewitching: nerium: How many images are you talking about?
[23:24:51] nerium: VeryBewitching: 800k maybe
[23:25:49] lacuna: has joined #RubyOnRails
[23:26:00] twilizant: has joined #RubyOnRails
[23:26:08] VeryBewitching: There's nothing stopping you from writing a script to migrate the data manually (changing the file name on disk and in the database) but it will take quite some time.
[23:26:15] VeryBewitching: For it to run, that is.
[23:27:10] nerium: VeryBewitching: Moving the files should be fast, but I???m not very keen on moving file around in the fs
[23:27:40] VeryBewitching: Well you're not changing it's location, just the name.
[23:27:48] VeryBewitching: Is that correct?
[23:28:39] nerium: VeryBewitching: I need to change the location as well
[23:28:53] rhizome: you sure have a mess on your hands
[23:29:00] Intii: Radar: I reinstalled Ruby and Rails through rbenv and still getting the same error.
[23:29:05] VeryBewitching: nerium: You have a two-step process now.
[23:29:16] VeryBewitching: nerium: Changing the name in the table and on disk; then moving them.
[23:29:21] nerium: VeryBewitching: I know the basic setup :)
[23:29:51] nerium: VeryBewitching: The problem is to map the path I???m moving the files from to a path paperclip understands
[23:29:58] Intii: Could this be a spring related issue?
[23:30:11] rhizome: nerium: you should plan that out before now
[23:30:12] VeryBewitching: nerium: That's not the hard part, really, you can specify the path that Paperclip uses.
[23:30:18] rikkipitt: does anyone know how to send GET params with the Her gem?
[23:30:27] Oliphaunte: has joined #RubyOnRails
[23:30:33] rikkipitt: I tried a Faraday middleware but to no avail...
[23:30:39] nerium: VeryBewitching: Could you how to access these params? ":class/:attachment/:hash/:style.:extension"
[23:30:53] tubbo: Intii: !ubuntu
[23:30:53] helpa: Intii: Ubuntu, Ruby, ruby-install, chruby, Rails setup guide: http://ryanbigg.com/2014/10/ubuntu-ruby-ruby-install-chruby-and-you/ - Gauranteed to work 100% of the time or your money back!
[23:31:00] VeryBewitching: nerium: You'd have to read the Paperclip docs for the exact values you can use.
[23:31:26] nerium: VeryBewitching: That???s what I mean. If I pick the wrong name, the mapping to PC wont work
[23:31:47] nerium: That???s the difficult part. Just moving the files and telling PC the new location is easy
[23:32:06] Intii: Gonna try out Radar's proposed method and see if that works
[23:32:09] VeryBewitching: nerium: Yes, it's going to be a bit of work and attention to detail, make a plan and simulate it first.
[23:32:20] VeryBewitching: nerium: No one can help you with that here, that's up to you to do now.
[23:33:52] VeryBewitching: Intii: I can verify that the ruby-install and chruby method that Radar wrote about has worked for me through several Ubuntu versions now.
[23:34:30] Intii: VeryBewitching: I've used Gorails method 100 times before. This just started happening. I'm in a brand new VM too. Xbuntu 15.10 fully up to date
[23:34:49] atomical: has joined #RubyOnRails
[23:35:03] VeryBewitching: Intii: I started with RVM and am glad that Radar was nice enough to provide a path away from that horrible, dirty mess.
[23:35:36] Intii: VeryBewitching: OMG don't get me started on RVM. when i found out about rbenv my pants got wet...
[23:37:23] gousuto: is there a preferred way of using bootstrap with rails?
[23:37:47] tubbo: gousuto: the gem
[23:37:55] VeryBewitching: gousuto: gem 'bootstrap-sass'
[23:38:10] gousuto: what about bower?
[23:38:15] VeryBewitching: gousuto: Look it up on Github, the installation process should be followed.
[23:38:41] VeryBewitching: In fact, I'm nice today so: https://github.com/twbs/bootstrap-sass
[23:38:59] Intii: +1 on the bootstrap-sass gem
[23:39:08] gousuto: hmm, alright
[23:39:16] gousuto: I'll start with that for now, but I'm also a tad interested in bower
[23:39:25] tubbo: i prefer gems because they typically come with generators that help you get set up
[23:39:26] diegoviola: what indentation level do you guys use for your sass files? spaces, tabs? how many spaces?
[23:39:58] tubbo: gousuto: so why didn't you ask about something totally irrelevant to bower?
[23:40:01] gousuto: I know bower is an npm tool... and rails has its own asset pipeline, so, I dunno, still looking into it, but bower looks kinda neat
[23:40:04] tubbo: s/didn't/did
[23:40:23] tubbo: well bower isn't an asset pipeline, it doesn't compile anything. they do different things.
[23:40:37] gousuto: right, I'm just thinking out loud
[23:41:06] tubbo: gousuto: i use some bower packages in my rails apps, using the https://rails-assets.org rubygems host.
[23:41:20] gousuto: ah, interesting
[23:41:28] tubbo: it's this bridge between rubygems and bower, so you can do `gem 'rails-assets-vuejs', source: 'https://rails-assets.org'`
[23:41:29] shanemcd: has joined #RubyOnRails
[23:42:12] diegoviola: my coworker already started using tabs for sass files, but I want to use spaces...
[23:42:20] rgtk: has joined #RubyOnRails
[23:42:47] gousuto: tubbo: that's kinda neat, I might look into that, thanks
[23:43:07] tubbo: diegoviola: i use the same indentation for everything, 2 spaces.
[23:43:26] diegoviola: I'll just convert to 2 spaces and hope he doesn't complain
[23:43:40] tubbo: diegoviola: you should tell him to configure his editor to not use tabs
[23:43:44] rhizome: say something
[23:43:56] diegoviola: my vim config converts tabs to spaces automatically
[23:44:03] rhizome: it's a style rule that everybody has to be aware of
[23:44:15] VeryBewitching: diegoviola: Have the conversation, you will likely regret not doing that if he is a believer in tabulator vs space
[23:44:15] diegoviola: :set expandtab
[23:44:46] rhizome: it's a good way to get on peoples' bad side
[23:44:57] shanemcd_: has joined #RubyOnRails
[23:45:09] VeryBewitching: diegoviola: I use 2 spaces, never tabulators, in all of my source code regardless of language, but I know some mainstays who think I smoke crack because I do it this way.
[23:45:22] diegoviola: I already had some small fights with this coworker, so it's not like this will add more fuel to the fire
[23:45:22] rhizome: "btw, here's a 300-file commit"
[23:45:51] tubbo: realistically i just use 2 spaces because so do most people. from an engineering point of view, tabs *should* be better, because we can all configure our editors to space the code however we want
[23:46:17] rhizome: which is the downfall
[23:46:31] PedramT: has joined #RubyOnRails
[23:46:33] Hans267: has joined #RubyOnRails
[23:48:55] atomical: has joined #RubyOnRails
[23:49:29] drale2k: has joined #RubyOnRails
[23:50:47] Intii: Radar: Where do I get my money back? :(
[23:53:13] tubbo: send an email to refunds@/dev/null
[23:54:02] Intii: It bounced back
[23:54:21] tubbo: man you just aren't very good at computers huh
[23:54:42] Intii: what's a computer?
[23:56:21] Radar: Intii: how did it not work
[23:56:28] StevenXL: has joined #RubyOnRails
[23:56:28] StevenXL: has joined #RubyOnRails
[23:56:45] Intii: Radar: I've installed Ruby and Rails fine, but I'm still getting the same error when I run rails generate
[23:56:46] pr1meshock: has joined #RubyOnRails
[23:56:50] Radar: Intii: show me
[23:56:54] bradleyprice: has joined #RubyOnRails
[23:56:59] Intii: Sure, one second will post a Gist
[23:57:23] pwnd_nsfw: is your computer plugged in?
[23:57:24] ascarter: has joined #RubyOnRails
[23:57:56] Intii: Radar: https://gist.github.com/dsarhadian/e2e13f8260462aff2fcf
[23:58:15] Intii: pwnd_nsfw: I think so... I'm hearing clicking noises, that's normal right?
[23:58:30] Papierkorb: pwnd_nsfw: is he even at his computer or is in reality someone talking to him over the phone?!
[23:58:33] pwnd_nsfw: if it's not on fire, you're doing it wrong
[23:58:53] Radar: Intii: I really do want to blame Spring for this. Remove it from your Gemfile
[23:59:09] Intii: Radar: Okay, give me a sec
[23:59:44] tubbo: Intii: also, try running `bundle exec rails generate`