struct DPPM::Prefix

Defined in:

prefix.cr

Constructors

Class Method Summary

Instance Method Summary

Constructor Detail

def self.new(path : String, group : String = @@default_group, source_name : String = @@default_source_name, source_path : String? = nil) #

[View source]

Class Method Detail

def self.default #

Default prefix for a DPPM installation.


[View source]
def self.default_dppm_config #

Default DPPM configuration.


[View source]
def self.default_group : String #

Default group namespace where installing applications.


[View source]
def self.default_source_name : String #

Default source name to get packages.


[View source]

Instance Method Detail

def app : Path #

Application path, including the #group namespace.


[View source]
def check #

Raises if DPPM isn't installated.


[View source]
def clean_unused_packages(confirmation : Bool = true, &block) : Set(String) #

[View source]
def create #

Create @path and all its subdirectories needed.


[View source]
def delete #

Delete the prefix directory path.


[View source]
def delete_src #

Delete the packages source @src directory.


[View source]
def dppm : App #

Returns the DPPM application.


[View source]
def dppm_config #

DPPM configuration.


[View source]
def dppm_config=(dppm_config : Config) #

[View source]
def each_app(&block : App -> ) #

Yields each application in the group.


[View source]
def each_pkg(&block : Pkg -> ) #

Yields each built package of the source.


[View source]
def each_src(&block : Src -> ) #

Yields each source package of the source.


[View source]
def ensure_app_dir #

Ensure the presence of the #app directory.


[View source]
def ensure_pkg_dir #

Ensure the presence of the #pkg directory.


[View source]
def group : String #

Application group namespace used.


[View source]
def new_app(name : String) : App #

Creates a new App application object.


[View source]
def new_pkg(package : String, version : String? = nil, tag : String? = nil) : Pkg #

Creates a new Pkg package object. A package name includes the package and optionally a version/tag separated by either a _ or :. If no version is provided, latest one will be used.


[View source]
def new_src(name : String) : Src #

Creates a new Src source package object.


[View source]
def path : Path #

Path of the prefix on the filesystem.


[View source]
def pkg : Path #

Package path, including the #source_name.


[View source]
def root_app : Path #

Base path for applications.


[View source]
def root_pkg : Path #

Base path for packages.


[View source]
def root_src : Path #

Base path for packages sources.


[View source]
def source_name : String #

Source name to use when building packages and creating applications.


[View source]
def source_path #

Source path used, which can be an URL or a filesystem path.


[View source]
def src : Path #

Package path, including the #source_name.


[View source]
def update(force : Bool = false) #

Download, or update a packages source cache.


[View source]