Fork me on GitHub

1. I'm using git. 2. I have a file src/server/scala.clj 3. I want to retrieve, from git, ALL versions of this server/scala.clj file 4. How do I do this ?


you can do git log -- src/server/scala.clj to see all the commits that changed that file


git log --online -- src/server/scala.clj will be more concise/greppable


and then git show <commit id>:src/server/scala.clj to spit out just the contents of the file at that commit


git log --oneline -- src/server/scala.clj | awk '{print $1}' | while read commit_id; do git show $commit_id:src/server/scala.clj > "$commit_id"_scala.clj ; done


will spit out a bunch of “<commit id>_scala.clj” files in your current working directory


@smith.adriane was afk, resolved this issue (via stack overflow), but: 1. the commands look very similar 2. thanks for writing this out in detail


If I want a simple DB that's contained in a file, how does H2 compare to SQLite? Does anyone know pros/cons?


@roklenarcic Not sure if it matters much between those two. I’d go for H2 since it’s more Java centered (


@roklenarcic However, I would also take a look at if your requirements are only Clojure data structures


but if you want to migrate to another SQL db in the future, H2 might be the best option


I just got refused at my dream job because I didn't had enough functional programming experience. I've been interested in functional for years, but I've never had the opportunity to use it at work, and I was too damn lazy to do it by my own, I didn't get the job.


I'm not feeling like this again, time to work harder towards what I really want


Keep at it 🙂 I was refused by one company (not enough cljslightly_smiling_face: then refused from another a few years later (not enough clj). Finally, a few months ago, I was accepted into the first one since I'd learnt enough by doing things on the side. I kept pushing it as much as I could at work too, teaching JavaScript developers I was working with about ImmutableJS and the like. Even building some tiny services in Clojure with permission from people I worked with.


Thanks. So you got in the company that rejected you at first? That's inspiring, because I'm definitely gonna call the company that refused me once I have more experience in clojure.


Yup, I was rejected a few years back by the same guy because I just didn't know enough and they needed someone who could actually contribute right away. Since I've joined we've turned people down for the same reasons (although we have offered to hire one person as a junior that we would train up (no response)). Best thing I can recommend is an interesting GitHub, so tinker, fix bugs on things, do exercises in books. Just be visible online doing the thing you want to do day to day. It's how I started as a programmer in JavaScript and how I moved to Clojure(Script). Just do stuff, even if it's not amazing, to show that you're invested. You'll also see your progress clearly as you look over your old projects, which is fun.


The problem I have now is that I have to maintain a bunch of open source JavaScript that I don't like looking at 😝


@U38J3881W just mark it as abandonware and you're golden 😉


Ahah. At least I'll be able to learn from your mistakes and start directly with clojurescript 😛


@U61HA86AG haha, I wish I could. They have 900 and 2.2k stars respectively, so I feel like I should keep kicking them along. A lot of the issues now are people telling me it doesn't work with some version of TypeScript. People keep trying to add things to something I've seen as "done" for years 😄 maybe I'll lock them one day...


@U38J3881W that's honorable of you :~)


@U61HA86AG - Interesting thread… Just curious, why did you tag me though? 🙂


@U08ABGP70 i'm so sorry, it's that silly slack popup thing


Slack doing the old "pick anyone called Oliver and it's probably fine" dance.


Oh no worries 🙂 FWIW, @U7S5E44DB I am finally doing Clojure / ClojureScript full time by being Engineer #1 at a new start-up and persuading the CEO that I am right to pick the stack 🙂


So that’s another route into it… 😉 I’ve been programming in Clojure for about 6 years, done a tiny bit of paid work before and a TINY bit of Clojure got onto the stack at previous employers… What I’ve learned in the last 5 months has been a revelation, but I don’t remotely regret the decision. 🙂


the moment i have the chance to sucker punch clojure into a project here i am doing it 😈


At my previous one, where I was hired to write JS, I extended our hubot with some useful stuff by writing a Clojure server and talking to it from a tiny hubot plugin. Was a good thing to talk about in interviews too.


My public GitHub is empty. I spend all day coding and enjoying it. I don't have any desire to spend my free time doing that too though...


I can talk about loads of stuff we do in-house assuming I get to interview though


I have a friend that doesn't like the "you must have an active GitHub" mentality, and I totally get it. It's just a good way to get into something if your employer won't pay you to do the thing you want. If you can get paid for it, by all means 😄


@U6SUWNB9N i hear you man, at home i only code on occasion (or when i am, it's helping my mates with their code instead of doing my own). plenty of other things i want to do :~)


If I'm in a job where I'm coding a lot at work, I tend to neglect my GitHub repos. If I'm in a job where I'm mostly managing, or mostly being an architect (and hands off), then I have to find time to write FOSS code otherwise I go insane 😐


My github activity is very sparse, most of my work is in private repos for clients. I would not be an interesting prospect if people only looked at my Github. Working on side projects has also declined because I have a 4 year old, and when I have time to do some side projects, I normally use it doing research/education.


As a hiring manager, I find it helpful if a candidate has a GitHub repo but I wouldn't discount anyone for not having one. In some ways, I'd look harder at a candidate who has a GitHub repo: they're saying "Here's code I think is good enough for others to use" -- so if I think it's poor code, they're more likely to be cut before the interview.


Of course, if it's good code, then that does improve their chances 🙂


ah, but i personally just put all of my code on git(hub|lab), regardless. i wouldn't want people to use the code on there, it's just for my sake 😁


guess i could pay for premium and use private repos, but haven't needed them


if i wanted to create a portfolio of my best code, i would do that specifically, on a website


@U61HA86AG And that's a reasonable approach too, but even "throw away" code on GitHub tells you something about how a programmer approaches problems.


fair enough


Without eval-ing in your REPL, what’s the result of (#()): an exception or a value?


(I was surprised it was a value ;))


(fn* [] ())
it expands to this @borkdude


pretty fun


at first i misread your snippet as (#{}), which is indeed an exception 😉


I know that Java offers the Convolution operator on BufferedImages. Does Java also offer such an op on float-arrays ?