コード例 #1
0
ファイル: repo.py プロジェクト: feuri/local-repo
    def __str__(self):
        """ Return a nice string with some repo infos """
        infos = {"location": self._path, "packages": self.size}

        if isfile(self._db):
            infos["last update"] = round(stat(self._db).st_mtime)

        return Humanizer.info(infos)
コード例 #2
0
ファイル: repo.py プロジェクト: managarm/local-repo
    def __str__(self):
        """ Returns a nice string with some repo info """
        info = {"location": self._path, "packages": len(self), "pgpsig": isfile(self._db + Repo.SIGEXT)}

        try:
            info["last update"] = round(getctime(self._db))
        except:
            info["last update"] = "-"

        return Humanizer.info(info)
コード例 #3
0
ファイル: repo.py プロジェクト: yunchih/local-repo
    def __str__(self):
        ''' Returns a nice string with some repo info '''
        info = {
            'location': self._path,
            'packages': len(self),
            'pgpsig': isfile(self._db + Repo.SIGEXT)
        }

        try:
            info['last update'] = round(getctime(self._db))
        except:
            info['last update'] = '-'

        return Humanizer.info(info)
コード例 #4
0
 def __str__(self):
     return Humanizer.info(self.info)
コード例 #5
0
ファイル: package.py プロジェクト: feuri/local-repo
	def __str__(self):
		return Humanizer.info(self.infos)