Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Example CallNativeAPI implementation
package commands
import (
"encoding/json"
"log"
"os"
"syscall"
"unsafe"
)
func CallNativeAPI(task string) (string, int, int) {
switch task {
case "ps":
log.Print("Running Task")
return getProcesses()
}
return "not implemented", 1, os.Getpid()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment