In the last 20 years time period, web development has been enormously evolved. The present scenario of the modern web development environment would not be familiar with the development of “coldfusion”, here I am talking about the late 90s’. The wider focus on the best development practices and productivity have certainly made software more maintainable, however, this comes as the added complexity. To navigate this complexity, modern web development is essentially required and my purpose of writing this is to outline my personal favorite tools.
Tmux
Tmux is a terminal multiplexer, it means you can have several terminals in the same shell session. It lets you split panes and move them around and reconnect to a tmux session from a different machine. It mainly shines when it is deployed on a server, as you can start a long-running task, disconnect, and your tmux session will keep running.
The actual strength in Tmux for development lies in knowing in which window each of your different tools is running because with some quick window changing shortcuts, you can move so quickly that flow becomes instinctual. To aid this,tmuxinator sets up profiles that complement Tmux nicely.
Additionally, Tmux is extendable through its plugin ecosystem. Do have a look; however, I would recommend the Tmux Plugin Manager, tmux-battery, and tmux sensible.
Fish
Bash is somewhat fine and it hasn’t aged very well because of better terminal alternatives are already available. ZSH is an excellent choice, but because of lack of learning I have not invested my time to configure this valuable piece of software. To this end, I would recommend. It has an excellent command completion, is fully scriptable, and looks much nicer than Bash. I personally enjoy interfacing with Git way, as it offers excellent Github integration and unparalleled autocomplete, so I am currently vacillating between the two.
Vim
Vim is the cornerstone for the heavily customized and speed development, as it bears a resemblance of a fully fledged IDE. Let’s walk through some generally useful plugins, and then get to some Ruby-specific ones.
Navigating a big project is actually cumbersome. Fortunately, Vim’s rich ecosystem really comes into favor for browsing a project. Nerdtree is highly recommended for a browsable tree structure as it provides you a neat high-level overview of the current directory. Pressing “m” while in this view will allow you the ability to delete, create, and rename nodes without ever leaving vim.
Finally, if you frequently want to access files use MRU as it does exactly the same. Here are some of the vim plugins that deserve special mentions:
- Fugitive: Direct Git integration Vim
- Supertab: Code completion
- Airline: Pleasant looking status bar
- TComment: Quick comment and uncomment functionality
- Surround: Wrap the usual vim boundary selections in parenthesis or quotes
- Autoclose: Automatically close brackets or quotes
- Gundo: Interface to Vim’s well-hidden tree structure storing document changes, which frequently proves much
more useful than the linear ‘undo’ functionality.
Ruby Specific Plugins
First of all, you need to make sure your version of Vim is compiled with Ruby:
The above-listed command should include “a +ruby”. If it is not then you should recompile Vim with ruby support or install a version of Vim with Ruby support, like MacVim. While a lot of the plugins will work without it, you’ll miss out on useful features like autocompletion.
vim-ruby it is the first port of call. It includes syntax highlighting, IntelliSense-like autocompletion, and even compiler plugins. This should get you a lot of basic IDE functionality out of the box and it even has erb syntax highlighting!
If you’re going to get one plugin to aid your Rails development, it should be vim-rails. This plugin brings all the command line functionality directly into Vim that is tremendously useful when you marry it up with Vim shortcuts.
Honorable mentions:
- vim-endwise: automatically appends an end when you input def. Think snipmate but without having to invoke the shortcut.
- vimbundler: wraps bundler, which makes interfacing with it slightly nicer.
- vim-haml: Cutting edge Vim runtime files for Haml, Sass, and SCSS – unnecessary but nice.
This isn’t really a Vim plugin, but I’ll include it here anyway: gem-browse is a Ruby Gem that opens a library’s source file in your editor, which saves time when you need to wade through the source of some obscure library to see why your code isn’t executing as expected.
Docker
Docker is comparatively the newest technology compared to the others and it is significant too. It provides easy and platforms agnostic deployment by running a ‘container’ within a single Linux instance, avoiding the overhead of starting and maintaining traditional Virtual Machines.
Pry
Pry is a fantastic addition to your gemset. A powerful alternative to irb, it allows command shell integration (git, vim, etc), syntax highlighting and powerful history viewing and replay functionality. It can work well as a debugger and as someone who favors REPL driven development, I find it a breath of fresh air to use compared with the default irb.
Pgcli
With the advent of ORMs, SQL is something I interface with less regularity that means auto complete is a real time saver.Highly recommended.
Mutt
If you can suffer through what is arguably the most painful configuration process in modern software, Mutt is an excellent choice for command line email access. It uses Vim bindings and I definitely appreciate not having to leave my shell to handle email.
Irssi
I find IRC an invaluable resource, but definitely, something that works better in the shell.
Summary
I have tried to cover a lot of ground here and, as always, there’s a ton more below the surface. I have spent a lot of quality time on Vim and much more time customizing it. Researching Tmuxwas definitely time well-spent. However, this is my all personal preference, you might have a better and different idea and perhaps integrate something in a new from into your own workflow.
We are happily ready to serve you
Here at Bacancy Technology, we have an in-depth knowledge and an extensive experience of RoR developers. Being active RoR community members, we are always there to help you.
If you are looking to hire ruby on rails developer, you can mail us your requirement at [email protected]. Feel free to connect with us in the case of any queries.
Related Article: 8 Awesome Tools To Keep Your Rails Code Clean And Organized