X-Git-Url: http://git.onelab.eu/?p=sface.git;a=blobdiff_plain;f=sface%2Fconfig.py;h=b8b18726d0ff48cd73941d365b915a5910833bbd;hp=edb2924edd2847b53d7824ebfaca31a3f9f91dc7;hb=ebc6f2825a983bf1cef33831349643577a32336c;hpb=ab5bd9742a2d1b306e1a65b7f37c46f602c3fdd3 diff --git a/sface/config.py b/sface/config.py index edb2924..b8b1872 100644 --- a/sface/config.py +++ b/sface/config.py @@ -179,26 +179,19 @@ class Config: if value is not None: setattr(self,field,getattr(optparse_options,field)) -# def setUser(self, user): -# Config.SFI_USER = user -# -# # Should probably get authority from user record instead... -# a = user.split('.') -# Config.SFI_AUTH = '.'.join(a[:len(a)-1]) - def fullpath (self, filename): return os.path.join(self.get_dirname(),filename) def getSliceRSpecFile(self): return self.fullpath("%s.rspec" % self.getSlice()) + def getResourcesRSpecFile(self): return self.fullpath("resources.rspec") + def getSliceRecordFile(self): return self.fullpath ("%s.record" % self.getSlice()) + def getUserRecordFile(self): return self.fullpath ("%s.record" % self.getUser()) + def getAuthorityRecordFile(self): return self.fullpath ("%s/%s.record" % self.getAuthority()) - def getAuthorityListFile(self, i=None): - if (i != None) and (i != 0): - return self.fullpath ("%s_list.record.%d" % (self.getAuthority(),i)) - else: - return self.fullpath ("%s_list.record" % self.getAuthority()) + def getAuthorityListFile(self): return self.fullpath ("%s_list.xml" % self.getAuthority()) # configuration singleton