http://guides.rubyonrails.org/layouts_and_rendering.html
- `<%= javascript_include_tag "main" %>``
- `<%= stylesheet_link_tag "main" %>``
<%= image_tag "header.png", alt: "My Image", class: "my-class" %>
- `<%= video_tag "video.mp4" %>``
#!/bin/bash | |
branch_name=$(git branch | sed -e '/^[^*]/d' -e "s/* \(.*\)/\1/") | |
echo "Removing old cordova directory" | |
rm -rf cordova | |
echo "Creating cordova app to ${branch_name}..." | |
echo "WARNING: say 'no' to the next prompts" | |
ember generate cordova-init "my.company.${branch_name}" --platform=android |
#!/bin/bash | |
# Sync Homebrew installations between Macs via Dropbox | |
# | |
BREW="/usr/local/bin/brew" | |
# first get local settings | |
echo "Reading local settings ..." | |
rm -f /tmp/brew-sync.* |
http://guides.rubyonrails.org/layouts_and_rendering.html
<%= image_tag "header.png", alt: "My Image", class: "my-class" %>
Exporting password + one-time code data from iCloud Keychain is now officially supported in macOS Monterey and Safari 15 (for Monterey, Big Sur, and Catalina). You can access it in the Password Manager’s “gear” icon (System Preferences > Passwords on Monterey, and Safari > Passwords everywhere else), or via the File > Export > Passwords... menu item). You shouldn't need to hack up your own exporter anymore.
After my dad died, I wanted to be able to have access any of his online accounts going forward. My dad was a Safari user and used iCloud Keychain to sync his credentials across his devices. I don’t want to have to keep an OS X user account around just to access his accounts, so I wanted to export his credentials to a portable file.
import argparse | |
import json | |
import re | |
import os | |
from time import time | |
parser = argparse.ArgumentParser(description='Convert to Quiver Format') | |
parser.add_argument("src", help="The Source File You want to Convert") | |
args = parser.parse_args() | |
cells = [] |
chsh -s $(which zsh)
README.md
Magic words:
psql -U postgres
Some interesting flags (to see all, use -h
or --help
depending on your psql version):
-E
: will describe the underlaying queries of the \
commands (cool for learning!)-l
: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)I think the most confusing thing that I have found about Ruby on Rails so far has been the transition from (trying to) write code myself to the use of the fabled "Rails Magic". So, to help my own understanding of a few core Ruby on Rails concepts, I have decided to write something on what I think is a CRITICAL topic... the idea of Convention over Configuration and why (in my mind) it is the most important thing that helps Rails become magic!
(This may be a topic that we cover in more detail in class but as I said, I'm writing this for my own understanding... I hope it helps someone else understand things too... Perhaps you can give me a hand when I'm crying next week!)
##Convention over configuration ###What does this "actually" mean...
<html lang="en"> | |
<head> | |
<title>CodeMirror in Action</title> | |
<script src="js/vendor/jquery-1.9.1.js"></script> | |
<!-- More examples at http://codemirror.net/demo/ --> | |
<!-- add basic CodeMirror functionality --> | |
<script src="js/vendor/codemirror-4.1/lib/codemirror.js" type="text/javascript" charset="utf-8"></script> |