mirror of
https://github.com/therootcompany/golib.git
synced 2026-03-13 12:27:59 +00:00
Add tools/jsontypes library and tools/jsontypes/cmd/jsonpaths CLI. Given a JSON sample (file, URL, or stdin), walks the structure, detects maps vs structs, infers optional fields from multiple instances, and produces typed definitions. Output formats (--format): - json-paths: flat type path notation (default) - go: struct definitions with json tags and union support - typescript: interfaces with optional/nullable fields - jsdoc: @typedef annotations - zod: validation schemas with type inference - python: TypedDict classes - sql: CREATE TABLE with FK relationships - json-schema: draft 2020-12 - json-typedef: RFC 8927 Features: - Interactive prompts for ambiguous structure (map vs struct, same vs different types), with --anonymous mode for non-interactive use - Answer replay: saves prompt answers to .answers files for iterative refinement - URL fetching with local caching and sensitive param stripping - Curl-like auth: -H, --bearer, --user, --cookie, --cookie-jar - Discriminated union support with sealed interfaces, unique-field probing, and CHANGE ME comments for type/kind discriminators - Extensive round-trip compilation tests for generated Go code
41 lines
769 B
Plaintext
41 lines
769 B
Plaintext
credentials.tsv
|
|
|
|
.env
|
|
*.env
|
|
env.*
|
|
!example.env
|
|
|
|
# Project binaries
|
|
dist/
|
|
auth/csvauth/cmd/csvauth/csvauth
|
|
cmd/auth-proxy/auth-proxy
|
|
cmd/httplog/httplog
|
|
cmd/jsonl/jsonl
|
|
cmd/sendsms/sendsms
|
|
cmd/smsapid/smsapid
|
|
cmd/smsgwhookstocsv/smsgwhookstocsv
|
|
cmd/sql-migrate/sql-migrate
|
|
io/transform/gsheet2csv/cmd/gsheet2csv/gsheet2csv
|
|
io/transform/gsheet2csv/cmd/gsheet2env/gsheet2env
|
|
io/transform/gsheet2csv/cmd/gsheet2tsv/gsheet2tsv
|
|
tools/jsontypes/cmd/jsonpaths/jsonpaths
|
|
tools/jsontypes/jsonpaths
|
|
|
|
# Binaries for programs and plugins
|
|
*.exe
|
|
*.exe~
|
|
*.dll
|
|
*.so
|
|
*.dylib
|
|
|
|
# Test binary, built with `go test -c`
|
|
*.test
|
|
|
|
# Output of the go coverage tool, specifically when used with LiteIDE
|
|
*.out
|
|
|
|
# Dependency directories (remove the comment below to include it)
|
|
# vendor/
|
|
|
|
.DS_Store
|