Live data from Hacker News

A pure JavaScript implementation of Git for Node and browsers

github.com

131–140 of 203 posts

Re: A pure JavaScript implementation of Git for Node and browsers

#131

JavaScript: Because that's what we know.

Possibly; but as someone who maintains a NodeJS native addon in C++, I frequently _dread_ new releases of NodeJS that invariably break my bindings. A shim library called "NaN" has done so much to help with this; I would have given up sooner. Having libraries implemented purely in the language from which the library is implemented solves many many headaches, irregardless of JavaScript or not.

NAPI has ease that pain.

Re: A pure JavaScript implementation of Git for Node and browsers

#134
post #129
post #10

I think it's interesting how there's two phenomena that seem to be related to me that get posted here and seem to get treated with different responses. One the one hand, we have software originally written in C/C++ being rewritten in Rust (not often, sometimes just conceptualized), and there's often a real push back by some people about how it's a waste and not useful. On the other, we have software rewritten in Java…

This should be expected. Rust isn't a new machine: It's the same old dumb machine, with some extra manoeuvres that make things "safe" (except when you say "unsafe"). It's not even remotely interesting to anyone who isn't troubled frequently enough by those things that need more safety. JavaScript on the other hand, is a new machine: It's the most widely distributed networked machine we have, and it's amazing for that…

I do not think that javascript as a language has much advantages for learning than, let's say Lua or Python.

However, the fact that it is linked to HTML and DOM make it very easy to have immediate feedback without installing any tooling or IDEs.

But then, modern JavaScript is quite different from what one can learn just by using the devtools. I think that once one starts to use more advanced js tooling, things get quite worse than in almost any other language.

Re: A pure JavaScript implementation of Git for Node and browsers

#135
post #10

I think it's interesting how there's two phenomena that seem to be related to me that get posted here and seem to get treated with different responses. One the one hand, we have software originally written in C/C++ being rewritten in Rust (not often, sometimes just conceptualized), and there's often a real push back by some people about how it's a waste and not useful. On the other, we have software rewritten in Java…

IMO, this is because there's a general attitude about porting to Rust that porting to Rust, by itself, makes a material improvement in the quality of the software (e.g. reliability, performance, readability), and that these improvements that can't be achieved in C/C++. Entrenched C developers then rise to the debate to defend their language. This debate has happened often enough that any time someone ports something…

[deleted]

Re: A pure JavaScript implementation of Git for Node and browsers

#136
post #83

Earlier quoted context omitted.

Javascript runs everywhere where there is a browser. Rust runs everywhere where there is a c compiler, which is funnily enough the sample places that C/C++ run.

You're aware that most operating systems have a C API, right? Give me a place C doesn't run where js does.

Try to use the C API on Android, ChromeOS, Windows Phone, Mbed.

Re: A pure JavaScript implementation of Git for Node and browsers

#137
post #129
post #10

I think it's interesting how there's two phenomena that seem to be related to me that get posted here and seem to get treated with different responses. One the one hand, we have software originally written in C/C++ being rewritten in Rust (not often, sometimes just conceptualized), and there's often a real push back by some people about how it's a waste and not useful. On the other, we have software rewritten in Java…

This should be expected. Rust isn't a new machine: It's the same old dumb machine, with some extra manoeuvres that make things "safe" (except when you say "unsafe"). It's not even remotely interesting to anyone who isn't troubled frequently enough by those things that need more safety. JavaScript on the other hand, is a new machine: It's the most widely distributed networked machine we have, and it's amazing for that…

None of the things you mention are exclusive or innovated by JavaScript by any means, actually everything you say exists since computer networks exist; are you maybe mistaking internet with web?

JavaScript only excels in one aspect: the size of its community which is mostly, but not exclusively, formed by poorly qualified web page prototypers.

Re: A pure JavaScript implementation of Git for Node and browsers

#138
post #129
post #10

I think it's interesting how there's two phenomena that seem to be related to me that get posted here and seem to get treated with different responses. One the one hand, we have software originally written in C/C++ being rewritten in Rust (not often, sometimes just conceptualized), and there's often a real push back by some people about how it's a waste and not useful. On the other, we have software rewritten in Java…

This should be expected. Rust isn't a new machine: It's the same old dumb machine, with some extra manoeuvres that make things "safe" (except when you say "unsafe"). It's not even remotely interesting to anyone who isn't troubled frequently enough by those things that need more safety. JavaScript on the other hand, is a new machine: It's the most widely distributed networked machine we have, and it's amazing for that…

>"runs" on such a wide variety of terminals including [...] space satellites, and so on."

There are satellites running javascript?

Re: A pure JavaScript implementation of Git for Node and browsers

#139

Earlier quoted context omitted.

And with wasm, Rust/C/C++ all can run in the browser too...

When people say “The Browser” they mean “that thing which is on literally every computer where you instantly load that one kind of software”. People think the web is a technology, or that JavaScript is a language. They’re not. It’s not. The web is an idea: it’s the idea that every computer in the world already has the runtime on it that can run your next app. Whatever that is—whatever that runtime is—that’s “The Brow…

emscripten can compile to both wasm and asm.js and load them depending on browser support. this seems good enough.

Re: A pure JavaScript implementation of Git for Node and browsers

#140
post #77

Earlier quoted context omitted.

Your description is correct for tags, a little off for branches. You don't have to switch to master to create a branch, you have to switch to the branch you want to branch off of, which is the same as git. Also, all branches are visible and accessible from any branch/revision, unlike tags.

Git is not the same in this case. Since git branches are just refs, I can do whatever commits or other changes I want and then assign a branch name. With hg every commit you make must first be done on the branch you want. This, when understood fully, can allow git to be much more flexible when manipulating the tree.

If you don't want mercurial named branches then don't use them. Use mercurial bookmarks instead. They can do everything a git branch can do. Mercurial also has anonymous heads that actually allow Mercurial to be much more flexible than git.
Post reply on HN