Friday, November 27, 2026
HomeGolangNople: an editor in pure Go, no cgo, that opens a ten...

Nople: an editor in pure Go, no cgo, that opens a ten GB log in 0.35 s – Releases


Nople is an editor for studying and checking code. It’s written in Go with out cgo, right down to the GPU rendering: GitHub – bankai-tensei/nople: A easy editor for the age of AI. ยท GitHub

Time from launch till the contents of a log present, identical machine, identical file:

Nople Zed 1.27.0 VS Code 1.133.0
1 GB log 0.31 s 2.1 s 8.0 s
10 GB log 0.35 s doesn’t open 117 s
Peak reminiscence, 10 GB 392 MB n/a 5.8 GB

The ten GB log is able to scroll, search and edit the second it exhibits.

How it’s constructed, in brief:

  • It by no means reads the entire file. It retains one offset each 64 traces and reads a block from disk when a line comes into view.
  • Edits stay in a chunk desk, so typing into a ten GB file prices one line of reminiscence.
  • Indexing, search and saving every run on a goroutine of their very own and publish their outcomes to the UI goroutine. The window by no means stops.
  • The UI is gowaku, a desktop UI library I wrote, additionally in pure Go: it calls Direct3D 11, Vulkan and Metallic with out cgo, so go construct is the entire construct and cross-compiling works. I’ll publish about it individually.

What you get as a person: a file tree, tabs, highlighted code, rendered Markdown, side-by-side Git diffs and a terminal, with no extensions and no settings to tune. Installers for Home windows, Linux and macOS are on the releases web page.

The comparability covers opening giant logs solely, with recent profiles and no extensions; the script and uncooked outcomes are in instruments/examine.



2 Likes

Nice work on the streamin/desk method. You suppose you might port this function to VS Code? Perhaps as a plugin for giant recordsdata ?

A full port isnโ€™t actually attainable via the conventional extension API: VS Code owns the core textual content buffer, file loading, and rendering. The closest method could be a customized editor/webview that streams blocks from disk and retains a chunk desk exterior the native doc, however search, enhancing, and Git integration could be extra restricted or require additional glue. So it might work as a targeted large-log viewer, not as a drop-in alternative for VS Codeโ€™s regular editor.

Thanks! That reply is true. A VS Code extension can’t exchange the editorโ€™s textual content buffer, so the identical method would solely work as a separate viewer. I’ve no plan to make one, however the editor widget in gowaku is reusable if somebody needs to attempt.

That is good. Aspect observe: when you’ve got 10gb log recordsdata, for the love of every part, cycle your log recordsdata. :wink:



3 Likes

Nevertheless it could be a very good platform for a One Billion Rows Problem plugin. :rofl:



1 Like

That is actually cool! Two questions, because the README doesnโ€™t say:

  • Can or not it’s put in utilizing go set up?
  • Can or not it’s accurately cross-compiled to Home windows utilizing GOOS=home windows?

Thanks!

Sure to each.

go set up github.com/bankai-tensei/nople@newest

works. I simply tried it and obtained v1.0.1.

Cross-compiling works too, as a result of there isn’t a cgo. On Home windows add -H windowsgui, in any other case a console window opens subsequent to the editor:

GOOS=home windows GOARCH=amd64 go set up -ldflags=โ€œ-H windowsguiโ€ github.com/bankai-tensei/nople@newest

I constructed home windows/amd64, home windows/arm64, linux/amd64 and darwin/arm64 from one machine with CGO_ENABLED=0. The exe icon is barely included for amd64.

You might be proper that the README doesn’t say this. I’ll add it.



1 Like

Emacs can do it for a very long time already with VLF, with all of the bells&whistles.

For instance ~60GiB giant file, opened with syntax highlighting, completion, occur-mode filtering, xref navigation and many others:

(benchmark-elapse (vlf "/house/torimus/Downloads/Video games/very_large_selfcontained_installer.sh"))

0.015369362s

Thanks! I didnโ€™t know VLF was that quick โ€” 0.015 s for 60 GiB is spectacular.

So far as I perceive, VLF hundreds one chunk at a time and allows you to navigate between them. Nople takes a special method: it shows the preliminary traces immediately and indexes line positions within the background, so line numbers and the scrollbar cowl your entire file. Be happy to right me if I misunderstood how VLF works.

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments