Skip to content

Instantly share code, notes, and snippets.

@mharting
mharting / Pipeable.rb
Created March 25, 2025 21:29
This is a utility Ruby module. It can be used like this: `method1 | method2 | method3` this would take the output from method1 and pass it as an input to method2 and take the output of that to method3. The output of method3 would be returned as a result of the method chain.
module Pipeable
extend ActiveSupport::Concern
def |(other)
other.call(self)
end
module ClassMethods
def call(arg)
@mharting
mharting / jira_search.md
Last active August 26, 2024 21:34
Setup Jira search in Chrome

go to the Chrome Site Search settings chrome://settings/searchEngines

Scroll down to Site Search and either edit the Jira search or click Add to create a new one if it doesn't exist in your Chrome

image

Review the image to see how to create/update the new site search and the click Save.

This will be activated by typing jira (the value in the shortcut field) into the address bar and then the ticket number.

@mharting
mharting / gist:ab33a0a9b6726f9b3535d528122edc14
Last active June 30, 2021 19:09
Reconfigure existing repositories to use SSH
The repositories we clone from now on using SSH will continue to use SSH for future Git commands such as git pull and git push. But existing local repositories, previously cloned with HTTPS, will continue to use HTTPS, unless we set them up to use SSH.
To do that, open the terminal and change the current directory to a local repository.
List the existing remote repositories and their URLs with:
$ git remote -v
That command should output something like:
@mharting
mharting / MacSetup.md
Last active October 12, 2022 20:20
MacBook setup