Skip to content

codefromthecrypt/apex-go

This branch is 12 commits behind apexlang/apex-go:main.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Oct 4, 2022
7d1bfdc · Oct 4, 2022

History

10 Commits
Oct 4, 2022
Sep 30, 2022
Oct 4, 2022
Sep 30, 2022
Sep 30, 2022
Sep 30, 2022
Sep 30, 2022
Oct 4, 2022
Sep 30, 2022
Sep 30, 2022
Sep 30, 2022
Sep 30, 2022
Sep 30, 2022
Oct 4, 2022
Feb 21, 2022
Oct 4, 2022
Oct 4, 2022
Oct 4, 2022
Sep 30, 2022
Oct 4, 2022

Repository files navigation

Apex Language support for Golang

TODO

package main

import (
	"encoding/json"
	"fmt"
	"os"

	"github.com/apexlang/apex-go/parser"
)

func main() {
	schema, err := os.ReadFile("schema.apex")
	if err != nil {
		panic(err)
	}
	doc, err := parser.Parse(parser.ParseParams{
		Source: string(schema),
		Options: parser.ParseOptions{
			NoLocation: true,
			NoSource:   true,
		},
	})
	if err != nil {
		panic(err)
	}

	jsonBytes, err := json.MarshalIndent(doc, "", "  ")
	if err != nil {
		panic(err)
	}
	fmt.Println(string(jsonBytes))
}

About

Golang support for the Apex language

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 99.6%
  • Makefile 0.4%