IRC

I could not believe myself, that I finally created an IRC account. Lot of people have asked how come I am not on IRC. They told me that we get to interact with smart people on IRC, including creators of great software, libraries, framework. But for some reason, I resisted. It felt complex, compared to modern communities like Telegram, Discord etc. Today someone suggested it again on the Doom Emacs Telegram channel, and this time I decided to give an honest try.

Continue Reading »

Ruby for Python Programmers

While I noted similarities and difference between Ruby and Python, as I was learning the basics here, here and here there is official document on the Ruby site. See this

Learning Ruby: Syntax (Part 3)

Methods Ruby functions start with def just like python, but end with end keyword. splat operator (*) to destructure an array into a List. This is similar to Python splat operator >>> x = [10, 20, 30] >>> a, *b = x >>> print(f'{a=}, {b=}') a=10, b=[20, 30] Python ☝️, Ruby 👇 >> first, *rest, last = ["a", "b", "c", "d"] => ["a", "b", "c", "d"] >> first => "a" >> rest => ["b", "c"] >> last => "d" >> But in Ruby, splat operator can also create an array.

Continue Reading »

Icons in Directory Listing

Would you like to see pretty icons in your terminal for directory list ? Then install lsd from here Check this pretty screenshot of lsd --tree In case you are wondering, I’m using nord theme with Alacritty

Learning Ruby: Syntax (Part 2)

Learning continues … idiomatic(?) ruby loops use each like : (1..5).each do |counter| puts "iteration #{counter}" end Although python like loop also work for counter in 1..5 puts "iteration #{counter}" end array.each_with_index is like python’s enumerate Ruby seems to have multiple ways to do the same thing, as opposed to Python’s There should be one– and preferably only one –obvious way to do it. e.g. a.map do .. end, a.map { |el| e.

Continue Reading »

Installing Ruby

There are multiple ways to install ruby on your machine. Official recommendation is to use your OS’s package manager like apt, pacman or brew If you are using a version manager, rvm (Ruby Version Manager) seems to be popular. But in the past, I started using asdf, so I’ve decided to stick with it. It is also mentioned (first in the list) on the official Installing Ruby page 😄 asdf plugin add ruby https://github.

Continue Reading »

Learning Ruby: Syntax (Part 1)

I’ve meaning to learn Ruby for some time now. Especially, when I dabbled from time to time in Elixir, I felt that knowing Ruby may be an advantage (since Elixir syntax similar to Ruby) No one learns (I think) Ruby just for the language. They learn it so that they can use Ruby on Rails (RoR as popularly known) RoR, in case you don’t know, is the Web framework. Like Django in Python land.

Continue Reading »

Tmuxinator: Manage complex tmux sessions easily

After using tmux for a while, I realized that whenever I create new session locally, I end up opening same set of panes. One for work project (Sometimes more than one, but usually one) One for some kind of blog (I have three Hugo projects at this time) One misc. I start this in ~, I use this for running brew commands or standalone python session, or bin/doom sync (which I’ve been doing from inside doom emacs these days, so the last usecase has gone down) Turns out I’m not the only one™️ with such use case.

Continue Reading »

Firefox Reader mode in your Terminal

As I mentioned in an earlier post, I’m trying to move to more text based workflows. On that journey, I came across readable which creates a clean version of a webpage, just like Firefox Reader mode would do. But without Firefox. Which means, you can read cleaner website from your terminal (if you want) Read Firefox Reader mode in your Terminal

Fuzzy Search in fish with fzf

I had installed fzf some time ago. But default key ** for invoking fzf did not work with fzf. Upon searching, I came across couple of options. Of those, I chose the one with active development. As of this writing, the last commit was 11 days ago. Very active, I would say. 😄 Installation instruction said fisher install PatrickF1/fzf.fish but when tried, I got an error: fisher: unknown flag or command "install" 🤔

Continue Reading »