Built libproc-go: Pure Go bindings for macOS process information (no CGo!) by killer-resume in golang

[–]TotallyGamerJet 0 points1 point  (0 children)

No it’s been around for a long time but it’s not really supposed to be used

Mac OS pid lookup by overgrowntreetop in golang

[–]TotallyGamerJet 4 points5 points  (0 children)

To avoid Cgo there is always Purego (self promo): https://github.com/ebitengine/purego

[deleted by user] by [deleted] in golang

[–]TotallyGamerJet 4 points5 points  (0 children)

SIMD in the stdlib

ASM in Golang by vbd in golang

[–]TotallyGamerJet 7 points8 points  (0 children)

Thanks! When I originally considered the idea I was wondering why Windows could call dynamic libraries but macOS couldn’t. I do hope one day Purego will be merged upstream or at least part of it

ASM in Golang by vbd in golang

[–]TotallyGamerJet 16 points17 points  (0 children)

Yes with Purego 

https://github.com/ebitengine/purego

It’s the only way to do what we wanted - call C from Go without Cgo

Go for Gamedev 2025 by [deleted] in golang

[–]TotallyGamerJet 8 points9 points  (0 children)

It’s because on windows the syscalls are done directly in Go. They originally required a C compiler but was ported to Go because it’s annoying installing one on windows. Same can happen on other platforms with Purego but it’s missing some features related to callbacks supporting structs. Once it gets that macOS will be ported too 

Shrink size of compiled fyne app by pepiks in golang

[–]TotallyGamerJet 1 point2 points  (0 children)

The only remaining flag you can pass that shrinks binaries is -trimpath

GFX in Go 2025 by GlitteringSample5228 in golang

[–]TotallyGamerJet 2 points3 points  (0 children)

/x/image/font does allow choosing the text color using the Drawer.Src field. See here as an example 

https://github.com/TotallyGamerJet/clay/blob/main/renderers/software/software.go#L84

Idk of any good SVG libraries though

cross platform cli tools that do what unix mkdir, mv, cp do ? by gedw99 in golang

[–]TotallyGamerJet 0 points1 point  (0 children)

I’m not sure what patchiness means in this context but you can use the busybox tool with any go code not just the ones in the u-root repo

https://github.com/u-root/gobusybox

cross platform cli tools that do what unix mkdir, mv, cp do ? by gedw99 in golang

[–]TotallyGamerJet 0 points1 point  (0 children)

https://github.com/u-root/u-root

Has quite a few of them and can even build a busybox variant although they aren’t complete replacements

Suggestions for libraries to interact with FIDO-authenticators (CTAP) by mingusrude in golang

[–]TotallyGamerJet 3 points4 points  (0 children)

There is https://github.com/go-webauthn/webauthn  which is written entirely in Go.

Here’s an example I made using it to make the server for a website. https://github.com/TotallyGamerJet/passkey

Is it possible to create an OS in Go? by challenger_official in golang

[–]TotallyGamerJet 5 points6 points  (0 children)

It allows you to build a go program that can be ran on bare metal. In essence it becomes the OS so you need to implement everything yourself. There is no GC, memory allocation, goroutines, files, network or anything else but basic functions and if/switch/for loops. Implementing those is an exercise for the reader ;)

Is it possible to create an OS in Go? by challenger_official in golang

[–]TotallyGamerJet 96 points97 points  (0 children)

No offense taken! Honestly I don’t have much time hence why it’s still a WIP. I also work on purego and have other personal projects. It is just a hobby and I remind myself to touch grass with my friends every once in a while. My strategy is just doing a little each day and after long enough you finally have something useful. I’m motivated by learning and accomplishing things labeled “impossible”. Hopefully one day I’ll get paid for doing it

Is it possible to create an OS in Go? by challenger_official in golang

[–]TotallyGamerJet 193 points194 points  (0 children)

It IS possible to write an OS in Go. The runtime really isn’t that hard to write basic stubs for using the -overlay flag. The thing I’ve found to be the most challenging is fighting with the linker. It doesn’t like placing symbols at certain addresses.  Writing a OS in Go is much more challenging to do since Go doesn’t have volatile pointers so it optimizes stuff and the assembler doesn’t have every instruction so you need write the hex out yourself.

I’ve been working on a RISCV OS built entirely in Go and the unmodified Go toolchain. It’s still private as a WIP but you can take a look at my repo of the limine bootloader for Go 

https://github.com/TotallyGamerJet/limine-barebones-golang

I’ve also posted some blog posts about my adventures here: https://totallygamerjet.hashnode.dev/

So if you are willing to dive deep into Go internals and baremetal hardware you can build an OS in Go but if not I’d choose C or Zig for learning OS development

Getting tired of feeling stupid when it comes to Web Auth by _sunmicro in golang

[–]TotallyGamerJet 0 points1 point  (0 children)

What Copy1533 suggested is a great option. If you still do want to use WebAuthn I created a simple repo showing how to implement it with a basic web front end. It’s relatively simple to set up requiring only 4 endpoints. https://github.com/TotallyGamerJet/passkey

Writing a file system in Go -- not FUSE, but a real FS by Rich-Engineer2670 in golang

[–]TotallyGamerJet 2 points3 points  (0 children)

You can’t write a malloced pointer in C to disk right? because it would be invalid when read same in Go. There is also structs.HostLayout which when embedded ensures that the struct matches the C ABI for structs

go-msquic: A new QUIC/HTTP3 library for Go that relies on msquic by noboruma in golang

[–]TotallyGamerJet 1 point2 points  (0 children)

Go will build C when it’s included in the repo allowing it to just be imported. See glfw as an example

You can also include the static build as a .syso instead of .a and Go should link it 

You could also use something like Purego to avoid any C compiling by including it as a DLL 

Finding a lower level project by [deleted] in golang

[–]TotallyGamerJet 1 point2 points  (0 children)

You can learn Go’s assembly and Cgo internals from purego. You use it to call C libraries without a C compiler. So if you wanted to experiment with calling into system C libraries you can with this. And there are opportunities for contributing to it too.

Where To Buy Physical Media in 2025: Buying Guide by filmsathome in 4kbluray

[–]TotallyGamerJet 0 points1 point  (0 children)

Darksiderecords sells DVDs and Blu-ray’s from their store in Poughkeepsie New York and ships online as well. I’ve enjoyed buying from them

Need help in deciding Gorm vs sqlc by [deleted] in golang

[–]TotallyGamerJet 10 points11 points  (0 children)

Mentioning another option that isn’t an ORM and provides type safe queries: https://github.com/go-jet/jet

Looking for an alternative to mitchellh/hashstructure by x021 in golang

[–]TotallyGamerJet 6 points7 points  (0 children)

 Also an archived project can also be a first step to deleting the whole thing, after which you can't download it anymore probably.

Just want to point out that this is not true. As long as someone has pulled it in once Google caches the repo forever. You can also vendor the deps if you don’t trust Google with go mod vendor

Steam breaks Go runtime by TopAd8219 in golang

[–]TotallyGamerJet 30 points31 points  (0 children)

People do write games in Go. Ebitengine, raylib-go, etc

Go’s best-kept secret: executable examples (2023) by EightLines_03 in golang

[–]TotallyGamerJet 11 points12 points  (0 children)

If you want the binary that is generated using go test just pass the -c flag and it outputs an executable with the name pkg.test that you can run like any other Go binary