« first day (1136 days earlier)      last day (2119 days later) » 

3:08 AM
I usually don't post gif but I'll pay my tribute to you @WayneConrad i.imgur.com/5YqLQYi.gifv
 
Heh, thanks :)
 
If you move the link to it's own message chat will onebox it
Sorry I missed the good morning thing today (?). Could've been 6 :(
Also, someone mentioned a gem for otter ascii art and I am on top of it
 
I've been in Mexico today so that's my excuse.
 
I was competing in a robotics competition as the team coder. I got to pretend I know how java works.
I just registered the otter gem
They will be on gitlab tommarow
And on that note, I will go to sleep. Good night everyone!
 
Awesome! g'nite @thesecretmaster
 
3:24 AM
does anyone on here have experience with linux?
 
Ooo I just did some maths and I've slept 4 out of the last 52 hours. Also I do linux.
I will delay my sleeping if the question is quick
Ask away @qaispak
 
@thesecretmaster have you ever used arch linux?
 
No, but I've heard much about it. Do you use it? Or are you considering switching to it? Or do you need to solve a problem on it?
 
basically... I have been using it on and off for a few months but I don't feel I'm learning too much. Rather I am just getting frustrated and it doesn't make sense and I wanna switch to something like ubuntu
but then I fear such an attitude will stunt my growth and I should stick to it
so I guess I'm looking for advice on what to do at this stage
I am spending wayyyyyyy more time "trying" to learn sys admin stuff than coding
 
It really depends on what you're looking for. There are so many distros, as I'm sure you know.
 
3:29 AM
I just wanna be able to use the terminal and setup/configure my stacks easily
 
I use mint and it works fine for me. But I've actually recently been experimenting with pentesting/security type distros.
I think that if that's all you need than almost any distro should be fine.
From what I know arch is for people who want to build the os, picking components from the ground up.
Any distro will let you use the terminal, and depending on the stacks you're using most distros should be OK.
 
@thesecretmaster in general I like to understand concepts from the ground up so that's one of the reasons arch really interested me but I think it was the wrong decision tbh
another reason I liked it was that it had on bloat software
 
If I were you, I'd get accustomed to linux on an "easier" distros, then once you kinda know your way around and understand a bit of how linux works under the hood you can move on to a harder distro like arch. Although for what you need I think an "easier" distro would work fine. On linux, most of the time the bloatware is easily removable though a package manager like apt or whatever.
 
Also there are way more Q&A for Ubuntu than for Arch
 
3:36 AM
Actually @FranklinYu Idk how true that is. Q &A yes but Arch has wayyyy better documentation
and if I do spend the time, I understand/appreciate arch way better. The problem is spending the time to understand that can take forever sometimes
 
Arch has docs, ubuntu has q&a, they're both good in different ways.
 
So it's again just personal preference, and you already knows the pros and cons of either.
 
For me, whenever I google a problem, I can find a solution, which is nice, because I don't want to go down the linux rabbit hole.
 
"The problem is spending the time to understand that can take forever sometimes"
Story of my life.
 
I think that as long as you are willing to put in the time to understand the things, then arch might actually be a good fit for you. Learning may be slow, but that's how most things are. Eventually, you'll get the hang of it, and you'll be happy that you put in the time to understand everything instead of taking the "easy" route of Ubuntu or mint or whatever.
 
3:40 AM
So that's a question similar to "should I take Ruby or C as my first language to learn?" and it really depends.
(I feel like I just repeated "YMMV" in several different ways.)
 
Well see that's the thing. I had C and C++ as my first languages and I am very happy I chose those. Similarly I might be way happier if I stick to arch but I suppose the choice isn't as simple because the time I spend learning arch could be spent learning other software....
but I guess there's no easy answer haha
 
You sound really motivated to learn arch, so I'd say go for it. You sound like you will really be happy that you put the time in and learned it.
^^ Based on about 5 sentences
 
haha you're right but discipline > motivation and I have to have that too
but this discussion has been helpful
 
Actually suggestion: Dual boot arch and some other distro. Then whenever you don't feel like dealing with arch you can switch to your other distro, and if you feel like questing into the depths of linux, then you can boot to arch.
 
hmm not a bad suggestion at all
 
3:48 AM
For example I dual boot mint and a (not very good) distro called parrot, and if I feel like fighting with parrot to make it work I boot to that, but if I just really need write some code and parrot is giving me some obscure error about being unable to save files, then I'll jump back to mint.
The only thing I'd warn you about is that you may find yourself dedicating less time to learning arch that way, so I'd try to set aside time to mess with arch so that you don't just start defaulting to the other distro.
Anyways, good luck on your linux quest. I'm going to go to sleep now. Feel free to come back if you have any questions about choosing distros or something. I don't think we have anyone here who is a linux expert, but we have at least 2 linux users who can give some advice.
 
g'nite @thesecretmaster, and thanks for giving good advice.
 
4:14 AM
@qaispak I'm also proud of C/C++ background. C/C++ is the language to learn data structure and algorithm in my mind.
 
@FranklinYu I disagree a little. C/C++ force you to spend so much time managing munitia such as memory management that often the algorithm is obscured or too difficult to code. I remember coding some algorithms from the Dragon book in C++, and they were very difficult. In a language such as Ruby, however, you can focus more on the algorithm and less on all of the tiny details.
I hate to comment and run, but I've goto to run. But thanks for dropping by and chatting. Take care, bye for now.
 
 
8 hours later…
12:41 PM
@thesecretmaster I don't like oneboxing gif, it's too invasive for gif.
 
 
1 hour later…
2:18 PM
Animated GIFs are not good to one-box. Other GIFs I don't mind so much.
 
2:37 PM
Indeed static image are ok, but even then there should be a way to minimize image in chat
 
That would be really nice.
 
3:01 PM
I recorded that this morning. It's raining here, and has been for a day (kind of rare for where I live). It seemed fitting to record some blues in the rain.
 
 
4 hours later…
7:06 PM
Please remind me, other than that they are inherited, is there a reason to avoid @@static_variables?
 
@@they make the code hard to reason about and refactoring difficult.
 
What do you recommend for a regexp cache?
@@regexp_for ||= Hash.new {|h, k| h[k] = Regexp.new foo(k)}
 
Make it a regular old class. If you want it to be conveniently accessible everywhere like a global variable, plus initialized automatically, then make it a singleton.
 
7:24 PM
Why doesn't it share the downsides of static variables?
 
What is "it"?
 
Why doesn't a singleton class have the same issues that a static variable does?
 
Because it is, other than its singleton-ness, just like any other class. There are no funky inheritance rules. Initialization is done by the #initialize method. It's vanilla.
 
user5870134
7:40 PM
Good evening, guys.
 
user5870134
@WayneConrad Wow... You are really good :D
 
user5870134
@WayneConrad I laughed a bit when I saw your "rain is kind of rare for where I live" comment, you should really see the kind of weather (storms / rain / hail / snow / freezing cold temperatures) we have to put up with EVERY SINGLE DAY :D
 
@Mango Thank you very much.
 
user5870134
Imagine if everyone got the opposite temperatures of what they're normally used to. E.G: if South U.S. got the temperature Scandinavia has, and Scandinavia got the temperature the South has.
 
It would be a bit of shock to both.
 
user5870134
7:49 PM
Without diving too deep into the details imagine what would happen to the plant life that has evolved over thousands of years to deal with those types of temperatures.
 
I guess I'd get my own temperatures? Czechia here.
 
@JanDvorak Heh, I guess so.
 
user5870134
I can only imagine the response of the U.S. Gov :D
 
user5870134
@JanDvorak How so? What kind of weather do you have over there?
 
0-30 C most of the time
> The coldest temperature ever measured was in Litvínovice near České Budějovice in 1929, at −42.2 °C (−44.0 °F) and the hottest measured, was at 40.4 °C (104.7 °F) in Dobřichovice in 2012.[65]
 
user5870134
7:53 PM
But do you guys have "violent weather" like floods, storms, etc...
 
user5870134
@JanDvorak What an even scale :D
 
The more reason to use Celsius :-D
 
user5870134
I think The U.S. is the only country that doesn't use Celsius.
 
USA, and some tiny islands in the Oceania and in the Carribean
 
user5870134
Honestly speaking, I think it's pretty safe to call those "The Extended U.S." or "The Unofficial / Unincorporated U.S. Territories".
 
7:59 PM
USA++
 
user5870134
Haha! Exactly :D
 
user5870134
8:40 PM
And.... We're back to 0...
 
user5870134
9:07 PM
Preventing exact duplicate file uploads sounds so simple but has to be one of the hardest things I've attempted to implement.
 
Why?
 
9:39 PM
@Mango MD5 checksum (or SHA1, or etc.) is good for this.
I worked at a place that needed to detect duplicate uploads. Every upload that was accepted had its MD5 checksum stored in the database. Every upload first had its MD5 checksum checked against the database; we reliably prevented duplicate uploads this way.
 
10:03 PM
I'm going to do something awful... I'm going to mutate the output of Enumerator#peek ... and rely on the side effects to persist.
 
user5870134
Oh my god... @WayneConrad You genius!
 
Is someone good with Bootstrap modal here? I can't see why my modal is not showing when I clearly see it in the source code
 
user5870134
My, my... The old bootstrap modal, man those things are hard to work with.
 
12
Q: rails 4 bootstrap 3 ajax modal

dracI'm busy learning Rails 4 and I would like to display a bootstrap popup modal when a user clicks on a link, when the modal opens it needs to show the information relating to that particular record. Heres what I have done so far, which just doesn't show the actual modal popup BUT does pass the co...

I'm using the answer from there
 
user5870134
@Marc-Andre Why don't you just create a "div" that has it's visibility toggled after a certain event is triggered?
 
10:08 PM
I do like the blacked out effect
 
user5870134
That's very easy to implement, if set the position of the parent's div to absolute, set it's background colour to a "rgba" colour, disable page scrolling, and centre it horizontally and vertically then show your "modal div" over that.
 
user5870134
@Marc-Andre Anyways, did you get it to work?
 
Well when I clicked my link, the code is called, the content is replace inside the div, the blacked out effect is there, but the content of the modal doesn't show
But I can see it in the source.
 
user5870134
I would like to see what's going on. Are you able to upload a screenshot?
 
Oh I think I know what's going on
 
user5870134
10:13 PM
@Marc-Andre Check the CSS of the modal, is there a property that isn't allowing it to show?
 
I think the modal show is called before the html is replace by the ajax call
 
user5870134
Then you need to wait for the AJAX call to complete, and then update the visibility of the modal.
 
Nope it's not that..... I think
 
user5870134
You need Dr. Phil
 
Baby is waking up later
 
user5870134
10:17 PM
No, I'm not saying you need Dr. Phil because of the baby, I'm saying you need him because you don't know exactly what is wrong :D
 
user5870134
11:42 PM
@WayneConrad Once again, THANK YOU! By checking the MD5 sum of the files & comparing them I was able to remove ~28 lines of code, and now I don't have to read every file byte for byte and compare it to the current file by reading it byte for byte.
 

« first day (1136 days earlier)      last day (2119 days later) »