Created
April 14, 2014 15:06
-
-
Save jordonbiondo/10656469 to your computer and use it in GitHub Desktop.
working windows omnisharp syntax checker for flycheck
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (flycheck-define-checker omnisharp | |
| "Flycheck checker for omnisharp" | |
| :command ("curl" | |
| "--silent" "-H" | |
| "Content-type: application/json" | |
| "--data-binary" | |
| (eval (concat "@" (omnisharp--write-json-params-to-tmp-file | |
| omnisharp--windows-curl-tmp-file-path | |
| (json-encode (omnisharp--get-common-params))))) ;; do the work here, and get the path | |
| "http://localhost:2000/syntaxerrors") | |
| :error-parser omnisharp--flycheck-error-parser-raw-json | |
| :modes csharp-mode) | |
| (defun omnisharp--write-json-params-to-tmp-file | |
| (target-path stuff-to-write-to-file) | |
| "Deletes the file when done." | |
| (with-temp-file target-path | |
| (insert stuff-to-write-to-file) | |
| target-path)) ;; return the target path |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment