This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-01-09
Channels
- # beginners (38)
- # boot (160)
- # cider (143)
- # cljs-dev (62)
- # cljsjs (2)
- # cljsrn (3)
- # clojure (278)
- # clojure-austin (8)
- # clojure-brasil (5)
- # clojure-greece (2)
- # clojure-italy (11)
- # clojure-russia (188)
- # clojure-sg (2)
- # clojure-spec (118)
- # clojure-uk (103)
- # clojurescript (87)
- # core-async (8)
- # cryogen (2)
- # cursive (12)
- # datomic (119)
- # emacs (13)
- # hoplon (4)
- # immutant (12)
- # off-topic (12)
- # om (54)
- # om-next (5)
- # onyx (1)
- # pedestal (2)
- # portland-or (2)
- # re-frame (58)
- # reagent (18)
- # ring-swagger (18)
- # rum (4)
- # spacemacs (4)
- # specter (3)
- # untangled (65)
- # yada (25)
@juhoteperi: @martinklepsch I'm using multiple builds for an app which runs both in the browser and in electron, also working on a ipfs electron version
hey all, quick question: I'm setting up a new cljs project with boot, I've got everything loading. However, when I make changes to the source files, nothing happens, even though I'm using (watch)
nevermind - I had tacked on a (wait)
call at the end, that seems to have stopped (watch)
from doing anything
@juhoteperi We also have multiple builds: devcards, main, admin, test
Would love to fix this with modules somehow, because it is pretty annoying especially when compling for prod: main and admin can be pretty slow
Any idea why update-feeds
doesn’t invoke aot
when I call it and how could I refactor this correctly without writing two tasks?
(deftask update-feeds*
[]
(…))
(deftask update-feeds []
(comp (aot "-n" 'feeds.rss20-parser)
(update-feeds*)))
@borkdude what is the name of your boot task for managing deps again? I should have bookmarked it 😄
@borkdude thanks I will add it here: https://github.com/boot-clj/boot/wiki/Community-Tasks
Oh OK cool
Probably it should still be there, or somewhere there for visibility
Have you ever considered adding it to bootlaces
?
Bootlaces feels like a good place for boot utilities (imho)
In any case, good job, the data approach is cool
> Handy tasks and things for the boot Clojure build tool. Is from Bootlaces task, not Bootlaces maven group
Bootlaces maven group is what we currently plan to use to deploy "the official" Boot tasks (boot-cljs, boot-reload, boot-cljs-devtools)
Ah no, the group name is powerlaces...
I'm not completely convinced about this naming yet, it is quite confusing
Yeah powerlaces
😀😀😀
Also, if we powerlaces or something is going to be the place for "official tasks", I'd be quite strict about what tasks are going to be included there
I think I'll just release next Boot-cljs with current group id and namespace
Ok sounds good
anyone here used boot-npm
to install “local” NPM dependencies in a boot-cljs
environment? I find that it works but then my node_modules
dir ends up in target/
which means that my js/require
or cljs.nodejs/require
arguments change from imagemagick
to ../target/node_modules/imagemagick/package.json
, which is …gross
@chris_johnson I haven't but you could use sift
to filter them out if you don't want them in target
well, ideally I’d want them above target, though to be honest at this point I’m strongly considering just giving them the old npm install -g
and letting the Node resolver deal with it
my use case is making Nervous Systems’ lein-cljs-lambda
work in “idiomatic” Boot, and for right now the only modules I actually need are aws-sdk
and imagemagick
, which will be provided in the Node runtime in Lambda
oh incidentally, I wanted to do that too 😄
and in fact anything I need to include in later Lambda functions would have to go through a nice yak-shave because they’d need to be “built” against Amazon Linux, which you’ll be surprised to learn I don’t run as my workstation OS
I’m considering writing up a blog post once I get it to work, which should be soon-ish.
(NB: I’ve said that before, and my blog is still exactly one post about how I use org-mode -> Jekyll -> Github Pages to publish a blog)
ah ah ah nice can't wait for that
@richiardiandrea I added boot-bundle myself here: https://github.com/boot-clj/boot/wiki/Community-Tasks
so @micha I am trying to sneak a dep in boot-shim.clj
...If I call (pod/add-dependencies new-env)
in there it should resolve and add the dep right? Did I understand right?
ok, I see the subsequent require
failing
Caused by: java.lang.ClassNotFoundException: lucid.core.inject
which is weird, because the dep is there
my attempt:
(require '[boot.core :as boot])
(require '[boot.pod :as pod])
(let [new-env (-> (boot/get-env)
(update :dependencies conj
'[im.chit/lucid.core.code "1.2.8"]
'[im.chit/lucid.core.debug "1.2.8"]
'[im.chit/lucid.core.inject "1.2.8"]
'[im.chit/lucid.mind "1.2.8"]))]
(pod/add-dependencies new-env)
(require '[lucid.core.inject :as inject])
(inject/in
clojure.core
[lucid.mind .> .? .* .% .%> .& .>ns .>var]
[lucid.core.debug dbg-> dbg->> ->doto ->>doto ->prn]
[clojure.pprint pprint]
[clojure.java.shell sh]))
Caused by: java.lang.RuntimeException: No such namespace: inject
Ok it looks like I cannot do it because I don't have boot.aether
on the classpath
yep weird, shouldn't it be there already?
so I cannot use get-env
uhm yeah
but being a side effecty thing, I can just call add-dependencies
with an empty env
I'll try
Hello
I can't get boot to run on Circle CI
I followed https://github.com/boot-clj/boot/wiki/Running-Boot-on-CI-systems
but get boot: line 1: {error:Not Found}: command not found
anything trivial I am missing?
machine:
java:
version: oraclejdk8
environment:
_JAVA_OPTIONS: "-Xms512m -Xmx1024m"
dependencies:
pre:
- curl -L -o boot
- chmod +x ~/bin/boot
override:
- boot uberjar
cache_directories:
- "~/bin"
- "~/.m2"
- "~/.boot/cache/bin"
- "~/.boot/cache/lib"
test:
override:
- echo 1
@adrien it looks like you are saving the script in the wrong place with curl
is it on the PATH
by default
yeah probably so
try to echo $PATH just to be sure 😄
😄
ubuntu@box3480:~$ which boot
ubuntu@box3480:~$ echo $PATH
/opt/circleci/nodejs/v4.2.6/bin:/opt/google-cloud-sdk/bin:/opt/ghc/8.0.1/bin:/opt/cabal/1.24/bin:/opt/alex/3.1.7/bin:/opt/happy/1.19.5/bin:/home/ubuntu/.composer/vendor/bin:/opt/circleci/.phpenv/shims:/opt/circleci/.phpenv/bin:/opt/circleci/.rvm/gems/ruby-2.2.4/bin:/opt/circleci/.rvm/gems/ruby-2.2.4@global/bin:/opt/circleci/.rvm/rubies/ruby-2.2.4/bin:/home/ubuntu/.go_workspace/bin:/usr/local/go/bin:/opt/circleci/nodejs/v4.2.6/bin:/opt/circleci/.pyenv/shims:/opt/circleci/.pyenv/bin:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/android-sdk-linux/platform-tools:/usr/local/android-sdk-linux/tools:/usr/local/apache-maven/bin:/home/ubuntu/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/local/gradle-1.10/bin:/opt/circleci/.rvm/bin:/opt/circleci/.rvm/bin
cool 🙂
ubuntu@box931:~$ which boot
/home/ubuntu/bin/boot
ubuntu@box931:~$ ls
bin numerry-erp
ubuntu@box931:~$ cd numerry-erp/
ubuntu@box931:~/numerry-erp$ boot uberjar
/home/ubuntu/bin/boot: line 1: {error:Not Found}: command not found
ubuntu@box931:~/numerry-erp$ boot -u
/home/ubuntu/bin/boot: line 1: {error:Not Found}: command not found
weird, the first time it should download the dependencies to .m2
as well
@richiardiandrea @micha it works! thanks a million!
@adrien about that I have just pushed a change to cider
to make it more robust if you feel like trying 😄
it will be possible to inject "custom" middleware at some point
no rush, just to validate that it works 😄
@adrien you need to clone also https://github.com/arichiardi/cider-nrepl/tree/boot-middleware
and run lein install
yeah, there are two moving parts, one is the emacs cider
plugin
the other one is the cider-nrepl
artifact
do you have a way to update (manually) cider packages? If not it might a hassle
oh ok then you'd better wait that the merge it but thanks anyways 😉
@micha surpringly the injection of doc
clashes: WARNING: dir already refers to: #'clojure.core/dir in namespace: boot.tmpdir, being replaced by: #'boot.tmpdir/dir
I will at some point use an nrepl middleware, but I have played enough with it for today 😄
lists the simbols in a namespace
oh sorry look:
-------------------------
clojure.repl/dir
([nsname])
Macro
Prints a sorted directory of public vars in a namespace
nil
probably I don't need it 😉
in vyniasa/lucididy it uses the .
namespace for injections
I guess to avoid clashes
anyways, thanks for bearing with me on my crazy experimentation 🙂
for now I have settled for a simple:
(ns .)
(require 'clojure.repl)
;; macros
;;
(intern '. (with-meta 'doc {:macro true}) @#'clojure.repl/doc)
(intern '. (with-meta 'dir {:macro true}) @#'clojure.repl/dir)
(intern '. (with-meta 'source {:macro true}) @#'clojure.repl/source)
;; fns
(intern '. 'apropos @#'clojure.repl/apropos)
(intern '. 'demunge @#'clojure.repl/demunge)
(intern '. 'find-doc @#'clojure.repl/find-doc)
(intern '. 'pst @#'clojure.repl/pst)
(intern '. 'root-cause @#'clojure.repl/root-cause)
(intern '. 'set-break-handler! @#'clojure.repl/set-break-handler!)
(intern '. 'stack-element-str @#'clojure.repl/stack-element-str)
(intern '. 'thread-stopper @#'clojure.repl/thread-stopper)
(require 'clojure.pprint)
(intern '. 'pprint @#'clojure.pprint/pprint)
(require 'clojure.java.shell)
(intern '. 'sh @#'clojure.java.shell/sh)
hello folks - has anyone of you managed to add some browser feature detection and conditional polyfilling with boot yet?
struggling here on how to conditionally load a polyfill here before loading the app code