summaryrefslogtreecommitdiffstats
path: root/modules/package.py
diff options
context:
space:
mode:
authorYaakov M. Nemoy <loupgaroublond@gmail.com>2009-01-05 17:21:12 -0500
committerYaakov M. Nemoy <loupgaroublond@gmail.com>2009-01-05 17:21:12 -0500
commit79577f7d35ba8cff9ba7a1f97d8bae8bab1b001f (patch)
treeacd762c687a982d74a3a6f27b5e8d7523994c8be /modules/package.py
parent6e14fd63cf74c50898e68dee8398fa3222fb2ec5 (diff)
downloadfedora-devshell-79577f7d35ba8cff9ba7a1f97d8bae8bab1b001f.tar.gz
fedora-devshell-79577f7d35ba8cff9ba7a1f97d8bae8bab1b001f.tar.xz
fedora-devshell-79577f7d35ba8cff9ba7a1f97d8bae8bab1b001f.zip
refactoring for bugfixes
turns out that we can't have a property also be an important method in our current method of parsing. also, sourceball is really a package idiom, and belongs there finally, i misnamed something earlier
Diffstat (limited to 'modules/package.py')
-rw-r--r--modules/package.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/modules/package.py b/modules/package.py
index 47f9803..d123446 100644
--- a/modules/package.py
+++ b/modules/package.py
@@ -64,15 +64,15 @@ class Package(Directory):
return self.cfg['dir']
@property
- def pkg_dir(self):
- return self.cfg['pkg_dir']
+ def pkg_name(self):
+ return self.cfg['pkg_name']
def get_srpm_name(self, profile):
with pwd(self.code_dir):
ver, rel = ver_rel(self.spec_file, profile.dist_defines())
return '%s-%s-%s.src.rpm' % (self.pkg_name, ver, rel)
- def ver(self, profile):
+ def ver(self, profile=None):
with pwd(self.dir):
ver, rel = ver_rel(self.spec_file, profile.dist_defines() if profile else '')
return ver
@@ -80,4 +80,8 @@ class Package(Directory):
def source_dir(self, *args):
raise NotImplementedError
+ @property
+ def sourceball(self):
+ return self.cfg['sourceball']
+
__all__ = ['Package']