This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-10-18
Channels
- # aleph (59)
- # beginners (21)
- # bigdata (1)
- # boot (110)
- # cider (7)
- # clara (1)
- # cljs-dev (160)
- # cljsjs (3)
- # clojars (10)
- # clojure (122)
- # clojure-czech (2)
- # clojure-dusseldorf (5)
- # clojure-france (1)
- # clojure-italy (4)
- # clojure-korea (5)
- # clojure-russia (13)
- # clojure-spec (15)
- # clojure-uk (78)
- # clojurebridge (1)
- # clojurescript (196)
- # core-async (6)
- # core-logic (27)
- # cursive (11)
- # data-science (2)
- # datomic (45)
- # dirac (9)
- # emacs (2)
- # funcool (8)
- # hoplon (16)
- # immutant (13)
- # jobs (1)
- # klipse (11)
- # lein-figwheel (1)
- # leiningen (1)
- # off-topic (3)
- # om (40)
- # onyx (31)
- # pedestal (25)
- # re-frame (55)
- # ring (1)
- # ring-swagger (1)
- # rum (4)
- # specter (1)
- # sql (2)
- # untangled (30)
- # vim (12)
- # yada (12)
@neurogoo CIDER does do that, in that when you create a new clj/s file from CIDER it’ll have the namespace declaration at the top. But honestly, ns declaration is so low-ceremony that I wouldn’t really care at all if that CIDER feature disappeared.
I’d start by just putting your files in src/myprojectname
, and then your ns declaration is just
(ns myprojectname.filename-without-suffix)
eg file src/foo/bar.clj
would have (ns foo.bar)
There’s not an enforced 1-to-1 relationship between files and namespaces, but 99+% of the time you’ll find that it’s one-file/one-namespace.
Unless that feature is in the newest cider, I'm pretty sure that's actually clj-refactor
@madstap that may be. I’ve always had both together, so I’ve never noticed what’s part of which.
You’re totally right, it’s mentioned here: https://github.com/clojure-emacs/clj-refactor.el/wiki#automatic-insertion-of-namespace-declaration
@eggsyntax Are you sure about the 1:1 relationship not being valid? I thought that when you did a require, clojure looked for the file corresponding to the namespace on the classpath?
It does but you can load other files in the context of that namespace
clojure.core is split up over a bunch of files
You can also create multiple namespaces within one file
But both of those are uncommon
@chokheli Hey dude. 🙂 I’m college-age too. I think a channel just got started up for Python in here. Apparently Clojure can interop with Python via Jython (Python for the JVM). I’d be super down to work with you to try and create wrappers for TensorFlow and all the other great machine learning / data-analysis Python libraries. I’ll definitely be needing to use those soon for a cool project of mine. 🙂
does (keys . . . )
preserver order?
It does not present the keys in insertion order
It does present the keys in a reliable order, for a given map
@alexmiller https://github.com/clojure/clojure/blob/master/src/clj/clojure/core.clj I don't see where it's split up?
Or are you referring to namespaces like clojure.core.data
?
Basically — can you give me an example, because I don't understand and it sounds useful 😛
Just grep for load in there - you will see that a bunch of additional files are loaded