Skip to content

Instantly share code, notes, and snippets.

View nabinno's full-sized avatar
🤞
Draw and draw and draw

nabinno

🤞
Draw and draw and draw
View GitHub Profile
@nabinno
nabinno / 0_reuse_code.js
Created March 22, 2014 10:03
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@nabinno
nabinno / javascript_resources.md
Created March 22, 2014 10:04 — forked from jookyboi/javascript_resources.md
Here are a set of libraries, plugins and guides which may be useful to your Javascript coding.

Libraries

  • jQuery - The de-facto library for the modern age. It makes things like HTML document traversal and manipulation, event handling, animation, and Ajax much simpler with an easy-to-use API that works across a multitude of browsers.
  • Backbone - Backbone.js gives structure to web applications by providing models with key-value binding and custom events, collections with a rich API of enumerable functions, views with declarative event handling, and connects it all to your existing API over a RESTful JSON interface.
  • AngularJS - Conventions based MVC framework for HTML5 apps.
  • Underscore - Underscore is a utility-belt library for JavaScript that provides a lot of the functional programming support that you would expect in Prototype.js (or Ruby), but without extending any of the built-in JavaScript objects.
  • lawnchair - Key/value store adapter for indexdb, localStorage
@nabinno
nabinno / css_resources.md
Created March 22, 2014 10:04 — forked from jookyboi/css_resources.md
CSS libraries and guides to bring some order to the chaos.

Libraries

  • 960 Grid System - An effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. There are two variants: 12 and 16 columns, which can be used separately or in tandem.
  • Compass - Open source CSS Authoring Framework.
  • Bootstrap - Sleek, intuitive, and powerful mobile first front-end framework for faster and easier web development.
  • Font Awesome - The iconic font designed for Bootstrap.
  • Zurb Foundation - Framework for writing responsive web sites.
  • SASS - CSS extension language which allows variables, mixins and rules nesting.
  • Skeleton - Boilerplate for responsive, mobile-friendly development.

Guides

#!/usr/bin/perl -w
use strict;
use warnings;
use Date::Simple;
use DBI;
# Buckup
# ------
my $today1 = Date::Simple::today();
@nabinno
nabinno / 0_reuse_code.js
Created July 19, 2014 14:27
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
box: wercker/ruby
services:
- wercker/postgresql
build:
steps:
# Execute the bundle install step, a step provided by wercker
- bundle-install
- rails-database-yml:
service: postgresql
# Execute a custom script step.
box: wercker/rvm
# Build definition
# See the Rails section on the wercker devcenter:
# http://devcenter.wercker.com/articles/languages/ruby/settingup-rails4.html
# You will want to define your database as follows:
services:
- wercker/postgresql
# See more about services on our devcenter:
# http://devcenter.wercker.com/articles/services/
build:
config.autoload_paths << Rails.root.join('lib')
@nabinno
nabinno / _controller.rb
Created July 24, 2014 13:51
本番環境のみ、BASIC認証を設定する! #Ruby #heroku #Rails / Qiita http://qiita.com/fakestarbaby/items/c5fe2a28983056fee68b
http_basic_authenticate_with :name => ENV["BASIC_AUTH_NAME"], :password => ENV["BASIC_AUTH_PW"] if Rails.env.production?
# After:
# $ heroku config:add BASIC_AUTH_NAME=fakestarbaby
# $ heroku config:add BASIC_AUTH_PW=password
@nabinno
nabinno / git-undo.sh
Created July 24, 2014 14:20
command line - git undo all commited changes / Stack Overflow http://stackoverflow.com/questions/14075581/git-undo-all-uncommitted-changes
# This will unstage all files you might have staged with git add:
git reset
# This will revert all local uncommitted changes (should be executed in repo root):
git checkout .
# You can also revert uncommitted changes only to particular file or directory:
git checkout [some_dir|file.txt]
# Yet another way to revert all uncommitted changes (longer to type, but works from any subdirectory):