Live data from Hacker News

Unix as IDE

sanctum.geek.nz

201–210 of 214 posts

Re: Unix as IDE

#201

Earlier quoted context omitted.

Every abstraction has a cost somewhere. If you want to use your computer to its full potential, avoid them all.

> Every abstraction has a cost somewhere. It's very simple: (0) Runtime performance degradation is unacceptable. (1) Increased compile times are annoying, but they're tolerable in exchange for more exhaustive automatic static analysis. Anything of interest that the compiler can't prove about my code, I would have to prove myself by hand anyway, which would take even more time than the slowest automated static analysi…

> Runtime performance degradation is unacceptable

Requirements like these are not grounded in real software use.

In economic terms: a cheaper/slower software can be acceptable over a more expensive/faster software. Example: Java-based software vs. the same written in C++.

In reliability terms: a more robust / slower software can be acceptable over a more expensive/faster software. Example: Erlang-based software vs. C++ software on a network switch.

And so on.

Abstract/absolutist requirements like 'Runtime performance degradation is unacceptable' is not often found in actual software development/use.

Software usually has a multitude of different important qualities. Raw performance is just one of these. Especially one then needs to say what performance exactly and how to measure it. Performance can be measured in many ways: throughput, latency, micro-benchmark speed, etc. etc. Optimizing one (say, throughput) then has effects on others (say, latency). To achieve faster throughput, some functionality can be affected.

Re: Unix as IDE

#202

Earlier quoted context omitted.

Every abstraction has a cost somewhere. If you want to use your computer to its full potential, avoid them all.

> Every abstraction has a cost somewhere. It's very simple: (0) Runtime performance degradation is unacceptable. (1) Increased compile times are annoying, but they're tolerable in exchange for more exhaustive automatic static analysis. Anything of interest that the compiler can't prove about my code, I would have to prove myself by hand anyway, which would take even more time than the slowest automated static analysi…

All abstractions degrade runtime performance. Even "zero cost" ones, as they get you to think in less efficient ways, about things like encapsulation, and whatnot.

If runtime perf degradation is really unacceptable to you, you shouldn't be writing in functional languages, or even C. You should be writing in raw asm, as low-level as possible.

Re: Unix as IDE

#203

Earlier quoted context omitted.

With evil-mode, which is what spacemacs is based on, you get it.

Interesting. Does it have text objects?

Yes. It includes most of the standard vim text objects, as well as providing an api for you to write your own. It also has the usual motions, plus an api to add your own. There are existing extensions for the more common vim plugin-provided motions as well.

Re: Unix as IDE

#204

Earlier quoted context omitted.

> Every abstraction has a cost somewhere. It's very simple: (0) Runtime performance degradation is unacceptable. (1) Increased compile times are annoying, but they're tolerable in exchange for more exhaustive automatic static analysis. Anything of interest that the compiler can't prove about my code, I would have to prove myself by hand anyway, which would take even more time than the slowest automated static analysi…

All abstractions degrade runtime performance. Even "zero cost" ones, as they get you to think in less efficient ways, about things like encapsulation, and whatnot. If runtime perf degradation is really unacceptable to you, you shouldn't be writing in functional languages, or even C. You should be writing in raw asm, as low-level as possible.

Encapsulation is making the internal representation of abstract data types not visible to their clients. In other words, it's a discipline for writing programs. Some languages (e.g., ML) just happen to helpfully enforce that discipline for you. It has no runtime impact whatsoever.

Re: Unix as IDE

#205

Earlier quoted context omitted.

Git was made in, what, 2005. We knew about discoverability then. We knew about accessibility then. We knew about user testing, about UX. Git makes use of zero of those concepts. In fact, it seems to be actively hostile towards its users^. We also had source control packages that were not only easier to use, but had more features: TFS let you put a lock on files that don't merge well, for example. Both TFS and Subvers…

> Yes, someone's going to come in here and say, "well it's a professional tool for professionals therefore it's ok that it's difficult to use and hostile and not accessibility to people who can't use a CLI due to physical limitations because it's a professional tool for professionals. Oh that's nonsense. First of all, because git is a CLI application you can easily build a GUI for it, and there are a lot of them for…

> Oh that's nonsense.

Ok...

> First of all, because git is a CLI application you can easily build a GUI for it,

Actually you can't, because Git has features like "pre-commit hooks" and it's literally impossible to translate the output/messages of those into reasonable form for a GUI to consume (since it's just freeform CLI output text). The best you can do is simply echo them back to the user in a stupid text dialog box. You'll notice all Git GUIs either don't support pre-commit hooks at all (always commit with them set to disabled), or display the output of them using the lazy text dialog box method.

The other limitation, of course, is that since Git has no library, it's impossible for a GUI to be based on Git without it actually using Git CLI commands in the background. Which means if the Git CLI changes its commands, suddenly its broken all GUIs built off of it. (GUI clients generally "solve" this problem by shipping their own Git binary and using it exclusively, even if a newer one is on the same system.)

(It's funny that you mention WinForms. What Git does with its CLI commands is pretty much exactly equivalent to a WinForms app with business logic in the event handlers. Except where any WinForms developer would say, "why are you mixing up the UI and the program logic? That's a terrible idea!" apparently Git developers think it's great and double-down.)

It's impossible to build a truly quality GUI without the product being designed with that in mind from the start. Git wasn't. And there was simply no excuse for that in 2005.

> You can't do the reverse,

The correct way of writing an application is to put all the functionality into a library, then keeping your user interfaces separate from that library. So while you're right that you can't do the reverse (build a quality CLI from a GUI application), if the developers of Git had done their job correctly, you wouldn't have to. Git would have a core library that anybody could build any kind of user interface from.

> Second, what "physical limitations" put people into a position where they can code but they can't use a CLI?

Dyslexia. I can manage in an IDE with a large dependence on auto-complete, but I can't do a CLI.

Since I grew up on Macs and it's only relatively recently that crud like Git has been seeping into the Windows development scene, this had never been a limitation for me in the past. Worse than being user-hostile, Git makes me feel disabled in a way no other program has.

> Multimedia artists are among the people who are most resistant to ever switch tools due to how much they have mentally invested into the complexities of their go-to application. Your example is far from good.

I'm sorry my examples do not meet your exacting standards.

Re: Unix as IDE

#206

Earlier quoted context omitted.

All abstractions degrade runtime performance. Even "zero cost" ones, as they get you to think in less efficient ways, about things like encapsulation, and whatnot. If runtime perf degradation is really unacceptable to you, you shouldn't be writing in functional languages, or even C. You should be writing in raw asm, as low-level as possible.

Encapsulation is making the internal representation of abstract data types not visible to their clients. In other words, it's a discipline for writing programs. Some languages (e.g., ML) just happen to helpfully enforce that discipline for you. It has no runtime impact whatsoever.

Not true. While the various abstractions themselves may have no runtime impact, they encourage programming in ways that, while they may be good for maintainability, aren't as fast. For example, if you're using ML, you'll likely represent a list of objects (say, structures representing addresses) by establishing a type for the objects, and keeping a list of them. A C programmer might use a statically allocated array, or actually embed a pointer to the next object in the list into the struct. The C program might be less maintainable, but it would be faster because it's doing less pointer chasing. An asm programmer might optimize further.

Now, this is a fairly trivial example, and not too hard for a compiler to optimize out, IIRC, but it's just an example. Other instances of this are far harder to optimize away.

The further up you are from the hardware, the less aware you are of the perf tradeoffs, and the less you can do to fix it. So if you want the best perf, go for asm.

Re: Unix as IDE

#207

Earlier quoted context omitted.

Git was made in, what, 2005. We knew about discoverability then. We knew about accessibility then. We knew about user testing, about UX. Git makes use of zero of those concepts. In fact, it seems to be actively hostile towards its users^. We also had source control packages that were not only easier to use, but had more features: TFS let you put a lock on files that don't merge well, for example. Both TFS and Subvers…

> We knew about user testing, about UX. Git makes use of zero of those concepts. In fact, it seems to be actively hostile towards its users^. I was with you all the way here, and then suddenly... > We also had source control packages that were not only easier to use, but had more features: TFS let you Suddenly you mention TFS as an example of something good. Mind blown. TFS is absolutely among the worst "popular" ver…

> Suddenly you mention TFS as an example of something good.

You need to work on your reading comprehension. The only claim I made about TFS is that it has a feature (locking files) that Git doesn't.

I cited it as an example that Git has fewer features than its competitors. I never said anything about its quality.

> This has nothing to do with Git specifically. This is a difference between centralized and distributed. If you want the benefits of distributed source-control, you'll have to pay the cost.

Fine; but that's not the point.

The point is it's a feature that I want. And now that Git has seemingly taken-over the field of source control, I no longer have it. Nobody does. It's gone.

I'm not a fan of newer software having fewer features than older software.

Re: Unix as IDE

#208
post #89

Earlier quoted context omitted.

If you're going to hate on something almost universally respected, you're going to have to explain yourself.

I'm a vote in the got sucks camp, its not universally respected amongst the programmers I know we just put up with it because its dominant. I always preferred mercurial but that fight is largely lost, I could use a mercurial -> whatever bridge but I'd still need to know git for when things break. Git's ui is simply horrible in my opinion.

I want to thank you for posting. I know that the groupthink around Git, especially on forums like this one, is so powerful that by even mentioning that Git has flaws and isn't some kind of angelic perfect software from heaven runs the risk of having a billion down votes.

Re: Unix as IDE

#209

Earlier quoted context omitted.

Encapsulation is making the internal representation of abstract data types not visible to their clients. In other words, it's a discipline for writing programs. Some languages (e.g., ML) just happen to helpfully enforce that discipline for you. It has no runtime impact whatsoever.

Not true. While the various abstractions themselves may have no runtime impact, they encourage programming in ways that, while they may be good for maintainability, aren't as fast. For example, if you're using ML, you'll likely represent a list of objects (say, structures representing addresses) by establishing a type for the objects, and keeping a list of them. A C programmer might use a statically allocated array,…

> For example, if you're using ML, you'll likely represent a list of objects (say, structures representing addresses) by establishing a type for the objects, and keeping a list of them.

In ML, most of the time I don't work with objects at all. I work with values. The beauty of programming with values is that the language implementor can represent them however he wishes, as long as he respects the semantics of the operations on said values. For example:

(0) Multiple logical nodes of a recursive data structure can be represented as a single physical node, eliminating the need to store pointers between them. For example, an ML implementation can determine that `List.tabulate (n, f)` always creates a list with `n` elements, and thus always pre-allocate a single large enough buffer before actually computing the elements. In Lisp, this wouldn't be a valid optimization, because Lisp mandates that every cons cell has its own object identity.

(1) Values with large representations can be automatically deduplicated, hash-consed or whatever it takes to reduce their memory footprint. Again, this is only possible because physical identities don't matter in ML (except for mutable cells and arrays).

In other words, values give the language implementation freedom to make useful physical data structure choices. Unlike objects, which come tied to a fixed representation.

There is no tradeoff between abstraction and efficiency, when you use the right abstractions.

Re: Unix as IDE

#210

Earlier quoted context omitted.

I'm a vote in the got sucks camp, its not universally respected amongst the programmers I know we just put up with it because its dominant. I always preferred mercurial but that fight is largely lost, I could use a mercurial -> whatever bridge but I'd still need to know git for when things break. Git's ui is simply horrible in my opinion.

I want to thank you for posting. I know that the groupthink around Git, especially on forums like this one, is so powerful that by even mentioning that Git has flaws and isn't some kind of angelic perfect software from heaven runs the risk of having a billion down votes.

People get silly when it comes to tools they've invested time in, lots of people don't like to think they made the wrong choice and will defend it often to the extreme, I don't get invested in tools I use what works for me and switch when it seems reasonable.

Git is a necessary evil basically.

Post reply on HN