X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=elpa%2Fflycheck-kotlin-20170122.1137%2Fflycheck-kotlin.el;fp=elpa%2Fflycheck-kotlin-20170122.1137%2Fflycheck-kotlin.el;h=bde4946cb4c10f6bdc3e64d6487e33c0934064b8;hb=28a13bd0b8508bbab5e79108e5d32d2edc357baa;hp=0000000000000000000000000000000000000000;hpb=26914a98eea51a46872bacef7c2dcf8ba96a50de;p=emacs-init.git diff --git a/elpa/flycheck-kotlin-20170122.1137/flycheck-kotlin.el b/elpa/flycheck-kotlin-20170122.1137/flycheck-kotlin.el new file mode 100644 index 0000000..bde4946 --- /dev/null +++ b/elpa/flycheck-kotlin-20170122.1137/flycheck-kotlin.el @@ -0,0 +1,57 @@ +;;; flycheck-kotlin.el --- Support kotlin in flycheck + +;; Copyright (C) 2017 Elric Milon +;; +;; Author: Elric Milon +;; Created: 20 January 2017 +;; Version: 0.1 +;; Package-Version: 20170122.1137 +;; Package-Requires: ((flycheck "0.18")) + +;;; Commentary: + +;; This package adds support for kotlin to flycheck. To use it, add +;; to your init.el: + +;; (require 'flycheck-kotlin) +;; (add-hook 'kotlin-mode-hook 'flycheck-mode) + +;;; License: + +;; This file is not part of GNU Emacs. +;; However, it is distributed under the same license. + +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3, or (at your option) +;; any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. + +;;; Code: +(require 'flycheck) + +(flycheck-define-checker kotlin-ktlint + "A Kotlin syntax and style checker using the ktlint utility. +See URL `https://github.com/shyiko/ktlint'." + :command ("ktlint" source-inplace) + :error-patterns + ((error line-start (file-name) ":" line ":" column ": " (message) line-end)) + :modes kotlin-mode) + + +;;;###autoload +(defun flycheck-kotlin-setup () + "Setup Flycheck for Kotlin." + (add-to-list 'flycheck-checkers 'kotlin-ktlint)) + +(provide 'flycheck-kotlin) +;;; flycheck-kotlin.el ends here