From 2e71246aa406b2d51441a961ec468833656b6798 Mon Sep 17 00:00:00 2001 From: Kyle Meyer Date: Tue, 24 May 2016 23:54:32 -0400 Subject: Fix indentation for continued lines under naked rule --- snakemake-mode.el | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'snakemake-mode.el') diff --git a/snakemake-mode.el b/snakemake-mode.el index e89d25b..5b4fb28 100644 --- a/snakemake-mode.el +++ b/snakemake-mode.el @@ -280,11 +280,13 @@ returned." (looking-at-p "^\\s-*$"))) (forward-line -1))) (and (looking-at - (concat snakemake-field-key-indented-re "\\s-*")) + (concat snakemake-field-key-indented-re "\\s-*\\(.*\\)")) (not (equal (match-string-no-properties 1) "run")) (cond (goto-first-p - (- (match-end 0) (line-beginning-position))) + (if (equal (match-string-no-properties 2) "") + above-indent + (- (match-beginning 2) (line-beginning-position)))) ((< field-indent initial-indent) field-indent))))))))))))) -- cgit v1.2.3