Documentation ¶
Index ¶
- type Backup
- type Base
- type Example
- type Executable
- type File
- type Intent
- type IntentTemplate
- type LocalRepository
- type MIMEType
- type MainRepository
- type Media
- type Module
- type Platform
- type Profile
- type Project
- type ProjectLessFunc
- type ProjectSorter
- type ProjectType
- type RemoteRepository
- type RepositoryBase
- type RepositoryGroup
- type Settings
- type SoftwarePackage
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Backup ¶ added in v0.0.15
type Backup struct { ID dxo.BackupID `json:"id"` Base BackupFileName string `json:"backup_file_name"` BackupFilePath string `json:"backup_file_path"` }
Backup 表示一个备份文件
type Base ¶
type Base struct { UUID dxo.UUID `json:"uuid"` CreatedAt util.Time `json:"created_at"` UpdatedAt util.Time `json:"updated_at"` }
Base 所有DTO 的基本结构
type Executable ¶
type Executable struct { ID dxo.ExecutableID `json:"id"` Base Name string `json:"name"` Title string `json:"title"` Description string `json:"description"` Path string `json:"path"` IconURL string `json:"icon"` SHA256SUM util.Hex `json:"sha256sum"` Remark string `json:"remark"` Size int64 `json:"size"` Ready bool `json:"ready"` Group dxo.ExecutableGroupName `json:"group"` State dxo.FileState `json:"state"` Tags dxo.StringList `json:"tags"` OpenWithPriority int `json:"open_with_priority"` // 如果 value<=0, 表示 disable }
Executable ...
type File ¶ added in v0.0.7
type File struct { Name string `json:"name"` Path string `json:"path"` Base Exists bool `json:"exists"` IsFile bool `json:"is_file"` IsDir bool `json:"is_dir"` Size int64 `json:"size"` Type string `json:"content_type"` }
File 表示一个文件或者文件夹的信息
type Intent ¶
type Intent struct { ID dxo.IntentID `json:"id"` Base Options []string `json:"options"` // used for filters // as exe Executable *Executable `json:"executable"` Repository *LocalRepository `json:"repository"` Project *Project `json:"project"` Location *File `json:"location"` // as web Method string `json:"method"` URL string `json:"url"` // as cli Command string `json:"command"` Arguments []string `json:"args"` Env map[string]string `json:"env"` WD string `json:"wd"` }
Intent 表示一个命令实例
type IntentTemplate ¶
type IntentTemplate struct { ID dxo.IntentTemplateID `json:"id"` Base }
IntentTemplate 表示一个命令模板
type LocalRepository ¶
type LocalRepository struct { ID dxo.LocalRepositoryID `json:"id"` RepositoryBase Path string `json:"path"` DotGitPath string `json:"dot_git_path"` RepositoryPath string `json:"repository_path"` WorkingPath string `json:"workspace_path"` Projects []*Project `json:"projects"` }
LocalRepository ...
type MIMEType ¶ added in v0.0.14
type MIMEType struct { ID dxo.MIMETypeID `json:"id"` Base TypeName string `json:"type"` FileNameSuffix string `json:"suffix"` }
MIMEType 表示一个 MIME 类型
type MainRepository ¶
type MainRepository struct { RepositoryBase ID dxo.MainRepositoryID `json:"id"` Path string `json:"path"` }
MainRepository ...
type Media ¶
type Media struct { ID dxo.MediaID `json:"id"` Base FileSize int64 `json:"size"` SHA256SUM util.Hex `json:"sha256sum"` Bucket string `json:"bucket"` ContentType string `json:"content_type"` Label string `json:"label"` LocalFilePath string `json:"local_file_path"` Name string `json:"name"` URL string `json:"url"` }
Media 表示一个命令模板
type Module ¶ added in v0.0.14
type Module struct { Name string `json:"name"` Version string `json:"version"` Revision int `json:"revision"` }
Module 表示一个命令模板
type Platform ¶
type Platform struct { ID dxo.PlatformID `json:"id"` Base OS string `json:"os"` Arch string `json:"arch"` }
Platform 表示平台信息
type Project ¶
type Project struct { ID dxo.ProjectID `json:"id"` Base Name string `json:"name"` Description string `json:"description"` ProjectType dxo.ProjectTypeID `json:"project_type"` ProjectTypeName string `json:"project_type_name"` ProjectDir string `json:"project_dir"` ConfigFileName string `json:"config_file_name"` PathInWorktree string `json:"path_in_worktree"` FullPath string `json:"full_path"` OwnerRepository dxo.LocalRepositoryID `json:"owner_repository"` Group dxo.ProjectGroupName `json:"group"` State dxo.FileState `json:"state"` IsDir bool `json:"is_dir"` IsFile bool `json:"is_file"` Tags dxo.StringList `json:"tags"` }
Project ...
type ProjectLessFunc ¶ added in v0.0.12
ProjectLessFunc ...
type ProjectSorter ¶ added in v0.0.12
type ProjectSorter struct {
// contains filtered or unexported fields
}
ProjectSorter ...
func (*ProjectSorter) Len ¶ added in v0.0.12
func (inst *ProjectSorter) Len() int
func (*ProjectSorter) Less ¶ added in v0.0.12
func (inst *ProjectSorter) Less(i1, i2 int) bool
func (*ProjectSorter) Sort ¶ added in v0.0.12
func (inst *ProjectSorter) Sort(items []*Project, fn ProjectLessFunc)
Sort ...
func (*ProjectSorter) Swap ¶ added in v0.0.12
func (inst *ProjectSorter) Swap(i1, i2 int)
type ProjectType ¶ added in v0.0.14
type ProjectType struct { ID dxo.ProjectTypeID `json:"id"` Base Name string `json:"name"` Type string `json:"type"` Label string `json:"label"` Description string `json:"description"` Priority int `json:"priority"` // 优先级,数值越高越先处理 AsFile bool `json:"as_file"` AsDir bool `json:"as_dir"` }
ProjectType 表示一个命令模板
type RemoteRepository ¶
type RemoteRepository struct { RepositoryBase ID dxo.RemoteRepositoryID `json:"id"` URL string `json:"url"` }
RemoteRepository ...
type RepositoryBase ¶
type RepositoryBase struct { Base Name string `json:"name"` DisplayName string `json:"label"` Description string `json:"description"` IconURL string `json:"icon"` Ready bool `json:"ready"` Group dxo.RepositoryGroupName `json:"group"` State dxo.FileState `json:"state"` Tags dxo.StringList `json:"tags"` }
RepositoryBase 仓库DTO
type RepositoryGroup ¶
type RepositoryGroup struct { ID dxo.RepositoryGroupID `json:"id"` Base Name string `json:"name"` }
RepositoryGroup 是 Repository 的分组
type Settings ¶ added in v0.0.14
type Settings struct { // example: Value1 string `json:"value1"` Value2 int `json:"value2"` Value3 bool `json:"value3"` IgnorePackageVersion string `json:"ignore.package.version"` IgnorePackageRevision int `json:"ignore.package.revision"` IgnorePackageSum util.Hex `json:"ignore.package.sha256sum"` }
Settings 表示一个命令模板
type SoftwarePackage ¶ added in v0.0.14
type SoftwarePackage struct { ID dxo.SoftwarePackageID `json:"id"` Base ModuleName string `json:"name"` // 包名称(=主模块.名称) FileName string `json:"full_name"` // 完整的文件名 AppName string `json:"simple_name"` // 简单文件名 Revision int `json:"revision"` // 包版次(=主模块.版次) Version string `json:"version"` // 包版本(=主模块.版本) OS string `json:"os"` // 操作系统 Arch string `json:"arch"` // 处理器架构 SHA256SUM util.Hex `json:"sha256sum"` // 包文件 sha-256 Size int64 `json:"size"` // 包文件大小 WebPageURL string `json:"web_page_url"` // 下载页面 URL DownloadURL string `json:"download_url"` // 下载地址 URL ReleaseAt util.Time `json:"release_at"` // 发布时间 }
SoftwarePackage 表示一个命令模板
Click to show internal directories.
Click to hide internal directories.