A comprehensive reference for Omarchy - an opinionated Arch Linux + Hyprland setup by DHH.
| Shortcut | Function |
|---|
Problem: accidentally pressing 'Esc' when editing a form in a "standard" LiveView modal dialog will discard all edits.
Proposed solution: Make the modal show a confirmation window on close when there have been changes on the form.
LiveView v0.20 was used.
Table of content
I get asked pretty regularly what my opinion is on merge commits vs rebasing vs squashing. I've typed up this response so many times that I've decided to just put it in a gist so I can reference it whenever it comes up again.
I use merge, squash, rebase all situationally. I believe they all have their merits but their usage depends on the context. I think anyone who says any particular strategy is the right answer 100% of the time is wrong, but I think there is considerable acceptable leeway in when you use each. What follows is my personal and professional opinion:
This is a quick walk through on how to:
This uses the free heroku and mailgun plans. If you get stuck on any part, check the full code here.
| package main | |
| // Sample file for test: https://drive.google.com/file/d/1DFkJdX5UTnB_xL7g8xwkkdE8BxdurAhN/view?usp=sharing | |
| import ( | |
| "encoding/csv" | |
| "encoding/json" | |
| "fmt" | |
| "io" | |
| "os" | |
| "strconv" | |
| "sync" |
| " plugins | |
| let need_to_install_plugins = 0 | |
| if empty(glob('~/.vim/autoload/plug.vim')) | |
| silent !curl -fLo ~/.vim/autoload/plug.vim --create-dirs | |
| \ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim | |
| let need_to_install_plugins = 1 | |
| endif | |
| call plug#begin() | |
| Plug 'tpope/vim-sensible' |
| module Accessible | |
| extend ActiveSupport::Concern | |
| included do | |
| before_action :check_user | |
| end | |
| protected | |
| def check_user | |
| if current_doctor | |
| flash.clear |
Run rails new --help to see all of the options you can use to create a new Rails application:
Output for Rails 8+
Usage:
rails COMMAND [options]
You must specify a command:
| # The following comments fill some of the gaps in Solargraph's understanding of | |
| # Rails apps. Since they're all in YARD, they get mapped in Solargraph but | |
| # ignored at runtime. | |
| # | |
| # You can put this file anywhere in the project, as long as it gets included in | |
| # the workspace maps. It's recommended that you keep it in a standalone file | |
| # instead of pasting it into an existing one. | |
| # | |
| # @!parse | |
| # class ActionController::Base |