Skip to main content

Posts

Showing posts from 2015

Install Command-T on Windows

Command-T is one of the most powerful Vim's plugins but install it on a Windows box could be a bit of pain in the ass little frustrating ;). Here I'll post a step by step guide on how to install this plugin from scratch. First of all, you will need a copy of Vim compiled with ruby support (+ruby) which ins't the case of the default version that you get from the official site. While you can compile Vim by yourself, you can also download an already compiled version from here http://wyw.dcweb.cn/download.asp?path=vim&file=gvim74.zip (ruby 2.0) Once your download completes, extract vim.exe and gvim.exe and copy them into “C:\Program Files (x86)\Vim\Vim74” Now, got to your command prompt and run: vim –version . Among a bunch of stuff, you should see +ruby . In addition to the modified version of Vim, you will also have to install ruby 2.0. If you haven't already, go to http://rubyinstaller.org/downloads/ and download de x86 version of Ruby 2.0 an...

Oneway ticket from Visual Studio to Vim

Not so while ago If you had asked: Would you ever leave Visual Studio (+ReSharper and tools)?. The answer would be: “Hell No!, Why on earth I'll leave the most powerful IDE ever built?! But as the time goes by, I've changed my mind... Lately I been working on Mac, Linux and Windows, doing .NET, JavaScript, TypeScript, Ruby, HTML, CSS, some SQL and batch/shell scripts. Having and editor that works (almost) the same way in all of these platforms is a big win for me. Not to mention that I can code in any language I want with out switching editors. Here is a short a short list features that made me change my mind. * Cross platform support. (Big one). * Lightweight. (When in the road, your battery will last longer). * Fast as hell. You won't be waiting for minutes to open solutions. * You can code in any language you want. * Tiny footprint. You don't need 8 GB of disk's space just to install the tool. * Already installed on most Unix systems. ...

Command-T on Windows. Vim error E370.

In this short post I'll show you how to troubleshoot the error: E370: Could not load library msvctr-ruby200.dll If you had install Commant-T on Windows (the right way) and are seeing the afore mention error, chances are  you had installed the x64 version of Ruby 2.0 and Ruby Dev Kit. I had made the same mistake (several times!), so no worries, you are just an easy fix away from fixit. Just uninstall the x64 version and install the x86 one of both, Ruby and RubyDevKit. Once you had installed the right version (platform wise), open vim and run: :ruby puts RUBY_VERSION. You shouldn't get any errors any everything should work as expected. Safety checks: * Verify the contents of C:\ruby200\bin (in there you should see msvctr-ruby200.dll). * Close all instances of cmd and run Vim from a fresh new one. If you have any question, ping me; I'll be glad to help.

TDD on .NET without Visual Studio

I've been long time user of the NUnit framework (I mean for ages) and I was quite happy with the overall experience. Good performance, lots of tests runners, great integration with Visual Studio, reasonable documentation, the list goes on and on... But lately I've been working mostly on mac and/or linux, and on that space, the experience wasn't that great. I still advocate for TDD (and any kind of automated tests for that matter) but I have to admit that doing TDD with NUnit outside Visual Studio (and without ReSharper support) was quite tedious. While NUnit comes with a console runner, I guess it's there just for CI Servers and not for developers to use. I mean you can use it, but the output is xml... and ... should I say more? ;) So with that problem at hand, I decided to write Contest , a small library that allows me to do TDD on .NET with just an editor and a console . Basic feature set but capable enough to get stuff done. And of course, easy to use from de con...

C# - How about using json files instead of app.config

I think we all agree that working with any kind of xml files is a bit of a pain in the ass. App.config is not an exception to that rule, so I'll show you a little trick that will help you to wipe out those nasty files replacing them for a more sane config file format with almost no changes to your code base.  Thanks to Json.Net, is really easy to read/write C# objects to json files, so if you are starting a new project, use a plain old C# object to store your settings and you are done. But what happens if you wanna replace the way you work with settings in an existing code base? I guess you will try to do it in a way that doesn't requires a whole lotta changes. Well this is one! Keep reading on github And of course, feel free to contact me if you have any question.