Live data from Hacker News

Sourcegraph is now open source

about.sourcegraph.com

11–20 of 95 posts

Re: Sourcegraph is now open source

#11
The kind of cross-reference SourceGraph provides is a must have for me after a few years of using a tool like it to understand big projects (I don't use SourceGraph, I use Grok/CodeSearch).

Google open sourced a version of Grok some time ago (https://kythe.io/). [1] A quick search also found this `OpenGrok` thing which I assume must be yet another generic indexer [2].

I wonder if there are other popular tools out there providing generic cross-referencing of code bases?

I was trying to find the equivalent of this Kythe page (how to write an indexer)[6] on SourceGraph docs, after 20 minutes I was still confused. I wish there was more clarity on the different pieces of the system. At first I thought SourceGraph could create a cross reference index from an LSP server, but I guess makes more sense it is the order way around? (SG can talk to text editors via LSP).

It must be a lot of work to make integrate any single language with both SG or Kythe and LSP, perhaps there's some tools or methodologies to make this easier?

I feel like language designers don't always think about building their implementations with ease of integration as a goal. I remember wanting to play with doing some AST transformations with both TypeScript and Dart (independently) and finding both languages made the task so hard and tedious. Mandatory remark: this is so easy with Lisp derivatives :-)

Things that a good language+ecosystem should have, IMO:

* Easy to retrieve and manipulate CST (for things like writing refactoring and querying tools, writing code formatters/pretty printers, etc). Many languages provide the syntax tree say, without comments, so it is hard to write a pretty printer.

* Documentation generator with cross-reference navigation.

* Play along nicely with generic build tools like Ninja [3].

* Good debugger and value-pretty-printer support (so I can just drop a breakpoint and print anything easily). And some sort of API to use the debugger programmatically or connect to a remote process.

* An LSP implementation [4], although it seems pretty much every popular language is getting one these days!

1: https://en.wikipedia.org/wiki/Google_Kythe

2: http://oracle.github.io/opengrok/

3: https://ninja-build.org/

4: https://langserver.org/

5: https://about.sourcegraph.com/docs/code-intelligence/

6: https://kythe.io/docs/schema/writing-an-indexer.html

Re: Sourcegraph is now open source

#12
post #3

Sourcegraph CEO here. We're back to work on testing release candidates for Sourcegraph 2.12, coming out this week. I'm especially excited about a few big new features that fit really nicely into the code search and browsing workflows people use Sourcegraph for: - https://github.com/sourcegraph/about/blob/master/projects/ex... - https://github.com/sourcegraph/about/blob/master/projects/so... - https://about.sourcegrap…

Is it easy to add new languages? I work at a large company with some very old codebases.

Re: Sourcegraph is now open source

#15

I was lucky to connect with Quinn and get the opportunity to volunteer as a guinea pig for open sourcing this code :). Sourcegraph is an interesting product and company. I see the potential for it to have a bigger positive impact on developer productivity than even Jetbrains IntelliJ has, because the reach can go beyond any particular editor or frontend. It could be a ubiquitous solution to efficient code search and…

Thanks for running through the README and helping us prep the open-source release last week!

Re: Sourcegraph is now open source

#17
> Together, these companies succeeded in bringing computing to billions of people. But these billions of people are still using software applications built by just 0.2% of the world's population (those who can code).

> The next step is to make it so billions of people, not just 0.2% of the world population, can build software (not just use it).

I must admit, this sounds indubitably noble.

But if you think that your software-engineering career is safe from (partial) automation, then these Sourcegraph folks have an iridium-plated bridge to sell you.

In not-so-tongue-and-cheek terms: if Sourcegraph succeeds, then tomorrow's software engineers will be - at most - as valuable as today's factory-robot operators.

* * *

(Of course, anyone worth their salt in this industry ought to be able to find the LSP's inherent limitations, and structure their codebases accordingly.)

EDIT: counterarguments are more persuasive than downvotes.

Re: Sourcegraph is now open source

#19

Is this the thing that caused furore a while ago because it was installed on some editors and it sent all your code to a third party server, or am I thinking of something completely different?

No that was Kite, they paid editor plugin developers to take over the plugin and then added their code complete which requires sending all source code to their servers.

https://qz.com/1043614/this-startup-learned-the-hard-way-tha...

https://kite.com

Post reply on HN