Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

(if (form)<Enter> does not indent the new line #32

Open
WalterGR opened this issue Jan 1, 2016 · 2 comments
Open

(if (form)<Enter> does not indent the new line #32

WalterGR opened this issue Jan 1, 2016 · 2 comments

Comments

@WalterGR
Copy link

WalterGR commented Jan 1, 2016

Repro:

  1. Open a .clj file.
  2. Type the following in the file, at the top level, and press Enter/Return.
(if (form)

Expected:

The cursor is indented on the new line by 2 spaces:

(if (form)
  _

Actual:

The cursor is not indented at all:

(if (form)
_

Strangely, if you instead type the following (i.e. form not enclosed in parens) and press Enter/Return:

(if form

then the new line is indented.

@wingyplus
Copy link
Contributor

wingyplus commented Sep 9, 2016

I think I can solve with simple solution, by add increaseIndentPattern to settings

'.source.clojure':
  'editor':
    'commentStart': '; '
    'increaseIndentPattern': '\\('

if @50Wliu agreed, I'll make a pull request.

@50Wliu
Copy link
Contributor

50Wliu commented Sep 9, 2016

As long as you can ensure that there are no unintended side-effects of that change, feel free to make a PR.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants