spacemacs

Spacemacs docs: http://develop.spacemacs.org/doc/DOCUMENTATION.html http://develop.spacemacs.org/layers/+lang/clojure/README.html https://practicalli.github.io/spacemacs/
kirill.salykin 2020-05-18T06:56:01.115600Z

goodmorning jack-in-clj&cljs with shadow-cljs seems to start two clojurescript repls for me does anyone has the same issue? is it spacemacs or cider? thanks

murtaza52 2020-05-18T08:52:56.117200Z

@jr0cket @spfeiffer @aisamu thanks for the help. Including the correct globbing patterns in the .gitignore file did the trick.

murtaza52 2020-05-18T08:56:54.121Z

Usually when I want to evaluate a form SPC m e f does the trick. This is very handy because I can eval the form when my cursor is at any point of the form. However while development I also have a lot of forms in the comment block, and these cant be evaled using the above. To eval these forms I need to navigate to the start of the form and then eval them using SPC m e v This works but is tedious, because I always need to navigate to the start of the form first. Any tips on how I can reduce the pain ?

kszabo 2020-05-18T09:32:41.121300Z

(setq clojure-toplevel-inside-comment-form 't)

kszabo 2020-05-18T09:33:03.121900Z

this will make ,ef work as โ€˜expectedโ€™ in comment forms

practicalli-john 2020-05-18T10:30:08.126600Z

To evaluate forms in a (comment ,,, ) block using , e f I add the layer variable clojure-toplevel-inside-comment-form t to the clojure layer definition in .spacemacs. For example, my clojure layer config is as follows

(clojure :variables
              clojure-toplevel-inside-comment-form t
              cider-overlays-use-font-lock t
              clojure-enable-linters 'clj-kondo)
If you are going to use setq instead, then it should really be wrapped in an add-hook form.

practicalli-john 2020-05-18T10:31:43.128300Z

For individual forms I simply use the #_ reader macro to comment that form. If this is placed on the line before, then , e f will evaluate even though the form is commented. For example:

#_ 
(str "I wont evaluate when you eval the buffer, but will evaluate when using , e f")

practicalli-john 2020-05-18T10:34:41.129200Z

You can also create a design_journal.clj namespace and add your forms to that, then you do not need to comment them out at all

murtaza52 2020-05-18T11:01:42.129600Z

@thenonameguy @jr0cket thanks for the tips

murtaza52 2020-05-18T11:03:18.130600Z

I feel lately that my spacemacs is not snappy, it takes time to respond to commands, is there anything I can do to make it more responsive ?

practicalli-john 2020-05-18T11:16:19.135400Z

@murtaza52 The only time I had Spacemacs become slow to respond was when my Operating System updated the desktop compositor (compton) it used and there was a lag redrawing the cursor, very annoying. Otherwise I have always had Spacemacs be very responsive across multiple laptops. Is it still slow if you switch the current fundamental mode? Sometimes excessive font locking can slow things down, so fundamental mode will switch that off. Have you checked Emacs its running any processes, SPC a p ? There are some other troubleshooting ideas here, probably the ones toward the bottom are more relevant https://practicalli.github.io/spacemacs/install-spacemacs/troubleshooting.html

murtaza52 2020-05-18T11:17:46.136500Z

I get the following warning when I connect to an external shadow-cljsrepl -

WARNING: CIDER requires cider-nrepl to be fully functional. Some features will not be available without it!
However if I start the shadow-cljs using cider-jack-in I dont get the warning. What could be wrong ?

practicalli-john 2020-05-18T11:20:51.139300Z

@murtaza52 cider-nrepl library is injected into the command line when using cider-jack-in- commands. You need to add cider-nrepl to your startup or project when using cider-connect and using a version that works with the version of CIDER you are running (one reason I try avoid using cider-connect) . I am sure there are some docs that describe how to do this on the internet, but I have forgotten how to do this now, sorry.

practicalli-john 2020-05-18T11:25:38.139600Z

There is some info in the shadow-cljs docs https://shadow-cljs.github.io/docs/UsersGuide.html#_preparing_the_app

practicalli-john 2020-05-18T11:26:13.140Z

although using jack-in approach is going to be less fiddly https://shadow-cljs.github.io/docs/UsersGuide.html#cider

murtaza52 2020-05-18T12:23:22.141200Z

thanks created a new alias in the deps.edn and added the cider-nrepl dep there. Then referred that alias in the shadow-cljs.edn file.

๐Ÿ‘ 1
2020-05-18T20:07:26.143300Z

Has anyone had luck with the kuberenetes layer? It just crashed my computer ๐Ÿ˜•

practicalli-john 2020-05-18T22:34:16.145Z

@drewverlee not tried kubes layer in Spacemacs yet. You could always ask on the Spacemacs Gitter chat https://gitter.im/syl20bnr/spacemacs Or raise an issue, SPC h I

๐Ÿ‘ 1