This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # | |
| # INSERT query generator for Oracle | |
| # | |
| # Requirements: | |
| # - Ruby 2.0 or later (https://www.ruby-lang.org/) | |
| # - ruby-oci8 (gem install ruby-oci8) | |
| # - Oracle Database | |
| # | |
| require 'oci8' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Could be used for instance like this in Phoenix: <%= select f, :time_zone, SimpleTimeZoneList.mapping %> | |
| defmodule SimpleTimeZoneList do | |
| @mapping %{ | |
| "International Date Line West" => "Pacific/Midway", | |
| "Midway Island" => "Pacific/Midway", | |
| "American Samoa" => "Pacific/Pago_Pago", | |
| "Hawaii" => "Pacific/Honolulu", | |
| "Alaska" => "America/Juneau", | |
| "Pacific Time (US & Canada)" => "America/Los_Angeles", | |
| "Tijuana" => "America/Tijuana", |
-
CTRL + A— Move to the beginning of the line -
CTRL + E— Move to the end of the line -
CTRL + [left arrow]— Move one word backward (on some systems this is ALT + B) -
CTRL + [right arrow]— Move one word forward (on some systems this is ALT + F) -
CTRL + U— (bash) Clear the characters on the line before the current cursor position -
CTRL + U—(zsh) If you're using the zsh, this will clear the entire line -
CTRL + K— Clear the characters on the line after the current cursor position -
ESC + [backspace]— Delete the word in front of the cursor
In your command-line run the following commands:
brew doctorbrew update
Dear all Github friends,
I moved this gist to the Github repository.
Following this repository https://github.com/nijicha/install_nodejs_and_yarn_homebrew
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ## Context + metadata | |
| shared_context 'Logged as a user', role: true do | |
| let(:user) { |example| create :user, example.metadata[:role] } | |
| before { login_as user } | |
| end | |
| scenario "Login as a client", role: :client | |
| scenario "Login as a customer", role: :customer | |
| scenario "Login as an admin", role: :admin |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Add the following in .zshrc: | |
| ... | |
| plugins=(osx git zsh-autosuggestions zsh-syntax-highlighting zsh-nvm docker kubectl) | |
| ... | |
| ### Fix slowness of pastes with zsh-syntax-highlighting.zsh | |
| pasteinit() { | |
| OLD_SELF_INSERT=${${(s.:.)widgets[self-insert]}[2,3]} | |
| zle -N self-insert url-quote-magic # I wonder if you'd need `.url-quote-magic`? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -module(connection). | |
| -behaviour(gen_statem). | |
| -export([start_link/1, request/2]). | |
| -export([callback_mode/0, init/1]). | |
| -export([disconnected/3, connected/3]). | |
| %% Public API. | |
| start_link(Opts) -> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Stick this in your home directory and point your Global Git config at it by running: | |
| # | |
| # $ git config --global core.attributesfile ~/.gitattributes | |
| # | |
| # See https://tekin.co.uk/2020/10/better-git-diff-output-for-ruby-python-elixir-and-more for more details | |
| *.c diff=cpp | |
| *.h diff=cpp | |
| *.c++ diff=cpp | |
| *.h++ diff=cpp |