compiler.py 文件源码

python
阅读 22 收藏 0 点赞 0 评论 0

项目:PyIDE 作者: raggesilver 项目源码 文件源码
def compile(self, *args):

        self.parent.running = True

        if os.path.isfile(os.path.join(self.path, '.pyide-project.json')):

            with open(os.path.join(self.path, '.pyide-project.json'), 'r') as f:
                ## Do stuff
                print('Found file')
                project = json.load(f)
                if os.path.exists(os.path.join(self.path, 'Makefile')):
                    self.stateEntry.set_text('Running...')
                    Gtk.main_iteration()
                    self.parent.openTerminal()
                    # with open(os.path.join(self.path, 'Makefile'), 'r') as f:
                    #     command = f.readlines()
                    #     for l in command:
                    #         self.parent.terminal.feed_child(l, len(l))
                    self.parent.terminal.feed_child("make all\n", len("make all\n"))
                    self._quit()

        else:

            self.p = ProjectSettingsWindow(self.parent, self.compileBtn, self.stateEntry, self.path, self)

            ## Create the file and then compile
            # pyideProject = json.JSONEncoder({
            #     ''
            # })
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号