Turning Kate into a Prolog IDE
The thing you do most of time is consulting files and if you type it manually it can be pretty annoying. But Kate can help :)
Settings -> Configure Kate… -> Application -> Plugins
and check if “External Tools” is checked, if not check it and click “Apply”. Now you should have a
Settings -> Configure Kate… -> Application -> Plugins -> External Tools
go there and click “New”, lets call it “Prolog Consult” and set the script
qdbus org.kde.kate-`pidof kate` /Sessions/1 sendText "consult('%directory/%filename')."$'\n'
and as executable set “qdbus” (if not already set automatically), you can even assign it to some mime types and tell it to save the current file(“Current Document”) if you want. Now click “OK” and close the “Configure – Kate” dialog by clicking “OK” again. To make things even easier open
Settings -> Configure Shortcuts
and assign “Prolog Consult” to a shortcut you like, and that’s it. Now every time you press the shortcut a
is send to your Kate konsole.
The only bummer that’s left is that default mimetype settings only have Prolog with *.prolog extensions, but swi-prolog only likes *.pl files, an easy way to fix this is adding a kate modeline at the beginning or end of the file, like
% kate: hl Prolog;
And now you also have prolog highlighting, so Kate is pretty cool and I hope it will help the *cough*countless*cough* prolog hackers out there. I am pretty sure you can modify it for various other uses :)