model

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 26, 2015 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	EventPush   = "push"
	EventPull   = "pull_request"
	EventTag    = "tag"
	EventDeploy = "deploy"
)
View Source
const (
	StatusSkipped = "skipped"
	StatusPending = "pending"
	StatusRunning = "running"
	StatusSuccess = "success"
	StatusFailure = "failure"
	StatusKilled  = "killed"
	StatusError   = "error"
)
View Source
const (
	Freebsd_386 uint = iota
	Freebsd_amd64
	Freebsd_arm
	Linux_386
	Linux_amd64
	Linux_arm
	Linux_arm64
	Solaris_amd64
	Windows_386
	Windows_amd64
)

Variables

View Source
var Archs = map[string]uint{
	"freebsd_386":   Freebsd_386,
	"freebsd_amd64": Freebsd_amd64,
	"freebsd_arm":   Freebsd_arm,
	"linux_386":     Linux_386,
	"linux_amd64":   Linux_amd64,
	"linux_arm":     Linux_arm,
	"linux_arm64":   Linux_arm64,
	"solaris_amd64": Solaris_amd64,
	"windows_386":   Windows_386,
	"windows_amd64": Windows_amd64,
}

Functions

This section is empty.

Types

type Build

type Build struct {
	ID        int64  `json:"id"            meddler:"build_id,pk"`
	RepoID    int64  `json:"-"             meddler:"build_repo_id"`
	Number    int    `json:"number"        meddler:"build_number"`
	Event     string `json:"event"         meddler:"build_event"`
	Status    string `json:"status"        meddler:"build_status"`
	Enqueued  int64  `json:"enqueued_at"   meddler:"build_enqueued"`
	Created   int64  `json:"created_at"    meddler:"build_created"`
	Started   int64  `json:"started_at"    meddler:"build_started"`
	Finished  int64  `json:"finished_at"   meddler:"build_finished"`
	Commit    string `json:"commit"        meddler:"build_commit"`
	Branch    string `json:"branch"        meddler:"build_branch"`
	Ref       string `json:"ref"           meddler:"build_ref"`
	Refspec   string `json:"refspec"       meddler:"build_refspec"`
	Remote    string `json:"remote"        meddler:"build_remote"`
	Title     string `json:"title"         meddler:"build_title"`
	Message   string `json:"message"       meddler:"build_message"`
	Timestamp int64  `json:"timestamp"     meddler:"build_timestamp"`
	Author    string `json:"author"        meddler:"build_author"`
	Avatar    string `json:"author_avatar" meddler:"build_avatar"`
	Email     string `json:"author_email"  meddler:"build_email"`
	Link      string `json:"link_url"      meddler:"build_link"`
}

type BuildGroup

type BuildGroup struct {
	Date   string
	Builds []*Build
}

type CCProject

type CCProject struct {
	XMLName         xml.Name `xml:"Project"`
	Name            string   `xml:"name,attr"`
	Activity        string   `xml:"activity,attr"`
	LastBuildStatus string   `xml:"lastBuildStatus,attr"`
	LastBuildLabel  string   `xml:"lastBuildLabel,attr"`
	LastBuildTime   string   `xml:"lastBuildTime,attr"`
	WebURL          string   `xml:"webUrl,attr"`
}

type CCProjects

type CCProjects struct {
	XMLName xml.Name   `xml:"Projects"`
	Project *CCProject `xml:"Project"`
}

func NewCC

func NewCC(r *Repo, b *Build, link string) *CCProjects

type Feed

type Feed struct {
	Owner    string `json:"owner"         meddler:"repo_owner"`
	Name     string `json:"name"          meddler:"repo_name"`
	FullName string `json:"full_name"     meddler:"repo_full_name"`

	Number   int    `json:"number"        meddler:"build_number"`
	Event    string `json:"event"         meddler:"build_event"`
	Status   string `json:"status"        meddler:"build_status"`
	Created  int64  `json:"created_at"    meddler:"build_created"`
	Started  int64  `json:"started_at"    meddler:"build_started"`
	Finished int64  `json:"finished_at"   meddler:"build_finished"`
	Commit   string `json:"commit"        meddler:"build_commit"`
	Branch   string `json:"branch"        meddler:"build_branch"`
	Ref      string `json:"ref"           meddler:"build_ref"`
	Refspec  string `json:"refspec"       meddler:"build_refspec"`
	Remote   string `json:"remote"        meddler:"build_remote"`
	Title    string `json:"title"         meddler:"build_title"`
	Message  string `json:"message"       meddler:"build_message"`
	Author   string `json:"author"        meddler:"build_author"`
	Avatar   string `json:"author_avatar" meddler:"build_avatar"`
	Email    string `json:"author_email"  meddler:"build_email"`
}

type Job

type Job struct {
	ID       int64  `json:"id"           meddler:"job_id,pk"`
	BuildID  int64  `json:"-"            meddler:"job_build_id"`
	NodeID   int64  `json:"-"            meddler:"job_node_id"`
	Number   int    `json:"number"       meddler:"job_number"`
	Status   string `json:"status"       meddler:"job_status"`
	ExitCode int    `json:"exit_code"    meddler:"job_exit_code"`
	Enqueued int64  `json:"enqueued_at"  meddler:"job_enqueued"`
	Started  int64  `json:"started_at"   meddler:"job_started"`
	Finished int64  `json:"finished_at"  meddler:"job_finished"`

	Environment map[string]string `json:"environment" meddler:"job_environment,json"`
}

type Key

type Key struct {
	ID      int64  `json:"-"       meddler:"key_id,pk"`
	RepoID  int64  `json:"-"       meddler:"key_repo_id"`
	Public  string `json:"public"  meddler:"key_public"`
	Private string `json:"private" meddler:"key_private"`
}

type Log

type Log struct {
	ID    int64  `meddler:"log_id,pk"`
	JobID int64  `meddler:"log_job_id"`
	Data  []byte `meddler:"log_data"`
}

type Netrc

type Netrc struct {
	Machine  string `json:"machine"`
	Login    string `json:"login"`
	Password string `json:"user"`
}

type Node

type Node struct {
	ID   int64  `meddler:"node_id,pk" json:"id"`
	Addr string `meddler:"node_addr"  json:"address"`
	Arch string `meddler:"node_arch"  json:"architecture"`
	Cert string `meddler:"node_cert"  json:"-"`
	Key  string `meddler:"node_key"   json:"-"`
	CA   string `meddler:"node_ca"    json:"-"`
}

type Perm

type Perm struct {
	Pull  bool `json:"pull"`
	Push  bool `json:"push"`
	Admin bool `json:"admin"`
}

type Repo

type Repo struct {
	ID          int64  `json:"id"                meddler:"repo_id,pk"`
	UserID      int64  `json:"-"                 meddler:"repo_user_id"`
	Owner       string `json:"owner"             meddler:"repo_owner"`
	Name        string `json:"name"              meddler:"repo_name"`
	FullName    string `json:"full_name"         meddler:"repo_full_name"`
	Avatar      string `json:"avatar_url"        meddler:"repo_avatar"`
	Link        string `json:"link_url"          meddler:"repo_link"`
	Clone       string `json:"clone_url"         meddler:"repo_clone"`
	Branch      string `json:"default_branch"    meddler:"repo_branch"`
	Timeout     int64  `json:"timeout"           meddler:"repo_timeout"`
	IsPrivate   bool   `json:"private"           meddler:"repo_private"`
	IsTrusted   bool   `json:"trusted"           meddler:"repo_trusted"`
	IsStarred   bool   `json:"starred,omitempty" meddler:"-"`
	AllowPull   bool   `json:"allow_pr"          meddler:"repo_allow_pr"`
	AllowPush   bool   `json:"allow_push"        meddler:"repo_allow_push"`
	AllowDeploy bool   `json:"allow_deploys"     meddler:"repo_allow_deploys"`
	AllowTag    bool   `json:"allow_tags"        meddler:"repo_allow_tags"`
	Hash        string `json:"-"                 meddler:"repo_hash"`
}

type RepoLite

type RepoLite struct {
	Owner    string `json:"owner"`
	Name     string `json:"name"`
	FullName string `json:"full_name"`
	Avatar   string `json:"avatar_url"`
}

type System

type System struct {
	Version string   `json:"version"`
	Link    string   `json:"link_url"`
	Plugins []string `json:"plugins"`
	Globals []string `json:"globals"`
}

type User

type User struct {
	ID     int64  `json:"id"         meddler:"user_id,pk"`
	Login  string `json:"login"      meddler:"user_login"`
	Token  string `json:"-"          meddler:"user_token"`
	Secret string `json:"-"          meddler:"user_secret"`
	Expiry int64  `json:"-"          meddler:"user_expiry"`
	Email  string `json:"email"      meddler:"user_email"`
	Avatar string `json:"avatar_url" meddler:"user_avatar"`
	Active bool   `json:"active,"    meddler:"user_active"`
	Admin  bool   `json:"admin,"     meddler:"user_admin"`
	Hash   string `json:"-"          meddler:"user_hash"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL