These are chat archives for codefellows/sea-c16-javascript

22nd
Jul 2014
Mandi Grant
@MJGrant
Jul 22 2014 00:04
@joeelsey Does your file start with var _ = require ('lodash');?
@joeelsey I was able to get this code to deliver an array of Stooge names in my own local file:
var stooges = [{name: 'moe', age: 40}, {name: 'larry', age: 50}, {name: 'curly', age: 60}];

getStoogeNames = function(stooges) {
  var stoogeNamesVar = _.pluck(stooges, 'name');
  console.log("Stooge names: ", stoogeNamesVar);
};

getStoogeNames(stooges);
This message was deleted
That renders this result in Terminal: Stooge names: [ 'moe', 'larry', 'curly' ]
Joe Elsey
@joeelsey
Jul 22 2014 01:23
I didn't before. I was able to make it work now. Thank you.
Mandi Grant
@MJGrant
Jul 22 2014 01:57
Awesome!
Scott Romney Burbidge
@sburbidg
Jul 22 2014 03:17
@faheydesign cool, thanks.
Scott Romney Burbidge
@sburbidg
Jul 22 2014 03:44
the websites I found to explain this kinda over complicated it
so here is a simple explanation on how to debug your js files in chrome
Scott Romney Burbidge
@sburbidg
Jul 22 2014 03:54
This message was deleted
This message was deleted
Scott Romney Burbidge
@sburbidg
Jul 22 2014 17:33
So for something like a node_modules folder is it best to just do a global ignore?
Hank Yates
@hankyates
Jul 22 2014 17:33
yup
i put mine in ~/.global_gitignore
then in ~/.gitconfig
[core]
  excludesfile = ~/.gitignore_global
Scott Romney Burbidge
@sburbidg
Jul 22 2014 17:36
and once you do that you don't even need to worry about the file type you ignore when you install it into a new project?
Hank Yates
@hankyates
Jul 22 2014 17:36
yeah pretty much
Scott Romney Burbidge
@sburbidg
Jul 22 2014 17:37
certainly a lot less tedious, Thanks
Ivan Storck
@ivanoats
Jul 22 2014 18:28
If you’re on a mac, also put .DS_Store in your .gitignore_global
Hank Yates
@hankyates
Jul 22 2014 18:28
oh please do that
thanks @ivanoats !
oops, forgot node_modules! :panda_face:
Scott Romney Burbidge
@sburbidg
Jul 22 2014 18:45
where do you put the global git ignore? Some places are saying in your root directory and some are saying in a repository.
Hank Yates
@hankyates
Jul 22 2014 18:46
i put it in my home folder
.gitignore is for a repo
Scott Romney Burbidge
@sburbidg
Jul 22 2014 19:19

Idk if this will help anyone but it helped me when I sort of messed up where my .gitignore files were.
enter:

defaults write com.apple.finder AppleShowAllFiles TRUE

TRUE will show hidden files and FALSE will hide them again.

Tyler Morgan
@toastynerd
Jul 22 2014 19:20
you can also use ls -a
Scott Romney Burbidge
@sburbidg
Jul 22 2014 19:21
ah, that is simpler. I was trying to find the ls option that would include hidden files.
Tyler Morgan
@toastynerd
Jul 22 2014 19:22
You can also use -A if you want to exclude . and ..
Ivan Storck
@ivanoats
Jul 22 2014 19:24
I wrote a Mac app for this too : https://github.com/ivanoats/ShowInvisibles
Scott Romney Burbidge
@sburbidg
Jul 22 2014 19:28
when it shows you something like
usage: ls [-ABCFGHLOPRSTUWabcdefghiklmnopqrstuwx1] [file ...]
how do you look at the [File...]?
Scott Romney Burbidge
@sburbidg
Jul 22 2014 19:34
or how do you look up what all those usages do?
Tyler Morgan
@toastynerd
Jul 22 2014 19:34
man ls
man ls
Scott Romney Burbidge
@sburbidg
Jul 22 2014 19:35
oh, for some reason I was doing man -k ls
Tyler Morgan
@toastynerd
Jul 22 2014 19:36
yeah, you only want to use apropos if you don’t know the name of the command
Scott Romney Burbidge
@sburbidg
Jul 22 2014 19:38
oh okay. I had forgotten about the manuals. They are super helpful
Livingston Martin
@LPM42
Jul 22 2014 19:44
@faheydesign love the jQuery tutorials! Very helpful.