def copy_files(self, file_name, action):
if action == 'make_backup':
command = ['cp', '-R', self.winetricks_cache + '/' + file_name, self.winetricks_cache_backup]
elif action == 'restore_backup':
command = ['cp', '-R', self.winetricks_cache_backup + '/' + file_name, self.winetricks_cache]
self.pid, stdin, stdout, stderr = GLib.spawn_async(command,
flags=GLib.SpawnFlags.SEARCH_PATH|GLib.SpawnFlags.DO_NOT_REAP_CHILD,
standard_output=True,
standard_error=True)
io = GLib.IOChannel(stdout)
self.source_id_out = io.add_watch(GLib.IO_IN|GLib.IO_HUP,
self.watch_process,
'copy_files',
priority=GLib.PRIORITY_HIGH)
winetricks_cache_backup.py 文件源码
python
阅读 21
收藏 0
点赞 0
评论 0
评论列表
文章目录