hodagi / learning-thema

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

learning-thema

Thema のチュートリアルに従って作ってみた。

前提

cue, golangがインストールされていること

環境

soharaki@DESKTOP:~/work/learning-thema$ cue version
cue version v0.4.3 linux/amd64
soharaki@DESKTOP:~/work/learning-thema$ go version
go version go1.18.3 linux/amd64

動かし方

  • 準備
# cueの初期化
MODPATH="github.com/example/thema_example"
cue mod init $MODPATH
# 念のため
go mod tidy
  • 実行
go test
  • リザルト
soharaki@DESKTOP:~/work/tutorial-thema$ go test
#######################################
version0.0:{Firstfield:foo}
version1.0:{Firstfield:foo Secondfield:-1}
Lacuna(欠落したフィールド情報)
{[] [{secondfield <nil>}] 0 -1 used as a placeholder value - replace with a real value before persisting!}
#######################################
PASS
ok      github.com/example/thema_example        0.191s

About


Languages

Language:Go 72.5%Language:CUE 27.5%