Sometimes you want to process something, but you're not interested in the result immediately because the task is not a priority to you, or maybe even the user.read more
I have a tool called pgpass-env that, given a suitably commented PostgreSQL
~/.pgpass file will allow you to easily set the environmental variables for software that doesn't support reading from that format.
Thinking about this problem, it seems to be a general problem:
Quick JDBC queries respecting UNIX conventions (environmental variables, STDIN, STDOUT etc)
git clone email@example.com:forbesmyester/jdbc-pipe.git && cd jdbc-pipe)
Hacky tools for PostgreSQL that makes interacting / extracting / analysis of data in PostgreSQL easier.
NOTE: Examples are from a PostgreSQL version of ergast.
Sometimes I find I have requests like the following:
Run this query and give me the results [in an Excel file so I can look at …
This is the third of the Code in PostgreSQL series of articles.
This is the second of the Code in PostgreSQL series of articles.
This is the first of the Code in PostgreSQL series of articles.
Sometimes you do not need all the data brought from the database into your normal programming language. Using normal aggregate functions such as [
AVERAGE](https://www.postgresql.org/docs/8.2/functions-aggregate.html) you may save your …
I wanted to make a blog post which a future LNUG talk will be based on to compare achieving the same output in both NodeJS and PostgreSQL.
While doing this I realised that it would be best to have the code shown side by side like the following:
+-----------------------------------------------------------+ | | | # Joining Two …
In general when I am developing I tend to have unit test results on the right with my code on the left as apposed to having two files open. This means I tend to use
C-^ keystroke a lot, which is jump back to last buffer in VIM.
The last …read more
When thinking about problems I sometimes come up with ideas on how to solve them. It might be a great solution, but more often than not they need some finesse and I may want to discuss them with other developers.
I find diagrams are a highly effective way of …read more
I have a pretty well customized tmux configuration, as do lots of people but there is one thing that I've found difficult to do and isn't in most peoples configuration (that I've seen). This is the ability to move panes between different windows or re-order the windows.
Configuring tmux for …read more
Noticed this when requiring Ramda:
[BABEL] Note: The code generator has deoptimised the styling of "/home/fozz/Projects/siac-ui/node_modules/ramda/dist/ramda.js" as it exceeds the max of "100KB".
Now I love Ramda, you should read about, it's awesome, but I am only actually using a few functions …read more
I recently re-installed my laptop (which has loopback, WIFI and wired network connections) from scratch and I found that it has "NetworkManager is not running" displayed when I click the NetworkManager applet, which is apparently not that strange. This was straight after an install which was disappointing :-(
My installation method …read more
When I was about 18 and living at my parents, my bedroom was full of old computers which I'd turned into servers and managed to wire up using a BNC network and HowTo's printed out on the college computers... I didn't have internet access. I tought myself TCP/IP networking …read more
Something unfortunate happened to me over the weekend... I was writing code using the great Ramda, there was promises going on and the code was wonderful... Then along came the awesome When.js to solve my more complicated future based problems but this made me write code like the following …read more
I have a desire set up virtual machines on my laptop using scripts for testing things like microservices. Unfortunately I don't much like BASH as a provisioning system and would prefer to work with Ansible.
The Init Provisioning scripts are designed to allow easy development of Ansible based virtual machines …read more
For most of my working life I've been doing RDD (refresh driven development) but in the last 3-4 years I've been using more and more TDD. It's got to the point that pretty much all functionality new that I write is written using TDD, life is sooooooo much better but …read more
Some of you may know that I'm pretty interested in Functional Programming with some of the code that I write day to day having a somewhat functional style (while hopefully not being completely alien to our imperative friends). I have spent quite a bit of time trying to learn Haskell …read more
I currently have a personal project which will almost certainly involve creating a mobile app. I'd ideally like to make it a hybrid native/Phonegap app to maximize the time spent writing cross platform code as apposed to duplicating work between different mobile platforms... The fact that the bulk of …read more
Went to a great talk about Neo4J at their London offices last night. It was great to hear (new to me) ideas about how to store data.
If I were to sum it up in a really short amount of words I would say that it is somewhat like an …read more
I've just had an extremely frustrating mostly wasted day with Docker. It turns out that, at least with Ubuntu 14.04 the root user is quite messed up, for example it's home directory ends up being just
/ and worse than that putting files like
.ssh/known_hosts in the root (or …
I am currently (and have been for a long time) in a state of flux with my current editor selection... For a while about 6 months ago I thought I would end up using VIM and even started reading a book about it. I learnt about VIM Golf, the amazing …read more
Today I am flying to Dublin for 7 days so I can continue my work with CityHook / Indigo and I am currently in the airport passed security... Of course they confiscate all drinks from you... so where to get a drink?
I found that you can get bottled …read more
Sometimes you have a function, that you're planning to use within something like
async.waterfall but it's wrote to be synchronous and returns a value instead of using a callback. This function will accept that function, along with a context and return an asynchronous version of that function
I am intending to take the React demonstration from TodoMVC and use it as a basis for demonstrating SyncIt. To enable me to do this I have released two seperate pieces of code, which for contractual reasons were always integrated directly into SyncIt and are now available seperately via GitHub …read more
Currying is a concept from functional programming where you allow you a function that would normally need
n arguments to be called with fewer arguments. When you do this it will return a function with you current arguments stored, but waiting for the extra arguments. When all arguments …
This week is incredibly busy for me as I am going to a meetup every day but it started with a great talk by Uncle Bob (Robert C. Martin) about Design Patterns at SkillsMatter. In it he gives what appeared to be a completely unrehearsed a run through of some …read more
Currently when I get home from work and I want a bit of a change I'll do a bit of work learning Clojure, which at the moment is writing a script to generate HTML photo albums from a directory structure with images... I'm looking forward to getting it working and …read more
In this post I want to look at a method I used for writing decoupled easily reusable code within one of my personal projects using a method inspired by Functional Programming.
var emailSender = new EmailSender( /* SMTP …
I was coding along quite happily on a project (soon to be unveiled) and got to testing my code that interacts with the server. I was intending to using Sinon.js to mock this, but the response was never coming back... My code was like this:
Often as a developer I want to explain something that is either very complicated or very abstract to other people and this is not easy always.
In this situation I might use a diagram but I am not particularly skilled at doing this and I find the whole process incredibly …read more
So I just got back from MongoDB London 2013 and here is a quick run down of some of the highlights for me...
Optimising for Performance, Scale and Analytics - David Mytton, Server Density. Talked about spotting problems with your deployment and the things you should watch out for as signs …read more
Today I disovered a great little tool for helping to draw small flow diagrams and then being able to export them into ASCII! It does not try to be a complicated tool, but instead gives you simple very simple ones just for drawing boxes lines, writing text and moving that …read more
After creating this Gist I decided that …read more
Me Map Reduce is inspired by MongoDB's map/reduce functionality.
Today I wanted to get started on writing the server code for SyncItStore so needed to set up a dev server. I started installing Ubuntu Server and was keeping notes on the steps I needed to replicated it.
I created virtual guests on my laptop using …read more
I currently am an owner of a Thecus N3200pro NAS. I bought it because it has three disk bays, so can do RAID5 and was similarly priced to a very cheap PC. I was happy with it at first...
Later on I wanted to try out …read more