summaryrefslogtreecommitdiff
path: root/cider-format.el
Commit message (Collapse)AuthorAge
* Fix restoring point after formatting in some conditionsDieter Komendera2018-09-30
| | | | | | | | | The snippet is used as a regex, so it needs to be quoted to not cause any regex errors further down and also make the search more precise. An example would be that the snippet would contain the opening [ of a clojure vector, but not the closing ], which lead to an invalid regex and thus make re-search-forward/re-search-backward break.
* More precise point positioning for cider-format-defun and no markDieter Komendera2018-09-30
| | | | | | | | | | cider-format-region uses the current point position to figure out where to place the point after formatting. mark-defun manipulates point, so if it was in the middle of some defun, after formatting the point would be placed at the beginning of the defun. Additonally, by not marking any region, it is not necessary to clean up, which previously was broken since save-excursion didn't restore mark since Emacs 25.1
* [#2203] Extract the formatting functionality in its own source fileBozhidar Batsov2018-06-23
This also allows to simply auto-load the formatting commands when they are used for the first time.