Live data from Hacker News

Hacker's Guide to Setting Up Your Mac

lapwinglabs.com

151–160 of 267 posts

Re: Hacker's Guide to Setting Up Your Mac

#151
post #43

Earlier quoted context omitted.

It's slow and it has to build the packages most of the time. pkgin will install a precompiled packages very quickly. It is also a whole C program and Homebrew is just ruby scripts.

Homebrew now has prepackaged binaries ("bottles") for most of the packages that take awhile to build, which has really helped the speed thing.

Yeah, but they often rely on the homebrew being installed to /usr/local which is just plain bad advice.

At least, not using /usr/local myself, I see a lot of packages building because they have detected I changed the base directory.

Re: Hacker's Guide to Setting Up Your Mac

#152
post #142

One of the most valuable skills someone can have, in my opinion, is not getting attached to really specific workflows or settings or tools. Instead I value being flexible and being able to adapt to whatever system I'm using. In practice, this means that whenever I think about making some change to my software environment, my first impulse is to ask myself, "do I really have to change this?" This is a 180 from my old,…

I am exactly the opposite and it certainly has nothing to do with fun or self-image. I can hop on to any Linux box and be just fine. But I'm comfortable in a familiar setting with my `~/bin`, aliases, editor (vim), keybindings, a few key-remappings and package manager (pacman). There's a lot of benefits that come from having precisely the same environment on my web server, home machine, laptop, media PCs and my machine at work.

I consistently look for ways to automate things. I do it not because I'm a tweaker for tweaking's sake, but because I find it insane to let myself be annoyed by tasks that I know I can automate away. (Then my brain can forget the details of the operation because it is enshrined in code and maybe even some documentation.) For me, it's an efficient way to work. Actually, that's a nice way to sum up how I work: how can I most effectively offload This Stuff I Know so I don't have to worry about it any more?

I am extremely uncomfortable on Macs or Windows machines. The solution is to just not use them. (We, as programmers, are fortunate to have some freedom here. For example, I would not take a job with someone who forced me to use OSX or Windows.)

To give you an idea of how far I'm willing to go: I wrote my own window manager. I spent years on that path. I got something working around late 2012 and haven't really touched the X11 world since. I had some really specific goals that I wanted to accomplish (support 3+ monitors correctly), and I did, and now I'm happier and more productive for it. Another plus: people using Go now have native X client libraries.

Another example: I wrote 8,000 lines of Go to download all of IMDb and load it into a relational database in under 8 minutes (including building trigram indexes on all movie, episode, tv show and actor names). And then I built a command line utility that does fuzzy search and can rename all of my media files instantly. Renaming them manually was terrible drudgery. (And I certainly enjoyed the engineering challenge of making this fast.)

Sorry for the banter. :-)

Re: Hacker's Guide to Setting Up Your Mac

#153

This "cool hacker settings for your Mac" script turns off your laptop's power saving features (sleep, display dimming, hibernation even though sleep was off(?)), removes at least three kinds of backups for data loss (MobileTimeMachine, Resume, hibernation file), and changes AppKit settings in a way your customers will never be using (by turning off Automatic Termination, which is pretty harmless). Please don't run sc…

I agree with you 100%. I bought a new mac book pro 2 weeks ago and it took me about 2 hours to get up and running.

Because OS X is linux based (BSD but the difference is not relevant here), a lot already exists to make these kind of things work out of the box.

Personally, I need two things to have my setup working:

  - Homebrew (OS X only but it's a given to anyone used to ruby)

  - dotfiles
My dotfiles are on github and git can be installed via homebrew. I am using vim so my setup depend on both homebrew (git) & dotfiles (settings/plugins).

I have no idea why I would need anything more than that to get started. But this is personal, your company needs may be different. But don't think you need some kind of automation, linux has powerful tools. Use them.

Re: Hacker's Guide to Setting Up Your Mac

#154

I have an Ansible setup [1] that installs my dot files and other useful tools on Mac and Debian/Redhat derived platforms. I also created recently a Docker image [2] that runs my Ansible script so I can easily dev inside this Docker container. Just "git clone" and start working! [1] https://github.com/KyleAMathews/linux-config [2] https://registry.hub.docker.com/u/kyma/dev-image/

If you like Ansible you might also be interested in OSXC which is based on Ansible.

http://osxc.github.io/

Re: Hacker's Guide to Setting Up Your Mac

#155
post #3

Anybody have any suggestions on how to do this on a Windows PC? I like Ninite[1] a lot but I would prefer something more customizable. [1]: https://ninite.com/

http://boxstarter.org/

Just in the interest of sharing, this is my boxstarter script for my development VM: https://gist.github.com/jarshwah/58f5f9f78d43ae269545

Re: Hacker's Guide to Setting Up Your Mac

#156

Earlier quoted context omitted.

Right....but your user shell has nothing to do with shellshock. Shellshock involves things like Apache invoking system calls that need a shell, and those system calls don't care what your user shell is. They care what /bin/sh and /bin/bash are (or wherever your system shells live, it's /bin for OSX). This guide is claiming that updating your login shell to bash via Homebrew will mitigate shellshock, which is flat-out…

OK, but nothing in your comment implied that you were talking about the "Shellshock" vulnerability. I believe that a very recent OSX update patched this vulnerability, anyhow.

Oops, a very good point. I should have mentioned that right off the bat: my issue was with calling this a "hacker's guide", when it contains a pretty blatant security issue.

Re: Hacker's Guide to Setting Up Your Mac

#157

This "cool hacker settings for your Mac" script turns off your laptop's power saving features (sleep, display dimming, hibernation even though sleep was off(?)), removes at least three kinds of backups for data loss (MobileTimeMachine, Resume, hibernation file), and changes AppKit settings in a way your customers will never be using (by turning off Automatic Termination, which is pretty harmless). Please don't run sc…

I agree with you 100%. I bought a new mac book pro 2 weeks ago and it took me about 2 hours to get up and running. Because OS X is linux based (BSD but the difference is not relevant here), a lot already exists to make these kind of things work out of the box. Personally, I need two things to have my setup working: - Homebrew (OS X only but it's a given to anyone used to ruby) - dotfiles My dotfiles are on github and…

> Because OS X is linux based

Wait... what?

> (BSD but the difference is not relevant here)

Still, "Linux-based" is a funny way of saying "Unix-like". Is HP-UX also "Linux-based (System V but the difference is not relevant here)"? ;)

Re: Hacker's Guide to Setting Up Your Mac

#158
post #150

Earlier quoted context omitted.

My understanding is that Homebrew does not clobber any system defaults — works with the OS, not against it. I could be wrong, though.

No, MacPorts is actually more sane in this regard because it build it's own set of dependencies instead of relying on anything the system provides. This makes it a more soundly designed tool, IMO. Homebrew also recommends using /usr/local as the root which I think is just plain bad advice, but it is simple enough to change it to something else.

Why is /usr/local bad advice?

Re: Hacker's Guide to Setting Up Your Mac

#159
post #109
post #46

Do any of you use Dock replacements? I'm faster with the Windows-style taskbar and uBar ( http://brawersoftware.com/products/ubar ) was the sponsor of the last episode of John Gruber's podcast.

Years ago I thought DragThing ( http://www.dragthing.com/ ) was the coolest thing around. I went around making all sorts of clicky things to litter my desktop with. It's apparently still developed though I don't think I've seen any screenshots of it from this decade, so it might be wishful thinking that it would've kept up with OS X UI styling. uBar looks interesting though and it's nice to see people working on this…

I think the developer spends more time working on PCalc, and even then, I think the iOS version gets the most attention.

I last used DragThing back in the OS 9 days. With the OS X dock, it didn't seem as necessary. Couple that with LaunchBar (or Alfred/Quicksilver) and I have basically my launch needs met.

Re: Hacker's Guide to Setting Up Your Mac

#160
post #81

Earlier quoted context omitted.

Assuming you have uBar installed, is there anything about it that makes it feel like an add-on? Or does it feel like it's really a part of the desktop environment? (I'm not talking about design aesthetic or anything like that, just wondering if it gets wonky sometimes)

That's what I want to know too.

Well, you get a 4 week trial, so that should give you a good idea of it.
Post reply on HN