Fork me on GitHub

Just a thought about possible changes in boot. Because I use emacs cider and often change Cider Boot Parameters in Customize options. That would be, send the user a warning if a requested task is not defined instead of not starting boot. I guess this could either be in boot itself, that all undefined tasks in command line will cause a warning, or in cider that looks for if a tasks exists before executing it?


@hlolli: I'm not sure I understand this: "Because I use emacs cider and often change Cider Boot Parameters in Customize options. " What does the customize have to do with unknown Boot tasks?


So to run a task I do: M-x customize-variable cider-boot-parameters and add there my predefined tasks. Maybe I'm doing it wrong?


So I may enter a task that exists in one project but not another. And every time I re-run cider, I will remove/add the corresponding tasks. No issue here of course. Mainly thinking about newcomers.


Well just a thougt, maybe a bad idea.


@hlolli: I think it's good that things break if a task does not exist but I also see why one would want this


@hlolli: I'd probably suggest to have a my-cider like function. That's how I do it (with inf-clojure but that doesn't matter I guess)


(have that function in emacs so you don't customize the default cider function but instead have the default & a customized one)


Yes good point! Ok, there reason I got thinking about this is that I shared my emacs with a friend of mine to run a boot based app I made. Then he hit the error that the task boot-cider task didn't exists, so I had to explain to him to remove it from my config. I guess an easy solution is not to share an emacs config with any task defined besides the repl 🙂


ok end of argument (on my behalf), breaking sounds very preventive actually.


you probably should avoid having tasks in build.boot which are defined in places like profile.boot


yes boot-cider is in ~/.boot profiles.


you could also customize the build.boot to see if boot-cider is defined and only use it in that case


I actually had that exact idea, I made a check if the symbol was defined.. let me show you...


the task was actually called cider forgot. But this was my attempt

(if-not (nil? (resolve 'cider))
 (deftask cider nil))


(comp (if (bound? #'cider)


nice, didn't know about bound? thanks, I think I will add this for safety.


is there a possibility to see if a user is running from lighttable, I noticed lighttable requires some middleware for boot... well I can research that myself.


I think bound? checks if the var has a value vs. resolve which would also return a (declare foo) var if I understand correctly


ok, I read about declare long time ago on stackoverflow. So I'm not surprised I'm using it incorrectly


probably not important for your use case but just learned about the difference myself so thought I'd share 🙂


nice, I read slack channels just to see what people are sharing.


well, to add to the previous discussion, the problem with bound? is that it will throw an exception instead if just saying false.


Wowo heroku is launching a Kafka service