文件操作 - dstat_helloworld.py
返回文件管理
返回主菜单
删除本文件
文件: /usr/share/dstat/dstat_helloworld.py
编辑文件内容
### Author: Dag Wieers <dag$wieers,com> class dstat_plugin(dstat): """ Example "Hello world!" output plugin for aspiring Dstat developers. """ def __init__(self): self.name = 'plugin title' self.nick = ('counter',) self.vars = ('text',) self.type = 's' self.width = 12 self.scale = 0 def extract(self): self.val['text'] = 'Hello world!' # vim:ts=4:sw=4:et
修改文件时间
将文件时间修改为当前时间的前一年
删除文件