#clojure logs

2015-09-27

00:32akkadwhat editor has the clojure dev mindshare these days?
00:35scriptorlargely emacs, I think some people use Cursive or Vim with Fireplace
00:36cfleming(disclaimer: Cursive author) Actually, a lot of people use non-Emacs setups these days
00:37nxqdhi guys, does anyone here using reagent. I have a little problem when working with the lib. I'm trying to create a component with local state and parameters, what I have tried is : (defn comp [x] (let [state (r/atom {:test true})] (fn [x] [:div (str x)]))
00:37nxqdbut x doesn't seem to be passed down. it's value is nil.
00:37cflemingakkad: If you're new to Clojure, generally you should use whatever you're used to, and not try to mix learning Clojure and a new editor
00:37akkaduse to CL and emacs, but cider clearly is more than the editor can handle
00:37scriptorcfleming: what's the breakdown these days? I haven't really been following the community news much
00:38scriptorakkad: cider works great with emacs
00:38cflemingscriptor: The only data I'm aware of is the state of Clojure survey, which is almost a year out of date now and must be due for a new one soon.
00:39nxqdakkad: if you are learning Clojure, but advice is don't mix up learning and customizing editor at the same time.
00:39akkadhttps://gist.github.com/7bc575c5e69574af27e9 it loves emacs like a parasite
00:39akkadnxqd: obviously not
00:39nxqdI use only inferior-lisp to integrate with clojure repl. No fancy stuff :D it just works
00:39akkadyeah that does seem less likely to eat cpu
00:42akkadwas just curious where most of the love was going these days for improvements.
00:45akkadis there an inspect/describe equiv?
01:03nowprovisionwhen using spyscope, is it the best approach to remove #spy/* entirely once shipping, or is there a simple way to make #spy/* be a no-op?
01:07nowprovisionor put another way change/replace data readers depending on environment
01:59craftybonesWhat is the difference between let and when-let? I mean I get it from the documentation, but I don't see when to use the when-let. Let seems to handle it in most cases
02:04craftybonesAh, never mind. Got it
02:29craftybonesCan most node libraries be used interchangeably in cljs?
02:55akkadhttps://gist.github.com/b5d9b69f6978827a2782 this look proper?
03:00tmtwd(defn mmap [m f a] (->> m (f a) (into (empty m)))) what does this function do?
03:02tmtwdnvm
03:40craftybonesIs there a preferred way of doing an indexOf look up? I am using .indexOf, but I can't pass that around as it is Java interop. Is there a better way?
03:41craftybonesI have a function that may use indexOf or lastIndexOf depending on different situations.
03:46nowprovisionwhat do you want to do with the index, perhaps you can use something that encapsualte both the lookup and next operation (e.g. a regex replace)
03:47craftybonesI have a series of headings(north south etc). Depending on which direction I turn, I want to pick the next heading
03:48craftybonesI am storing this in a vector [:N :NE :E :SE :S :SW :W :NW]
03:50craftybonesI simply want the next index, but the next index is not a simple dec/inc if its the last or first element.
03:50craftybonesin order to deal with this, I wanted to have the vector as [:N :NE :E :SE :S :SW :W :NW :N]
03:51craftybonesNow, my turn-left and turn-right are simply (dec .lastIndexOf) and (inc .indexOf) respectively
03:52TEttingerit is a simple inc/dec if you modulo by length
03:54TEttinger,(let [coll [:N :NE :E :SE :S :SW :W :NW]] (map #(nth coll (rem % (count coll)) (range 6 11)))
03:54craftybones@TEttinger, the indexOf is a simple modulo, however, let us say I end up with a 0 as the index. I can't simply dec.
03:54clojurebot#<RuntimeException java.lang.RuntimeException: EOF while reading>
03:54TEttinger,(let [coll [:N :NE :E :SE :S :SW :W :NW]] (map #(nth coll (rem % (count coll))) (range 6 11)))
03:54clojurebot(:W :NW :N :NE :E)
03:55TEttinger,(let [coll [:N :NE :E :SE :S :SW :W :NW]] (map #(nth coll (rem (- 2 %) (count coll))) (range 6 11)))
03:55clojurebot#<IndexOutOfBoundsException java.lang.IndexOutOfBoundsException>
03:55TEttingerhm
03:55TEttingerwhich was it then...
03:55craftybonesMy input btw is not an index. My input is a direction. So there is a lookup
03:55craftybones(= :NW (left-of :N))
03:56TEttinger,(let [coll [:N :NE :E :SE :S :SW :W :NW]] (map #(nth coll (mod (- 2 %) (count coll))) (range 6 11)))
03:56clojurebot(:S :SE :E :NE :N)
03:57TEttingersounds like this would be a good choice for a map?
03:57craftybones@TEttinger - yeah, that's a copout. I was just wondering if there's a way to do this with an indexOf.
03:57craftybonesThanks though
03:57TEttinger,(zipmap [:N :NE :E :SE :S :SW :W :NW] (range))
03:57clojurebot{:N 0, :NE 1, :E 2, :SE 3, :S 4, ...}
03:58craftybones@TEttinger - I was thinking of making each direction hold both its left and right headings. That way its just a straight ahead lookup
03:58craftybonesBut yeah, that'll work too
03:58craftybonesThanks
04:02TEttinger,(let [coll [:N :NE :E :SE :S :SW :W :NW] reversed (zipmap coll (range)) shift #(nth coll (mod (% (reversed %2)) (count coll))) left (partial shift dec) right (partial shift inc)] (-> :N left left left right))
04:02clojurebot:W
04:03TEttinger^ craftybones: look decent?
04:04craftybones@TEttinger yeah, that's pretty cool
04:05TEttingerbidirectional maps are unusually useful considering how rarely they end up in standard libraries. But I guess that's because they're easy enough to fake with a technique like a vector and a map
04:11craftyboneshttps://gist.github.com/craftybones/a5b7a407b321d16e89bf
04:11craftybones@TEttinger - this is what I got
04:11craftybonesTell me what you think if you've a minute
04:12TEttingersure thing
04:12craftybonesIgnore the directions being clobbered, that was just a quickie ;)
04:14TEttingerhm, were you trying to avoid .indexOf ?
04:14TEttingerthat is a clever approach, btw
04:15TEttinger(doc memfn)
04:15clojurebot"([name & args]); Expands into code that creates a fn that expects to be passed an object and any args and calls the named instance method on the object passing the args. Use when you want to treat a Java method as a first-class fn. name may be type-hinted with the method receiver's type in order to avoid reflective calls."
04:15craftybonesThanks. No, I wasn't avoiding it, just wasn't sure how to pass it
04:15craftybonesThanks a ton for memfn
04:15craftybonesThat looks like what I want, though, what I've written seems to be readable
04:15TEttingercool, it's an odd name for sure
04:16TEttingerindeed.
04:16TEttingeris performance a concern at all?
04:18craftybonesNot yet, but if it were, I'd just use a map
04:18TEttingerI would think storing two vectors, one already reversed, would avoid a slight amount of overhead from rseq (which is not slow compared to reverse, so that's something) and converting back to vec in next-heading
04:18TEttingerbut that really only matters if calling this a ton
04:18craftybones@TEttinger that's cool too
04:18TEttingerI see directions and i think of functions that get called a lot, from a game programming angle
04:19craftybonesYeah, hopefully, eventually. As of now, its just katas :)
04:19TEttingerah cool
04:19craftybonesBtw, what's a canonical way to test wrt assertions/test? Do you have a deftest that has one large case with each "testing" having more than one assertions?
04:21roelofhello, for checking if I use good clojure code can I better use kibit or eastwood ?
04:22TEttingercraftybones: I would imagine you would have multiple deftests if you have multiple things that could fail, but I haven't written any tests in clojure
04:23TEttingerroelof: I think the dev of eastwood is in here.
04:24TEttingerah, roelof they can be used together
04:24roelofTEttinger: oke, I know kibit could find thinks like this (= ( + a b) 0) that could be better (zero? (+ a b))
04:24roelofoke, I do a github course and I like to know if im on the right track
04:25craftybones@TEttinger - hee hee. Sorry, the test thing...its just been sort of drummed into me to do it.
04:25TEttingerI need to get used to it too
04:25roelofTEttinger: who is the dev of eastwood then ?
04:26TEttingerI was incorrect, I think I mixed up a contributor with the primary dev. and there's a lot of contributors
04:26roelofNP
04:26TEttingerI would guess since the URL of eastwood has jonase in it and that is what someone's nick starts with here... not to nick-alert if it's night-time or work-time...
04:27roelofthen the next task is to find out how to add the two to this : http://lpaste.net/141813
04:27roelofoke
04:28roelofhere it is morning time : 10:39 hour
04:28TEttingerhttps://github.com/jonase/eastwood#installation--quick-usage
04:28TEttingerwhile you have your profile open, https://github.com/jonase/kibit#usage
04:29roelofoke, I could just past these two after the profiles ?
04:29TEttingerlet me check mine
04:30TEttingerit should be inside the map
04:30TEttingerthe whole of profiles.clj should be a single {} map
04:32TEttingerif it specifies to put it in plugins, plugins is a vector of vectors [[foo "foo"] [bar "bar"]] containing pairs like that
04:33roelofI have now this : http://lpaste.net/141814 but it fails with this message : aused by: java.lang.IllegalArgumentException: No value supplied for key: {:user {:plugins [[jonase/eastwood "0.2.1"] [lein-kibit "0.1.2"]]}}
04:35TEttingeroh, I'm not sure it works with the profiles in a project.clj
04:35TEttingerit's a plugin for lein, both of them are
04:36TEttingerthe instructions here tell you where to go https://github.com/jonase/eastwood#installation--quick-usage
04:38roelofTEttinger: I thought I did what the instructions said :(
04:39TEttingerprofiles.clj is a file in a subdirectory of your user directory, ~/.lein/profiles.clj
04:40craftybonesHave you guys heard of this neat tool called pathpicker?
04:41craftybonesJust started using it. Really cool and convenient. Lets you parse files out of arbitrary text output and then perform tasks on them
04:41TEttingerwoah
04:46expezAnyone seen file-seq produce results like "/home/expez/the/root/~/the/root/src/some.ns/file.clj"?
04:46expezIt's 99% correct, but I get a few files with screwed up paths like that
04:49neurostormWhats the library to use for dom manipulation and dom element creation? Dommy + Hipo?
05:11muhukexpez: strange. I also use linux, I get good results when I do (file-seq (file "/home/muhuk"))
05:12muhukexpez: could it be symlinks
05:12expezmuhuk: I have 73 files and 3 paths that are messed up
05:12expezmuhuk: nope
05:12expez"/home/expez/git/refactor-nrepl/~/git/refactor-nrepl/src/refactor_nrepl/rename_file_or_dir.clj/find_symbol.clj"
05:13muhukexpez: yeah, I've just checked symlinks work fine.
05:13expezthis path is the combination of two others, but the two other files are additionally listed correctly
05:13expezI figured I would just filter with .exists, but that returns true on those files!
05:13muhukexpez: what path are you using? how do you build it?
05:13expez"/home/expez/git/refactor-nrepl"
05:14muhukso you don't combine File's etc.
05:14muhukyou just pass that str as the root path?
05:14expezI inspected the output of the file-seq and I couldn't spot the problem, but I might've missed it looking at thousands of entires
05:15expezmuhuk: no I pass that to the java.io.File constructor (or it would obv blow up)
05:15ionthasls
05:15expez(.endsWith (.getPath (io/file path-or-file)) ".clj") <= this is the filter I use on the file-seq which seems to be side-effecting, somehow?
05:15muhukexpez: that's what I meant.
05:16ionthas(ups, sorry about that)
05:16muhukexpez: what side-effect?
05:17muhukexpez: actually why don't you paste your code somewhere
05:20expezmuhuk: https://gist.github.com/expez/a055c5296aaccd52ffaa
05:22muhukexpez: well written code
05:22expezmuhuk: you can even clone the repo if you want to get the exact same output https://github.com/clojure-emacs/refactor-nrepl
05:22muhukexpez: file-seq returns a seq of files, so you probably shouldn't wrap them with io/file, no?
05:23expezio/file on a File is a no-op
05:23expezacts like identity
05:23muhukexpez: just for fun, try without wrapping it again
05:23muhukcould be the cause of weirdness denormalization
05:23expezyeah, I did try that, when I got real desperate :p
05:24muhukno cigar eh?
05:25expeznope
05:26muhukexpez: sorry I can only think of less than semi-useful stuff at this point
05:26expezmuhuk: could you try cloning the repo and see if you get the same result?
05:26muhukif you figure it out let me know though I'm curious
05:26muhukok let me try
05:26expezIf I'm the only affected user then this isn't *that* serious a bug
05:27expezIt might also be limited to my computer on this project :)
05:32muhukexpez: I wrote the clj-file fn, tried with it
05:32muhukI get good paths
05:32xtrntri'm having trouble understanding this piece of code
05:32expezmuhuk: thanks for checking, then I'm going to worry about this until someone else experiences similar issues
05:33xtrntr(swap! state (fn [curr] (update-canvas curr surface) (-> curr .. .. ..)))
05:33muhukexpez: 69 results returned
05:33muhukxtrntr: which part of that code is confusing for you?
05:35xtrntri suppose the first thing is swap! returns some kind of value
05:35xtrntrbut i don't see how it's being used in the function
05:36expezxtrntr: swap! is side-effecting, it's only used to change the value held by the atom named "state"
05:36muhukxtrntr: swap!'s return value is not really its thing. You should perhaps read on it first.
05:37xtrntrside-effecting?
05:37xtrntrthe docs aren't clearing up anything for me sorry
05:37justin_smithmuhuk: the return value of swap! is the new value of the atom
05:37muhukxtrntr: if update-canvas is side effecting, this is not good code (unless it's clojurescript)
05:37xtrntrit is clojurescript yeah..
05:37muhukjustin_smith: I didn't say it's not, why are you telling me this?
05:38justin_smith"swap!'s return value is not really its thing" - the changed value of the atom (which is what it returns) is it's main thing
05:38muhukxtrntr: then just think of swap! as a set operation (instead of a compare-and-set operation)
05:39muhukxtrntr: side-effecting means it has side effects, like printig/logging something or changing DOM.
05:41xtrntrokay, i think i understand the rest
05:41expezmuhuk: I figured it out. I actually have a dir called ~/ in my refactor-nrepl directory after working on the rename-file-or-dir refactoring a while back. *face palm*
05:41xtrntrso the end result of this swap! is a new state value
05:41xtrntrand before you do it you call update-canvas
05:41xtrntrthen call tick-ball
05:41xtrntrthen pass the result of tick-ball to handle-brick-collision and vice versa for handle-paddle-collision (the -> thingy)
05:42muhukexpez: cool
05:42xtrntrso this function changes the value of state?
05:42xtrntrwhy do you say it's not code unless its clojurescript though?
05:43muhukxtrntr: it's not good code unless it's cljs
05:43xtrntri suppose i've been confused all the while where the state was being held, and it's updated through some kind of timer
05:43xtrntrthe function is essentially one big set! operation
05:43muhukxtrntr: because JavaScript is single-threaded, so there will be no retries
05:43xtrntrno retries?
05:44muhukxtrntr: Clojure is multi-threaded, so more than one thread might be trying to swap! the same atom
05:44muhukxtrntr: one of them wins, the rest will re-try, re running their function
05:44muhukxtrntr: with the current result of the winning thread
05:45xtrntrwhat would that code look like if it weren't written for single threading?
05:45xtrntri'm curious what this re-try would look like in code
05:45muhukxtrntr: you woudn't have update-canvas in your fn
05:45muhukxtrntr: ok, it might be idempotent, but suppose it isn't
05:46muhukxtrntr: in multi-threaded env, first swap! wins, having called update-canvas
05:46muhukxtrntr: second thread calls update-canvas twice, because it re-tried
05:46muhukxtrntr: makes sense?
05:46justin_smithmuhuk: first does not win - the only one that did not see a concurrent change (that is, the last of the overlapping calls, if there were any overlaps) wins
05:47justin_smithwell maybe not even the last actually
05:47justin_smithit's very possible for none to win (or more than one) depending on how the calls line up
05:49xtrntrahh
05:49xtrntri don't understand really
05:49xtrntrmaybe i can come back to this later
05:50justin_smithxtrntr: atoms don't lock - they check the value, run the function you pass to swap, then only if the value has not changed since you started running the function do they commit the result
05:50justin_smithxtrntr: they retry if any changes occur while they are calculating
05:51xtrntri think i understand that, but i gotta see the code for that first
05:51muhukjustin_smith: please don't tag me. I'm not interested in your bikeshedding.
05:51xtrntrand i've never written applications that call for this kind of thing yet so far
05:52muhukxtrntr: rule of thumb is; don't have side effects in the function you pass to swap!.
05:52muhukxtrntr: also see https://clojuredocs.org/clojure.core/io!
05:52xtrntri think update-canvas has side-effects
05:52xtrntrit's just redrawing the whole game state
05:53xtrntris that okay?
05:55muhukxtrntr: kinda subjective. Some would say it's OK if it's cljs. I would still not have that there.
05:55muhukxtrntr: I use reset! a lot more in clojurescript for this particular reason. reset! is honest.
05:57xtrntrokay :)
05:57xtrntri was planning to program some graphical stuff
05:57xtrntrseems like it'll be a bit tricky
05:57xtrntrto do it clojure style
05:58xtrntrwhat kind of fun stuff is clojure good at?
05:59muhukxtrntr: all kinds of stuff, once you get the hang of it
05:59muhukkeep working on graphics stuff I say
05:59muhukmore gratifying than most stuff IMO
06:00xtrntri did it imperative style in racket
06:55thiagofm12:55 *** NAMES @ChanServ [Neurotic] _alejandr0 _ato `brian aaron7 abh adamhill adammh addisonj adereth AeroNotix ahoegh__ AimHere akhudek akilism akkad akurilin alchemis7 alexbaranosky alexyakushev algernon Alina-malina alisdair amalloy amano- ambrosebs Amun_Ra ananthakumaran andereld andrewstewart andreypopp ane anekos anon-5660 Answrguy_ anti-freeze aperiodic apetresc arkh arnihermann arpunk arrdem arrubin ashnur
06:55thiagofm Atlanis atomi auganov augustl avdi averell AWizzArd awwaiid babilen bacon1989 bailon bakedb ballingt Balveda basteni bdruth bencryption benizi beppu bg451 bhagany bigs Biohazard bja bjeanes bkamphaus blake_ blkcat Blkt bobpoekert bobth__ bobwilliams bodie_ bogdanteleaga boodle borkdude bourbon boyscared boztek|afk bracki brandonkl brianwong brixen brokenstring Bronsa broquaint bru bruceadams btobolaski budai cantsi
06:55thiagofmn carc cartwright cataska cespare cfleming cfloare cgfbee charliekilo chavezgu chenglou ChiralSym choas ChongLi chouser-log Chousuke chrchr chriswk cichli clojurebot cmbntr_ cmiles74 codefinger codelahoma coffeejunk cojy CookedGryphon cprice404 Cr8 craftybones crodjer cross cursork CVTJNII cYmen cyraxjoe d4gg4d d_run daemian dakrone dalecooper30 danlarkin danlentz danlucraft danneu danvet danzilio dean demophoon den
06:55thiagofme14 Deraen DerGuteMoritz devn devsda dhruvasagar dhtns Diabolik dignati_ dillap diyfupeco dj_ryan djcoin dkua dm3 dnolen doctorinserenity dogonthehorizon dominiclobue_ DomKM donbonifacio dopamean_ Draggor dsantiago dsp_ dubitae Duke- dukeraoul dustinm dxlr8r dylanp dysfun dzimmerman eagleflo ecelis edoloughlin_ eduaquiles egli egogiraffe ekroon ellinokon emdashcomma emperorcezar Empperi EnergyCoffee engblom eno789 e
06:55thiagofmoinh ephemeron erdic ericbmerritt eriktjacobsen Ethan- euphoriaa evilthomas evoqd Excureo expez f10w3r5 f3ew Fare farhaven felher felipedvorak felixn fikusz firstdayonthejob fluchtreflex folker Foxboron franco franklnrs futuro fuziontech gabrbedd galaux gcommer georgej162 gf3 gfredericks ggherdov ggreer ghjibwer gienah gigetoo gilliard GivenToCode gko gozala grandy gratimax gregf_ greghendershott grim_radical groot
06:55thiagofmGuest18627 Guest38454 guilleiguaran__ gws H4ns hadronzoo hakvroot halorgium HDurer HDurer_ henrytill herrwolfe heurist hipertracker hiredman hive-mind honkfestival honza hsaliak hugod hyPiRion iamdustan ibdknox icedp idnar ieure ikitommi_ imanc infinite1tate inoperable insamniac ionthas itruslove ivan\ j0ni J_Arcane jaaqo jackhill jackjames jamiei janne jasalt_ jaster jave jayne jba_ jconnolly jcromartie jcsims jdag
06:55thiagofmgett jeadre jeaye jeregrine jeremyheiler jet jetlagmk2 jez0990_ jfojtl jgdavey jgmize|strngloop jimrthy_away jinks_ jjmojojjmojo jjttjj jkni jkogut jkogut_gs jlewis jlf jlf` jlouis jlpeters jlyndon jmolet jodaro joeytwiddle jonasen jonathanchu jonathanj jonathanj_ joshskidmore jrdnull jsime JStoker juancate Juhani julienXX justin_smith justinmcp justizin jweiss kandinski karls katratxo keen__________ keifer ken_barb
06:55thiagofmer kenrestivo kephale kitallis klobucar Klumben kmicu Kneiva kraft Kruppe kungi kwmiebach kylo l1x l2x lachenmayer lambdahands lancepantz larme laxask LBRapid ldcn lea leftylink leifw lenstr Leonidas leptonix lfranchi Licenser littleli LnL lnostdal lobotomy lodin_ lokydor Lollypop lotia low-profile lpaste Lugoues LukeWinikates___ luma LuminousMonkey luxbock Luyt_ lvh lwlvlpl lyddonb lzhang m00nlight m1dnight_ m_3 ma
06:55thiagofmchty madscientist_ magnars mahnve maio majoh makufiru malyn Mandus manytrees marce808 mariorz markmarkmark marshzor martinklepsch martintrojer marvi MasseR matt_c matt_d matthavener mattrepl maxmartin mccraig mcktrtl mdeboard meandi_2 mearnsh Meeh Mendor|scr merlinsbrain metadaddy mfikes mgaare michaniskin michel_slm mihaelkonjevic_ mikolalysenko mindCrime misv mlb- mmikeym Mongey moop moquist Morgawr MPNussbaum mrb
06:55thiagofm_bk_ mrLite mrowe_away msassak mtd mtdowling Mugatu muhuk mungojelly MVPhelp myguidingstar mysamdog n1ftyn8_ n8a naga` nano- narendraj9 Natch nathanic nberger ndrst necronian neektza neena newgnus nexysno NhanH nickenchuggets nickmbailey nighty-_ nighty^ nilern_ ninjudd nlew noidi nomiskatz_ noncom noplamodo nseger nsuke nulpunkt numberten nw nzyuzin Ober ocharles__ octane-- oddcully OdinOdin omarkj onthestairs opqd
06:55thiagofmonut ordnungswidrig oskarth osnr owenb_____ owengalenjones oyvinrob ozzloy p_l paulweb515 pcn pepijndevos perplexa perrier philth_ piippo pisketti pjstadig pkug pleiosaur pmbauer povilas preyalone psy_ Pupnik_ puredanger puzza007 pwzoii pydave6367 pyon qz r0kc4t r4vi ragge Ragnor raifthenerd randy_ RandyT_ rapzzard^cloud rasmusto Ravana Raynes Raynos raywillig RazorX razum2um razzledazzle rberdeen rboyd rdema reiddr
06:55thiagofmaper retrogradeorbit rfv rigalo_ rinwa__ riotonthebay rippy rivarun rj-code rjknight rlb rlr robink robotmayo rotty rowth rpaulo rs0 rtl rufoa rweir ryanf s0lder safety saltsa sarlalian saurik scgilardi schwap Scorchin scpike_ scriptor sduckett seabre seako seangrove SegFaultAX segmond sephiap septomin seubert Shambles_ sharkz Shayanjm shaym_ shem shiranaihito SHODAN shoky si14 sickill silven sirtaj sivoais sjl__ sk
06:55thiagofma-fan skrblr sleezd snakeMan64 snits Snurppa sobel socksy sohum solvip someone someplace soncodi Sorella sorenmacbeth spacepluk Speed spicyj splunk spoofednoob srcerer sross07 ssideris stain stardiviner stasku StatusQuotidian stevenleeg StevePotayTeo stian surtn sw1nn taij33n talvdav_ tarcwynne_ tazjin tbatchelli tclamb tcrawley-away tcrayford____ tdammers TDJACR tekacs telex tempredirect terjesb terom TEttinger2 th
06:55thiagofme-kenny thearthur thecontrarian42 ThePhoeron thesquib thiagofm threeve_ TimMc timvisher TMA tmarble tmciver tokik tomaw tombooth tomjack tomku tomphp tonini torgeir ToxicFrog tpope Trieste Trioxin Tristam Tritlo troydm truemped tschimmi42 Tuna-Fish turbofail tuxlax tvaalen twem2 Uakh uber ubuntu3 vandemar varioust vedwin vendethiel Viesti vilmibm vishesh visof visof_ voidlily waamaral wamaral wang wasamasa whee whoo
06:56diyfupecothiagofm: …
06:56thiagofmsorry.
06:56Alina-malinaho nigga pleaseeee
06:56diyfupecothiagofm: Let me guess, emacs?
06:56thiagofmyes, emacs
06:56scriptorbeen there
06:56farhaventhat's... happening a lot lately
06:56thiagofmso, what do I do? :(
06:56jeaye-_-
06:56diyfupecoLearn to control your editor.
06:57thiagofmam I going to get banned?
06:57thiagofm:D
06:57Uakhfuck the police
06:57diyfupecoUakh: But only the cute ones! :P
06:57muhukwhat is causing this?
06:57muhukI don't use emacs
06:57Bronsathiagofm: consider using a client with flood protection
06:58thiagofmBronsa: really regretting going rcirc by a suggestion of a friend
06:58Bronsaif you want to keep using emacs, erc is built-in and has that facility
06:58Bronsautility*
06:59Bronsathiagofm: and no you won't get banned
07:01diyfupecomuhuk: Basically a function which lists all users and gets written into the message buffer somehow.
07:02muhukdiyfupeco: got it. Sounds innocent. Thanks for the info.
07:33leftylinkI don't usually see this happen, maybe I don't hang around in channels with emacs users often enough...
07:34hellofunkdoes anyone know how Heroku knows which project.clj profile to use when you deploy there? I can't find docs about how to name and specify the profile
08:03trisswhats the simplest way of getting a temporary file *path*.... I'd like a file name rather than a java File returned.
08:03triss?
08:06trisshang on i don't need it!
08:06trisssplendid. spit works with files
08:25roelofAnyone who can help here ? https://www.reddit.com/r/Clojure/comments/3mk6n1/how_to_add_the_plugins_in_this_projectcli/
08:35anehow did he manage that nick thing
08:35aneis it some feature of erc or something
08:46roelofno body who can help me with my little problem
08:47mysamdogroelof: just add the {:user} bit under :profiles
08:47oddcullyroelof: https://github.com/technomancy/leiningen/blob/stable/sample.project.clj
08:48oddcullyroelof: or you put that {:user...} thingy in your ~/.lein/profiles.clj
08:50roelofoke, and if I look at the sample I need to use :user and not { :user }
08:54roelofmysamdog: oddcully thanks, this (http://lpaste.net/532544041686925312) seems to be done the job
08:59roelofI use this to check if a number is negative (neg? x) kibit is allright with it but eastwood is saying this : rc/i_am_a_horse_in_the_land_of_booleans.clj:10:3: unused-ret-vals: Pure static method call return value is discarded: (. clojure.lang.Numbers (clojure.core/isNeg x))
08:59roelofdo I have a problem in my code or not ?
08:59Bronsaroelof: looks like you're not using the return value of neg?
09:00Bronsawhich usually means you have a bug in your code
09:00roelofI think I do . Here is the code : http://lpaste.net/141822 . I try to make a absolute value
09:01Bronsaroelof: there's no if there
09:01roelofoke, so I need the if. Wierd that midje and kibit did not found it.
09:02Bronsaneither midje nor kibit are linters
09:03roelofoke, but midje schould find it because i assume that the function will produce wrong output
09:04Bronsaif you wrote a reasonable test for it, sure
09:04Bronsathat function as you wrote it is just identity
09:05roelofBronsa : I did not write the test. This is a clojure course I found on github from the University of Helsinki
09:07roelofnice to see that eastwood also do a lein midje
09:09roelofWith the help of eastwood and kibit I could solve a lot of exercises :)
09:15roelofone last question : if I make a function and then a function that the opposite of the first one. Is it allright to use not or can I better use another function
09:15craftybonesI've a destructuring question
09:15roelofcraftybones: shoot
09:16craftybonesI want to destructure [0 0 :N] as {:co-ord [0 0] :heading :N}
09:16roelofthat possible
09:17craftybonesI can do it the long way by [[x y] :as co-ord h :as heading] and then return it individually
09:17craftybonesis there a terse way of saying it?
09:18roelofI do not know . I only know the long way
09:19roelofI hope Bronsa or oddcully can help you
09:24craftybonesEnded up writing it as follows
09:24craftybones(defn position [x y h] {:co-ord [x y] :heading h})
09:26muhukcraftybones: you can also use core.match for that. It'd move the logic of deconstruction closer to where you use it. Either way is fine, you decide.
09:26muhukroelof: a function that is opposite of another function is vague. If your fn return a boolean value, not is the way to go.
09:34craftybonesIs there a way to destructure all keys of a map into corresponding variable names?
09:34craftybonesLike so
09:35craftybones(let [{:keys _} {:x 1 :y 2}] x) ?
09:38AimHereWell you can pull the symbols out using 'name' and 'symbol'. I think you might need a macro to bind them to the values again
09:39AimHere,(map symbol (map name (keys {:x 1 :y 2 :z "wibble"})))
09:39clojurebot(x y z)
09:39muhukcraftybones: via macros maybe. I wouldn't want to do that though. Too much magic.
09:39craftybones@muhuk that's right
09:39craftybonesI stuck to making it more readable
09:39craftybonesthanks
09:39muhukyw
10:12roelofmuhuk: thanks, some people say I schould use complement
10:13roelofits about a function that returns true or false
10:19reutermjHow do you create a record and inherit from an abstract class?
10:22Bronsayou can't
10:23reutermjdarn, does that mean I have to use java and just instantiate the java class?
10:28roeloflast challenge. making a leap year function using and/or
10:35roelofI have this code : http://lpaste.net/141825 and see this warning : test/i_am_a_horse_in_the_land_of_booleans_test.clj:2:9: unlimited-use: Unlimited use of (iloveponies.tests.i-am-a-horse-in-the-land-of-booleans) in i-am-a-horse-in-the-land-of-booleans-test
10:35roelofwhat does it mean
10:43roelofhere are the tests : https://github.com/iloveponies/i-am-a-horse-in-the-land-of-booleans-tests/blob/master/src/iloveponies/tests/i_am_a_horse_in_the_land_of_booleans.clj
10:47muhukroelof: they are right, (complement f) is better than (comp not f) & #(not (apply f %&)) etc.
10:48roelofmuhuk: oke, then I will change this (not(teen? age))) to (complement (teen? age))
10:49muhukroelof: well not is good there, but (defn opposite-of-f (complement f))
10:50muhukroelof: (not (teen? age)) is better than ((complement teen?) age)
10:50roelofoke, then I will it this way
10:50muhukroelof: not operates on a value, returns a value. complement takes a fn & returns a fn
10:50roelofmuhuk: thanks for the explanation
10:50muhukyw
10:51roelofNow I hope someone can help me with my eastwood warning
10:54muhukroelof: your paste doesn't make sense to me
10:54muhukleap-year?
10:57muhukroelof: ok, it makes sense now. Can't do much about unlimited-use there, it originates from the tests.
10:57muhukroelof: I would exclude tests from eastwood.
10:59roelofmuhuk: oke, how can I do that ?
11:01muhukroelof: are you familiar with leiningen?
11:02roelofa liitle bit . Im just learning clojure by following the online course from the University of Helsinki
11:03muhukroelof: ok, you can go to eastwood's github and it should be documented in the readme.
11:03muhukbasically you'll change something in project.clj
11:03zxcHello! Can somebody teach me Clojure and web stuff, please?
11:03roelofcorrect . found already in the readme
11:06muhukHe said "please". C'mon!
11:07mzdravkovwhat is a simple way to implement rand-nth but with non-uniform chance to pick an element?
11:08muhukmzdravkov: test.check frequencies does a similar thing, but I'm not sure if it's the simplest.
11:08muhukmzdravkov: can you re-map your distribution to [0.0, 1.0) ?
11:09mzdravkovif I have [a b c] and a has 70% chance, b 20% and c 10% I can put them like ranges side by side: a [0;70), b [70;90), c [90; 100] and then pick a (rand 100) and check in which range it is, but this seems too complicated
11:10mzdravkovmuhuk: yes, I'll check it out. Thanks
11:10zxcmuhuk: I like you
11:11muhukmzdravkov: what I meant by mapping was a bit different
11:12muhuk(f 0.33) -> 0.7, (f 0.67) -> 0.9, (f 1.0) -> 1.0
11:12muhukwell my numbers are probably wrong, but I think you get the idea, fitting a function.
11:13roelofpity , according to the manual it cannot be supressed and this (lein eastwood "{ exclude-linters[:unlimited-use] }" does also not work
11:16roeloffound it, make a typo : this one is working : ein eastwood "{ :exclude-linters[:unlimited-use] }"
11:16roelofso this chapter is ready ":)
11:17roelofzxc: what do you think of this course : http://iloveponies.github.io/120-hour-epic-sax-marathon/
11:18roelofIm doing it myself
11:22zxcroelof: I was doing brave clojure some time ago, but found it boring
11:22zxctoo many unnecessary words
11:22wasamasabrave people enjoy all the words
11:23roelofI know that brave is rewritten and in a few weeks a new edition is out and a new website
11:23roelofmaybe doing the same course till there is a new version of brave
11:23zxcit was fun to read, but not fun when I had like 30min of free time and unable to learn anything, because of jokes
11:23zxc(busy college student)
11:25zxcroelof: It seems nice, also real life programs are interesting
11:25zxcroelof: I'll definitely read that
11:37roelofwhy this error
11:37roelofxception Unsupported binding form: (get v 0) on this code :http://lpaste.net/141828
11:40oddcullyroelof: isnt just (let [[f _ t] v] ...)?
11:40oddcullyif you want the (get) there, then remove one layer of [], since this is no destructuring then
11:41roelofin the explanation is this stated : (get ["a" "b" "c"] 1) ;=> "b"
11:42oddcullyyes, so either go (let [x (get ...)]) or destructure
11:42oddcullyyour are mixing things, therefor the error
11:43roelofodd , if I do it this way : http://lpaste.net/141829 thirt_number cannot be resolved
11:44roelofor do I misunderstood you
11:44oddcullyno, but you removed the wrong layer of [] (the outer one
11:44oddcully)
11:45oddcullyits (let [x (get) y (get)])
11:45roelofsorry, I will hit the books to see what it must be
11:46oddcullythe grimoire has lots and lots of examples: http://conj.io/store/v1/org.clojure/clojure/1.7.0/clj/clojure.core/let/
11:46roelofpff, finally working. Sometimes the [ and () are making me grazy
11:52roelofThanks all. I call it a day. Its time for dinner and watching tv
12:03Trioxinwhy everybody's name get mentioned all the time in here?
12:04Trioxinthankfully I don't do business on IRC really so I don
12:04Trioxindon't have it set to wake me up
12:09roelofmy name is also not always here.
12:09roelofVery very last question : Is clojure web essentials a good book to learn making web sites with clojure
12:11muhukroelof: not if you know you web programming generally
12:12muhukroelof: web frameworks are generally well documented compared to other stuff (I wonder why ;) )
12:13roelofmuhuk: do you have a better recommendation then ?
12:13roelofI only know a little html and css
12:13roelofBRB Dinner
12:14muhukroelof: then reading a book is a good idea.
12:32roelofmuhuk: thanks, I was also looking at web development with clojure but that seems you have to use light table so a no-go for me.
12:32roelofIm using a cloud enviroment which has his own ide
12:32rhg135You don't have to
12:33rhg135I use vim
12:33rhg135But any editor works
12:35roelofI know. But in the first chapters I have to change namespaces to make the tables in the database and nowhere a explantion how to do that
12:36rhg135(in-ns 'my.db.ns)
12:36rhg135In a repl
12:37roelofI tried that but I could not call a function in that namespace. I have asked for help on the google group but no one could help me then
12:39rhg135Is this cljs? If so you should try #clojurescript. I failed :-(
12:42seakodid you call the function with the namespace prefix like (my.db.ns/your-function) or did you call (your-function)
12:45rhg135Actually, that sounds like the ns isn't loaded. As clj will let you switch to an uninitialized one.
12:47roelofseako: I did (your-function) like the book said
12:48roelofrhg135: I think that was the problem. I was not loading the right one but a empty one
12:49rhg135Yeah, that got me too at first
12:50roelofthen I gave up and continued learning clojure with the help of a github course
12:57mungojellywe have it set up so there's some web front ends where you can run a little clojure but that's understood to be just "trying" it out and then to be "really" using it you have to have what is from an ordinary perspective quite a lot of skill in system administration
12:58mungojellythere should be a front end on the web that's considered legitimate and real and given some power because that's how most people have access at the moment
13:11roelof mungojelly what do you then use for your web site ?
13:12roelofrhg135: how to solve the problem of loading a empty ns instead of the right one
13:32noncom|2how do i verify a token generated in buddy?
13:43roelof no one who can recommend a book / tutorial for making web sites'with clojure and maybe Selmer ?
13:43rhg135Roelof: require
13:43roelofrgh: ???
13:45rhg135You should require it before switching. Or better yet require then alias it
13:45rhg135,(doc alias)
13:45clojurebot"([alias namespace-sym]); Add an alias in the current namespace to another namespace. Arguments are two symbols: the alias to be used, and the symbolic name of the target namespace. Use :as in the ns macro in preference to calling this directly."
13:48roelofmoment, Im in the user namespace and I need to goto this namespace (ns guestbook.models.db and carry out this function sql/create-table
13:49roelofI can do (ns-in 'guestbook.models.db) but then the create-table cannot be found
13:50roelofrhg135: how to solve this with require ??
13:50rhg135(require 'guestbook.models.db)
13:51rhg135Before in-ns
13:52roelofrhg135: So first (require 'guestbook.models.db) then (ns-in 'guestbook.models.db) and then I can use (create-table)
13:52roelofDo I understand you right ?
13:53rhg135in-ns, not ns-in. Correct.
13:55roelofoke, thanks for the lessons. Now I can also use the web development with clojure and not using a framework :)
13:56rhg135Np
13:57roelofI like the clojure community . Always someone who is willing to help a beginner and teach a beginner something
13:58rhg135Yup, very nice compared to the last language I used
14:05TrioxinIs the performance really slower in clojure than java?
14:05Trioxinor as much as it maybe used to be?
14:05Trioxini was reading some ppl say that
14:06rhg135Higher level tends to be, even in java
14:07Trioxinwhat I would love is to use clojure with matlab. I know my matlab can spit out java
14:08rhg135Passing around lists instead of arrays in java would be slower for example
14:09Trioxinmatlab has the whole built in nvidia processing and distributed/parallel computing engines going for it
14:09Trioxinfor my machine learning algos
14:09roelofrhg135: what is then the last one ? for me I tried erlang
14:10rhg135I'm sorry, what was that?
14:10TrioxinI should be able to work with this in clojure pretty easy right? http://www.mathworks.com/products/matlab-compiler-sdk/
14:11roelofI give a question to your respons on 19:58 Yup, very nice compared to the last language I used
14:12rhg135Trioxin, you should, but I've never tried
14:12gfredericksamalloy_: is hacking 4clojure to use an atom instead of mongo as tediously difficult as I think it might be?
14:13rhg135Roelof, I used python. It felt as if I was alone.
14:14roelofoke, I tried to used erlang But I get lost in pattern matching everything
14:14Trioxini just started using py. it's ezness so far
14:14Trioxinnot the kind of different things I have to get used with clojure
14:15rhg135I just didn't improve much since no help
14:15Trioxinwhat's that site uhm.. rosettacode. you can clearly see clojure being far less code than java and most others
14:15engblomPattern matching is actually one thing I like really much in Haskell.
14:16rhg135Here otoh, I can at least get another pair of eyes on my buggy code :-P
14:18Trioxini have to go java.lang.exception. meh. I'm guessing I could shorten that
14:18roelofengblom: I tried Haskell but could not find any good beginners book which prepares me for CIS194 and NICTA
14:18rhg135java.lang.* is autoimported.
14:19Trioxincould I create an alias as just Exception?
14:19rhg135Just Exception by default, but yes
14:19Trioxinwell, I do see cond, throw
14:20rhg135,(doc import)
14:20clojurebot"([& import-symbols-or-lists]); import-list => (package-symbol class-name-symbols*) For each name in class-name-symbols, adds a mapping from name to the class named by package.name to the current namespace. Use :import in the ns macro in preference to calling this directly."
14:20engblomI find Haskell to be a nice language itself, but the tools and libraries around it quite bad. The "equivalent" of lein for Haskell is cabal, and half of the time cabal will fail with installing dependencies
14:20Trioxini hears hickley speaking much ill of haskell
14:21Bronsawhere?
14:21clojurebotwhere is amalloy to explain it
14:21rhg135,(do (import 'java.util.UUID) (UUID/randomUUID))
14:21clojurebot#uuid "555c09fb-44a5-4703-9ef8-0a045d873f17"
14:21Trioxinin a video, well basically poking fun saying raise your hands if you code haskell; I feel sorry for you
14:23rhg135,Exception
14:23clojurebotjava.lang.Exception
14:25engblomTrioxin: That is lowering my opinion about Hickley. He should not mock people, that is not how you win people for your project.
14:26Trioxinhe was just joking
14:26mungojellythe mocking of haskell is some gentle ribbing between equals, it's the mocking of java where he gets actually sour, but i think it's fair
14:27mungojellyjava is awful not because of sincere innocent errors but in a giant conspiracy to conquer things and make money so fuck that
14:28mungojellyi want to learn haskell just so i can understand if there's actually a point to that syntax or if we should have strong typing and pure functions and also a readable syntax too, if there's some reason we can't have everything i don't understand it
14:28rhg135The error would be no nice data structures
14:28rhg135That's always what I miss most
14:29mungojellythe jvm was designed to make it difficult to compile other languages to it. and indeed clojure's construction was tremendously difficult. any sort of coherent rich anything would defeat that purpose of being uninteroperable.
14:30rhg135Eh, it's not that bad I think
14:31Bronsamungojelly: mapping clojure to jvm bytecode is not that difficult actually
14:31mungojellywell it depends on how you look at it. from their perspective they were putting a bunch of money into developing it so of course they didn't want to make it easy to plug in your language of choice and let everyone run away with it.
14:31rhg135There's a lot of jvm languages
14:31Bronsaand there have been efforts for years to make the jvm suitable for other languages
14:32mungojellyyes but there was absolutely no reason except profit that it was ever difficult at all in the first place.
14:32engblomI really wish Clojure would have picked another platform than jvm. You could never write a tool meant to be repeatly run from scripts, like 'sed' in clojure as it is too slow in starting up.
14:32rhg135Compilers are never easy to write
14:32mungojellyengblom: have you tried drip? i tried it out yesterday, it works great. it just spins up a spare jvm so one's ready instantly when you need it.
14:33rhg135Check out gcc
14:33gfredericksmungojelly: I feel like the fact that the bytecode spec existed so early at all means they were trying quite hard to make it suitable for other languages
14:35Bronsamungojelly: the jvm was designed for java. it's only natural that mapping an other language on top of its bytecode might require some workarounds
14:35mungojellyyou can say it's reasonable somehow that they were trying to make a virtual machine strongly tied to a single language but it's odd to say that's not what they were doing. that was the whole idea.
14:35rhg135I should write a shell in clojure.
14:36rhg135That way it'd just be calling functions for scripting
14:36Bronsamungojelly: that's exactly what they were doing. but you made the jump from that to "they were actively trying to design it so that it would be difficult to write another language on top of it" and that's a non sequitur
14:36l3dxI'm trying to use cljs-ajax to POST a FormData object, but I can't figure out what I'm doing wrong. When inspecting the request in devtools I can't see anything from the formdata. Anyone done this before?
14:38rhg135I suppose that would just be a repl with a slightly modified reader
14:39mungojellyrhg135: why do you have to modify the reader? i'd think you'd just need to use a library with some good file system functions
14:40rhg135Easy syntax sugar to call executables
14:40mungojellyi'd be happy with (ex "./file") i think
14:41engblommungojelly: I got curious about drip and tried it. Still very slow. The only thing drip improves is booting java itself, not the booting of clojure.
14:41rhg135Needs to rewrite stuff like 'vim' to (ex "vim")
14:42rhg135Laziness
14:42rhg135It's 6 more characters
14:43mungojellyi think a way that would make sense to script with clojure is to write some clojure that compiles into a script in whatever fast booting language
14:43mungojellyhmm well you could write (vim)
14:43rhg135Then I'd have to extend the evaluator
14:44rhg135And 2 more
14:44mungojellyparentheses are extra to type, you say? but that's not a general rule is it? ;)
14:45rhg135I could use post fix, but meh
14:45rhg135I like parens
14:46rhg135Mungojelly, that's cljs
14:47rhg135Node starts fast
15:06mungojellychanging the reader and the representation and everything just to save keypresses seems extreme, how about just if you typed "vim" and then pressed a key that wraps it in (shellpackage.stuff/execute "vim") and runs it
15:11mzdravkovI am trying to write a macro that generates patterns for core.match. I'll try to explain with an example: Suppose I want to test if this [[:a :b :a :b]] matches to one of [:a :b & r], [_ :a :b & r] or [_ _ :a :b & r]. Here are two mathes. Here is my code: https://gist.github.com/mzdravkov/d13d8083849f6dcc1cd7
15:12mzdravkovThe problem is that it never matches and I can't find the bug. This is the first ever macro I try to write, so it's probably some lame mistake.
15:23rhg1351that's what I'm thinking, mungojelly
15:23rhg1351make the reader just emit a list if it sees that
15:27rhg135it'd be pretty cool to be able to invoke clojure and java from the shell
15:28rhg135deling with objects, not just strings
15:30mzdravkovit seems like match doesn't expand my pattern macro
15:31mzdravkovcan anyone explain me why this is so
15:32gfredericksmzdravkov: match probably isn't designed to macroexpand anything
15:33mzdravkovgfredericks: is there any workaround?
15:34gfredericksmzdravkov: maybe not without having your macro wrap the whole match call
15:35mzdravkovI thin it wraps it. If I correctly understand what you mean.
15:35mzdravkovthink*
15:35gfredericksin which case *I* don't understand correctly what your problem is
15:36gfrederickshave you tried using macroexpand-1 to debug your macro?
15:36mzdravkovI used macroexpand
15:37gfredericksokay; that's all I can recommend
15:37rboydhi gfredericks!
15:38gfrederickshi rboyd!
15:38mungojellya really clojurey shell should return for each command a nondestructive reference to a filesystem as changed by that command
15:39gfredericksrboyd: I still have the rboyd memorial hex dice, and used them to generate some data one time: https://twitter.com/gfredericks_/status/561191705052205058
15:39rhg135I'd have to reimplement part of the kernel for that
15:39rboydhey! that's fantastic
15:40rhg135at least write a lot of c
15:41mzdravkovwhenever I call macroexpand on my macro that builds the match call it prints like 50 lines of obfuscated code, so I tryed to put 'println instead of 'match and the result is perfectly fine, except my inner macro is not expanded.
15:41gfredericksmzdravkov: oh macroexpand-1 and macroexpand don't recursively expand things
15:42mzdravkovSo I can't have macro inside of another macro?
15:42gfredericksclojure.walk/macroexpand-all might help
15:42gfredericksit's just a tooling problem, not an issue with macros
15:47mzdravkovYes, right. Actually macroexpand is recursive (Repeatedly calls macroexpand-1 on form until it no longer represents a macro form, then returns it. Note neither macroexpand-1 nor macroexpand expand macros in subforms) Macroexpand-all fixed printing of subform macros.
15:49mzdravkovBut now it's even stranger: if I call macroexpand when calling 'match in the macro it prints like 50-100 lines of obfuscated code. So I changed it to 'println and the result is perfect. If I copy the result of macroexand-all and change the println to match it works fine
15:56gfredericksthis might be a rather complex first macro attempt
16:00akkadhttps://gist.github.com/a7761767d77c4dabd23a how do you accumulate properly with recur/loop?
16:08gfredericksakkad: does that not work for some reason?
16:42irctcanyone know why lein uberjar would create a target dir that has a classes and a stale dir but not the actual uberjar?
18:21Trioxinis 4clojure a prime resource for a beginner to learn?
18:22AimHereIt's a good resource yes
18:23AimHerePick a bunch of random people to follow, and when you solve a problem, see how they solve it
18:23AimHereUsually you get a feel for more idiomatic ways of doing things
18:23AimHereOccasionally, they might be wrong though (like the quine examples!)
18:34justin_smithdnolen: thanks for including that Merzbow clip in your Strange Loop talk, I appreciated that. I never thought I would see that particular interest join this one however tangentially.
18:35justin_smithand the Ulmer too, great stuff
18:37justin_smithI've been listening to a lot of Anne Gillis recently while programming (French concret / industrial), I just got her 5 CD box set.
18:40wasamasaigorrr is where it's at
20:05dnolenjustin_smith: glad you enjoyed the reference :)
21:25Surgoanyone know of a java or clojure lib for modifying PE/Coff files?
21:25SurgoI've seen plenty for parsing, not so much for "I just want to change this value"
21:56Surgoanyone know of a java or clojure lib for modifying PE/Coff files? I've seen plenty for parsing, not so much for editing
22:07krat0sprakharhello.. i'm having a hard time in changing file permissions of a file
22:08justin_smithkrat0sprakhar: does it have to be portable?
22:13krat0sprakharnope.. unix inly
22:13krat0sprakhar*only
22:13krat0sprakhari need to run chmod 400 on it, basically
22:14krat0sprakhar@justin_smith there's also https://github.com/Raynes/fs
22:14krat0sprakharbut i'm not sure if i want to add the entire lib just for this
22:23amalloykrat0sprakhar: there are a bunch of permission-related methods on java.io.File as of java 1.6. everything you need to get to chmod 400, albeit a little clumsily
22:23amalloyhttp://docs.oracle.com/javase/7/docs/api/java/io/File.html#setWritable(boolean,%20boolean)
22:23krat0sprakharto be honest, i'm having a hard time understanding java interop
22:23krat0sprakharin clojure
22:23krat0sprakharis there a good guide to help?
22:25krat0sprakharhttps://www.irccloud.com/pastebin/twYsnCS5/brave-clojure
22:25krat0sprakharhow do I do file.setWritable(true) on this?
22:26amalloyhave you read http://clojure.org/java_interop?
22:27krat0sprakharah my bad.. will go through this.. thank you
23:00coetrywhat can a novice expect to be the outcome of having completed the clojure koans?
23:00coetryI have experience programming, i know variables, loops, functions, and basics like that, but haven't really weaved all those concepts together in any major project
23:16kenrestivoi wonder if i'm alone in great pain having resulted from starting to use the components library.
23:20amalloykenrestivo: i don't think any library exists that hasn't caused someone great pain
23:23cflemingDoes anyone know of a classloader that I could use to load classes from jar files that isn’t a URLClassLoader?
23:28kenrestivoamalloy: true indeed.
23:28kenrestivoin this case, i'm trying to figure out why if i have [:log] as a dependency in component/using, the log component isn't starting until after the other ones do