Attention: the list was moved to
https://github.com/dypsilon/frontend-dev-bookmarks
This page is not maintained anymore, please update your bookmarks.
Attention: the list was moved to
https://github.com/dypsilon/frontend-dev-bookmarks
This page is not maintained anymore, please update your bookmarks.
# Mac OS X Lion introduced a new, iOS-like context menu when you press and hold a key | |
# that enables you to choose a character from a menu of options. If you are on Lion | |
# try it by pressing and holding down 'e' in any app that uses the default NSTextField | |
# for input. | |
# | |
# It's a nice feature and continues the blending of Mac OS X and iOS features. However, | |
# it's a nightmare to deal with in Sublime Text if you're running Vintage (Vim) mode, | |
# as it means you cannot press and hold h/j/k/l to move through your file. You have | |
# to repeatedly press the keys to navigate. |
require 'set' | |
class Life | |
attr_accessor :state | |
def initialize(previous_state) | |
@state = advance(previous_state) | |
end | |
def advance(previous_state) |
### Keybase proof | |
I hereby claim: | |
* I am dangeranger on github. | |
* I am dangeranger (https://keybase.io/dangeranger) on keybase. | |
* I have a public key whose fingerprint is 1AF1 64DA A8D0 BAFE 35C2 71D4 2677 0B52 2A3D D2A3 | |
To claim this, I am signing this object: |
# lib/tasks/db.rake | |
namespace :db do | |
desc "Dumps the database to db/APP_NAME.dump" | |
task :dump => :environment do | |
cmd = nil | |
with_config do |app, host, db, user| | |
cmd = "pg_dump --host #{host} --username #{user} --verbose --clean --no-owner --no-acl --format=c #{db} > #{Rails.root}/db/#{app}.dump" | |
end | |
puts cmd |
###Checkout a remote branch and set it to track the remote
This will keep your local branch in sync with the remote on push/pull/fetch
[email protected]:~$ git branch -vv
joshes_branch 6a1e534 [origin/joshes_branch] added script tags to index.html
###Core Commands
Command | Description |
---|---|
cd | Go to Home directory |
cd ~ | Go to Home directory |
cd [folder] | Go to a [folder] |
cd / | Go to Root of the operating system |
ls | List files and sub-directories in the directory |
ls -l | List details of files and sub-directories in the directory |
###Querying the database
Now you just need to learn a little bit of new sqls for selecting stuff (creating and updating is transparent). Find records that contains a key named 'foo’:
Person.where("data ? 'foo'")