project

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2018 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrProjectNotFound = errors.New("project not found")

Functions

This section is empty.

Types

type Project

type Project struct {
	HostingPlatform  string // Name and directory name of the hosting platform like "github.com"
	OrganisationName string // Name and directory name of the organisation owning this project
	RepositoryName   string // Name and directory name of this project

	Path string // Full path of this project

	Manifest *manifest.Manifest // Manifest of this project
	// contains filtered or unexported fields
}

Project represents a project whether it exists locally or not

func FindBestMatch

func FindBestMatch(expr string, conf *config.Config) (found *Project, err error)

func FindCurrent

func FindCurrent() (*Project, error)

func GetAllProjects

func GetAllProjects(sourceDir string) ([]*Project, error)

func NewFromID

func NewFromID(id string, conf *config.Config) (p *Project, err error)

NewFromID creates an instance of Project from a short id like "org/name"

func (*Project) Clone

func (p *Project) Clone() (err error)

Clone runs the Git command needed to clone the project

func (*Project) Create added in v0.0.9

func (p *Project) Create() (err error)

Create creates the project directory locally

func (*Project) Exists

func (p *Project) Exists() bool

Exists checks whether the project exists locally

func (*Project) FullName

func (p *Project) FullName() string

FullName returns a logical id like platform:org/project

func (*Project) GetRemoteURL

func (p *Project) GetRemoteURL() (url string, err error)

GetRemoteURL builds the Git remote url for the project

func (*Project) Slug added in v0.0.4

func (p *Project) Slug() string

Slug returns a short, unique but humanly recognizable id based on the path

Jump to

Keyboard shortcuts

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