Package conary :: Package build :: Module build :: Class Link
[hide private]
[frames] | no frames]

Class Link

source code

  action.Action --+            
                  |            
action.RecipeAction --+        
                      |        
            BuildAction --+    
                          |    
                _FileAction --+
                              |
                             Link

NAME

r.Link() - Creates a hard link

SYNOPSIS

r.Link(newname(s), existingname)

DESCRIPTION

The r.Link() class is called from within a Conary recipe to install a hard link.

Note: The use of hard links is strongly discouraged in most cases. Hardlinks are limited to the same directory and symbolic links should always be chosen in preference to them. You should not use hard links unless the situation deems using them absolutely necessary.

KEYWORDS

The r.Link() class accepts the following keywords, with default values shown in parentheses when applicable:

package : (None) If set, must be a string that specifies the package (package='packagename'), component (package=':componentname'), or package and component (package='packagename:componentname') in which to place the files added while executing this command. Previously-specified PackageSpec or ComponentSpec lines will override the package specification, since all package and component specifications are considered in strict order as provided by the recipe.

EXAMPLES

r.Link('mumble', '%(bindir)s/passwd')

Demonstrates calling r.Link() to create a hard link from the file %(bindir)s/passwd to the file %(bindir)s/mumble.

Instance Methods [hide private]
 
do(self, macros)
Do the build action
source code
 
__init__(self, recipe, *args, **keywords)
Create a new Link instance:
source code

Inherited from _FileAction: chmod, setComponents

Inherited from BuildAction: doAction, initManifest, missingFiles

Inherited from action.RecipeAction: doPrep, doSuggestAutoBuildReqs, init_error

Inherited from action.Action: addArgs

Inherited from action.Action (private): _applyDefaults

Class Variables [hide private]

Inherited from _FileAction: keywords, useExplicitManifest

Method Details [hide private]

do(self, macros)

source code 
Do the build action
Overrides: BuildAction.do
(inherited documentation)

__init__(self, recipe, *args, **keywords)
(Constructor)

source code 
Create a new Link instance:
   self.Link(newname, [newname, ...,] existingpath)
Overrides: _FileAction.__init__