Fork me on GitHub
#emacs
<
2017-12-28
>
bozhidar07:12:22

But probably the approach that @dpsutton suggested is good enough for you, even if it’s not as reliable as using CIDER’s indentation metadata.

qqq10:12:40

is there anemacs builtin for: take current location, insert space chars until current char is at location 70

qqq10:12:55

to be precise "insert spaces before cu4rent cursor, until cursor is at column 70"

bozhidar10:12:39

Don’t think so, but it would be pretty simple to build such a command.

bozhidar10:12:45

Why would you need something like this?

qqq10:12:01

this is going to sound stupid; I find code much easier to read when I write it as:

(def some-fn .                       (fn [] ... 
because: 1. I'm on an ultra wide monitor 2. the lhs is "uncluttered" so I can easily read off the function names

vemv16:12:25

don't mean to be "that guy", but better to solve the root problem than starting what seems a non-ideal practice - it can bite back when you collaborate on clj projects I'd frame the problem as a window-management problem (at OS level), or frame-mgmt problem (at emacs level) namely: how to have an centered, not-overly-wide editor frame in my ultrawide screen?

qqq10:12:36

(defun insert-to ()
  (interactive)
  (if (< (current-column) 40)
      (insert-char ?\s)))
is what I have so far

qqq10:12:51

using if instead of while to avoid infiniteloop since I'm not sure if insert-char goes left or right

qqq10:12:39

okay, it appears to work now 🙂

bostonaholic15:12:21

@bozhidar That’s cool, I didn’t know about style metadata. However, I’m not a fan of adding editor-specifics to source code. That includes things like adding .idea (intellij files) to .gitignore or adding // -*- java -*- at the top of a file to signal to the editor to use java-mode.

bozhidar17:12:58

Well, this metadata is currently understood only by CIDER, but it’s really something generic which I hope others would eventually process as well.

bozhidar17:12:53

That would be big for the Clojure community.

bozhidar19:12:04

Hey everyone, Here’s one (a bit overdue) Christmas present for all of you - a major update to CIDER, the popular Clojure interactive development environment, built on top of Emacs and nREPL. The big news is that CIDER 0.16 starts much faster when you use cider-jack-in (due to deferred loading of most of the nREPL middleware that CIDER uses internally to power its features). As usual - there are other small new features, improvements and bugfixes. Go over the release notes for all the details! Enjoy CIDER 0.16 (ir)responsibly and have an awesome New Year! P.S. Special thanks to ClojureX’s team for helping me find the energy and the resolve to finish the work on this release and to all the amazing people who contributed to it! You’re awesome! Keep rocking! 🙂 P.P.S. We’ve got plenty of small newcomer-friendly tickets that you can help with here https://github.com/clojure-emacs/cider/issues?q=is%3Aissue+is%3Aopen+label%3A%22low+hanging+fruit%22

### New Features

* [#2082](), [cider-nrepl#440](): Add specialized stacktraces for clojure.spec assertions.
* [#2111](): Add `cider-pprint-eval-last-sexp-to-comment` and `cider-pprint-eval-defun-to-comment`.
* Add a REPL shortcut for `cider-repl-require-repl-utils` (this makes it easy to require common functions like `doc`, `source`, etc. in REPL buffers).
* [#2112](): Add a new interactive command `cider-find-keyword` (bound to `C-c C-:`).
* [#2144](): Create a Docker image to mimic the Travis CI environment.

### Changes

* `cider-switch-to-last-clojure-buffer` switches to most recent relevant Clojure(Script) buffer instead of the last "remembered" buffer.
* [cider-nrepl#438](): Improve startup time by deferring loading CIDER's middleware until the first usage.
* [#2078](): Improve startup time by bundling together sync requests during startup.
* `cider-rotate-default-connection` will warn if you use it with only a single active connection.
* `cider-format-buffer` tries to preserve the point position.

### Bugs Fixed

* [#2084](): Select correct REPL type (clj or cljs) in `cider-switch-to-repl-buffer` conditional on the current buffer.
* [#2088](): Fix functions defined with `def` being font-locked as vars instead of functions.
* [#1651](), [cider-nrepl#445](): Fix `cider-expected-ns` returns `nil` on boot projects.
* [#2120](): Fix Travis CI build errors for Emacs versions >25.2.
* [#2117](): Ensure `cider-repl-result-prefix` is only inserted before the first result chunk.
* [#2123](): Process properly the Java version in Java 9.

bostonaholic19:12:43

thanks for all of your wonderful work @bozhidar!