2018年7月20日 星期五

SWIProlog on TextMate

因TextMate提供的Plugin有問提,只好自己再改一下


#!/usr/bin/env ruby18
require ENV["TM_SUPPORT_PATH"] + "/lib/tm/executor"
require ENV["TM_SUPPORT_PATH"] + "/lib/tm/save_current_document"
TextMate.save_current_document
TextMate::Executor.make_project_master_current_document
command = ["swipl", "-f", "#{ENV["TM_FILEPATH"]}", "-t", "main", "-g", "true", "--quit"]
TextMate::Executor.run(command)
view raw swipl.pl hosted with ❤ by GitHub