Documentation
¶
Index ¶
Constants ¶
View Source
const ConfigFileName = "codex.toml"
Variables ¶
This section is empty.
Functions ¶
func UploadCodex ¶
func UploadCodex( client *api.Client, opts *UploadCodexOptions, ) (*api.UploadCodexResponse, *api.CodexParseFailedError, error)
Types ¶
type Config ¶
type Config struct {
Upload UploadConfig `toml:"upload"`
Kernel KernelConfig `toml:"kernel"`
// contains filtered or unexported fields
}
func GetOrInitCodexConfig ¶
func InitConfig ¶ added in v0.0.12
Initialize a new codex config file
func (*Config) UnmarshalFromFile ¶
type Details ¶ added in v0.0.10
type Details struct {
Name string
KernelSpec KernelSpec `json:"kernelSpec"`
}
type KernelConfig ¶ added in v0.0.12
type KernelConfig struct {
// The Docker image to use when running the kernel.
// This overrides all other kernel config options.
Image string `toml:"image,omitempty"`
// An array of additional (usually Debian) packages to install
// (e.g., {"texlive-latex-base"} if the `latex` command is required).
SystemPackages []string `toml:"system_packages"`
}
type KernelSpec ¶ added in v0.0.10
type KernelSpec struct {
ID string `json:"id"`
BuildStatus string `json:"buildStatus"`
Events []string `json:"events"`
BuildLog []string `json:"buildLog"`
}
func WaitForKernelBuildCompleted ¶ added in v0.0.10
func WaitForKernelBuildCompleted( ctx context.Context, client *graphql.Client, codexId string, ) (*KernelSpec, error)
WaitForKernelBuildCompleted polls the API server until the kernel build is completed.
type UploadCodexOptions ¶
type UploadCodexOptions struct {
// The codex directory
Dir string
}
type UploadConfig ¶
type UploadConfig struct {
// The ID of the codex category where the codex will be uploaded.
CodexCategory string `toml:"codex_category"`
// The name of the codex (as displayed in the Pathbird UI).
Name string `toml:"name"`
// The ID of the codex (if being re-uploaded).
CodexId string `toml:"codex_id,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.