+1 That thing is gross. I'd edit so much more slowly if I had to go back to a messy, complex syntax. At least without a very clever / specialized editor effectively undoing the change for me.
Infix is occasionally more readable for math, but I'd rather have a macro to transform a delimited section of infix code than to mess with the language.
One thing me and my teammate did in our last Clojure gig was to not shorten namespaces (with the `:as` keyword).
Instead of in this example write `[cognician.chat.dom :as dom]` just write `cognician.chat.dom`. Then when calling, use the whole namespace.
It's a tradeoff between typing a little bit more (in reality, using the autocomplete function) in exchange for having the code readable. When you read something on line 213, you don't have to scroll up to double check what that short name refers to.
I have been working on a Clojure (so JVM) program that I run in Docker for Mac.
It requires some data on disk, which is about 100GB. Since my laptop has a pathetic 250GB SSD I got an external drive for this. All well.
But I get the problem that the Mac shuts down after doing IO from inside the VM for about 10-20 minutes. Just a black screen and a second later reboot.
Has anyone on this forum had the same issue? I have the same when running in VirtualBox, and after wiping the Mac totally and reinstalling the OS. Happens using both USB and Thunderbolt.
Docker for mac has absolutely dreadful filesystem performance for mounted volumes (Docker toolbox with the extra virtualbox indirection actually ends up being faster if you're doing filesystem reads even remotely frequently). If you need to work with 100GB on disk you're going to have a lot of problems.
For this reason I went out to buy a Intel NUC and am now running NixOS on there. Developing on that machine, with a Clojure nRepl connected via SSH. Works great, especially since my service can now be running and fetching data from the internet when my laptop is closed, so that next time I work I don't have to wait for my service to catch up with the world.
I do so because my Clojure app I'm writing also depends on other programs from 3rd party vendors (open source stuff). I'm too old to spend time setting shit up on every develop machine, server etc. If I can just write one declarative file (docker-compose.yml) and then be done that's nice, so that is what I do.
Deploying on Linux anyways, so Docker isn't a performance overhead.
> It requires some data on disk, which is about 100GB
As someone who develops on a Macbook with a 128 GB drive, this is completely crazy to me. How is it taking up 100 GB? I use Docker for Mac for most of my day-to-day development, mostly for running docker-compose environments so I have separated Redis/Postgres environments for each app. They take up nowhere near 100 GB. Something sounds very wrong, but I can't imagine how it would be caused by the JVM running Clojure.
Oh, I read it as "Yeah it takes up some space on my drive, like 100 GB". Having it as actual data the program is processing makes way more sense, sorry about that.
>Tipping culture also introduces uncertainty into pricing, and means that nicer people pay more and jerks get to pay less, for the same service.
Why is someone a jerk for not tipping? I pay for service provided - give me a receipt with the amount and I'll pay it, no problem. Let's end tipping, folks...
It would require a legislative solution to end tipping. Until that happens, most restaurants pay their servers $2.13 an hour, with the rest of their pay coming from tips. If you don't tip at a restaurant that does make you a jerk. I don't like tipping culture either, but as long as you live in one, you've just gotta play along with it. Think of tips as an added tax on the price, and go out less if necessary to keep your costs under control.
But it's really hard to enforce, and if you were a waiter who consistently had to ask to be topped off to meet minimum wage, you might be putting yourself on thin ice with the manager.
As scarmig says, it's hard to enforce, but even if it is correctly enforced, it's on a per-paycheck basis, not on a strict hourly basis. So imagine a server who makes an average of $20/hour with tips (which seems reasonable) -- if suddenly two-thirds of customers become tip abstainers then the server's pay will drop down to right around the normal minimum hourly wage. The top off only gets you up to poverty wages (keep in mind many server jobs are part-time); any lack of tipping above that point is pure loss for the server.
Also, I happen to be in Madrid right now, which doesn't have a tipping culture, and let me tell you that I've had some pretty bad service here. Way worse, on average, than in the United States.
Complying with minimum-necessary legal obligations is insufficient to not be considered a jerk. There are many jerky things one can do that aren't illegal.
Stiffing someone, legally or not, because you'd like to see the renumeration system under which they're paid change is obnoxious. You're not sending a message[1] and you're not applying pressure where it could influence change[2]. You're underpaying someone who can't afford it, and have no room complain when people notice what you're doing. I personally do believe it reflects on character.
[1] Well, you are... just not the one you intended.
[2] To be clear, I'd love to see tipping go away, too.
It's a social expectation. You can expect not to get great service at a restaurant or even have the staff ask if there was a problem if you didn't leave a tip.
Why do operating systems allow users to run any executable?
For programmers it's important to be able to - but when you're not coding, running any executable is not required.
It should be that all programs are in /usr/bin & the others. Only root can write there. Users shouldn't be able to run any program that is located anywhere else.
Most of the machines out there are single user, and managed by that user, not by a professional sysadmin. As such, the user has the needed access (root) to install any programs that they want, and all modern OSes allow only the admins to install programs.
We already put multiple warning messages when a user decides to execute a suspicious binary, and yet everyone still clicks through any prompt without the second thought ?
What's your suggestion that a). allows any user to have the machine installed and configured as he wants? and b). do not allow random programs from executing ?
The one part I miss to be able to claim understanding of zero-knowledge protocols is anchoring the story to what one uses (modern) ZKPs for. Hoping to read that connection here in the HN comments.
Zcash is the first open, permissionless cryptocurrency that can fully protect the privacy of transactions using zero-knowledge cryptography. The Zcash client is now available for download as a command-line tool for Linux.
Having not heard of Angie's List before I decided to check their website out. If anyone working on that is reading HN, you might find it interesting that I didn't understand at all what the website was for until reading all the way down to the testimonials.
Until then it was all about how happy users are and how many solutions it provides.
Might be a good idea to put a one-liner explanation somewhere very visible.
It's a sales funneling technique. By the time the user has reached the bottom, he has been prepped with all the glowing testimonials and ready to sign up. For a casual visitor, as blunt as it is, you are not their target audience.
They do a huge amount of radio advertising -- so most visitors are likely coming from radio ads that explain what they do. People that visit AL already know why they're there.
I've used TypeScript, Flow and Elm for making front-end apps. My favourite of the three is by far Elm, even if that was a bit harder to get into (as it's a new language and I didn't know before how to do side-effect free programming).
Flow is definitely a better type system than TS. TS types are "strong" in the same way as Java types. Flow is basically OCaml types, so a similar type system to OCaml, Haskell or Elm (except that you can give things `any` type). I am sure I will chose Flow over TS for that reason.
A ML-type type system (Flow, OCaml, Haskell, Elm, etc) is very powerful in that you can have abstract types, which means you can do basic composition of them. Things like the Maybe or Result monad for instance, which is very useful (and simple).
Typescript on the other hand let's you use the basic JS types, but it's not as extensible.
Do you have any examples to back up your claims? I don't think Flow's type system is more advanced than TypeScript's (which is not Java-like in any way).
What do you mean by "abstract types"? TS's type system is based around structural interfaces, so you're almost always working with non-concrete types.
It also supports discriminated unions, and you can emulate nominal typing with abstract tag properties.
Being vegetarian is easy and healthy. I recommend it. If nothing else, buy a nice cookbook and make it a habit to cook nice non-meat food one night a week. Make it a date with your partner!
It's worth reiterating that there's a whole continuum between eating meat and eating no meat called "eating less meat". Always amazes me how people overlook this when writing off reduced meat consumption as not for them.
Vegetarian Cooking for Everyone by Deborah Madison is a great way to start down this path.
Thanks for pointing that out. I'm not a vegetarian, but when I order a veggie burger I'm often asked if I am.
I eat meat once a week or so, and would have a hard time passing on some of the cultural norms around meat (Thanksgiving turkey, etc.) but eating 90% less meat means 90% lower meat-related emissions.
Of course, if your reason for being vegetarian is animal welfare and ethics, then this rings hollow ("I commit 90% fewer murders!")