Skip to content

Instantly share code, notes, and snippets.

@teh

teh/stack.py

Created Aug 14, 2016
Embed
What would you like to do?
#!/usr/bin/env python
import sys
import time
import os
import subprocess
def main():
if sys.argv[1:] == ["path", "--project-root", "--verbosity", "silent"]:
print "/home/tom/src/intero"
return
if sys.argv[1:] == ["exec", "intero"]:
return
if sys.argv[1:4] == ['ghci', '--with-ghc', 'intero']:
odir = sys.argv[8]
hidir = sys.argv[10]
with open('/tmp/intero-log', 'a') as f:
f.write("HI {} HO {}\n".format(odir, hidir))
subprocess.call(['/home/tom/.nix-profile/bin/ghci', '-odir', odir, '-hidir', hidir])
return
with open('/tmp/intero-log', 'a') as f:
f.write(repr(sys.argv))
f.write("\n")
main()
@teh

This comment has been minimized.

Copy link
Owner Author

@teh teh commented Aug 14, 2016

elisp error on ctrl+q:

Debugger entered--Lisp error: (quit)
  intero-collect-compiler-messages(([cl-struct-flycheck-error #<buffer Setup.hs> intero "/home/tom/src/intero/Setup.hs" 3 9 "error:\n    parse error (possibly incorrect indentation or mismatched brackets)" error nil]))
  #[(state string) "\305\306�\"�r\307\n\310\"q\210\311\312�\"\313\307\n\314\"p�#��\315�!\210\307\n\316\"\317\320\321�\"\"\210   \2059�\322\323\324\325\f\326\327#P\330\331$,\207" [string compile-ok state msgs modules string-match "OK, modules loaded: \\(.*\\)\\.$" plist-get :file-buffer match-string 1 intero-parse-errors-warnings-splices :checker intero-collect-compiler-messages :cont finished cl-remove-if #[(msg) "�\302H    >\204��\303\304\305\306#\210�\307H\310=\207" [msg cl-struct-flycheck-error-tags 0 error "%s accessing a non-%s" flycheck-error-level flycheck-error 7 splice] 4] intero-async-call backend ":m + " replace-regexp-in-string "," "" nil #[(_st _) "\300\207" [nil] 1]] 7]((:cont #[128 "\301\302\300�#\207" [[cl-struct-flycheck-syntax-check #<buffer Setup.hs> intero nil] apply flycheck-report-buffer-checker-status] 5 "\n\n(fn &rest ARGS)"] :file-buffer #<buffer Setup.hs> :checker intero) "[1 of 1] Compiling Main             ( /home/tom/src/intero/Setup.hs, -odir=/run/user/1000/intero22410FlO/Main.o )\n\n/home/tom/src/intero/Setup.hs:3:9: error:\n    parse error (possibly incorrect indentation or mismatched brackets)\nFailed, modules loaded: none.\n")
  intero-read-buffer()
  #[(process string) "�\203 �\306\307   \"\210\310\311\n!!\205Q�r\311\n!q\210db\210 c\210�\203N�\f\203N�\312\313 \314 \"�\315\316
\"\203I�\306\317\320\321\322\323
#\323\324#@\206C�\325\227\"\210\202M�\306\326!\210)\327 )\207" [intero-debug string process intero-try-with-build intero-starting last-line message "[Intero] <- %s" buffer-live-p process-buffer buffer-substring-no-properties line-beginning-position line-end-position string-match "^Progress" "Booting up intero (building dependencies: %s)" split-string replace-regexp-in-string "�+" "\n" t "..." "Booting up intero ..." intero-read-buffer] 7](#<process stack> "[1 of 1] Compiling Main             ( /home/tom/src/intero/Setup.hs, -odir=/run/user/1000/intero22410FlO/Main.o )\n\n/home/tom/src/intero/Setup.hs:3:9: error:\n    parse error (possibly incorrect indentation or mismatched brackets)\nFailed, modules loaded: none.\n�")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment