Skip to content

Instantly share code, notes, and snippets.

View lelandsmith's full-sized avatar

Leland Smith lelandsmith

View GitHub Profile
Existing schema is below:
ActiveRecord::Schema.define(:version => 20120130161449) do
create_table "movies", :force => true do |t|
t.string "title"
t.string "rating"
t.text "description"
t.datetime "release_date"
t.datetime "created_at"
# This is a template .gitignore file for git-managed WordPress projects.
#
# Fact: you don't want WordPress core files, or your server-specific
# configuration files etc., in your project's repository. You just don't.
#
# Solution: stick this file up your repository root (which it assumes is
# also the WordPress root directory) and add exceptions for any plugins,
# themes, and other directories that should be under version control.
#
# See the comments below for more info on how to add exceptions for your
server {
listen *:8080;
server_name fanatik.redrokk.com www.fanatikbike.com fanatikbike.com;
root /home/production/www.fanatikbike.com/web/webroot/;
##
# redirect to www
##
#if ($host !~* ^www\.) {
# rewrite ^(.*)$ http://www.$host$1 permanent;
apt-get update
apt-get upgrade
apt-get install mysql-server
mysql_secure_installation
apt-get install nginx
apt-get install git-core
# Don't include any temporary files and other unimportant things
*.log
*.bak
*.bak.*
*.thumbs/
.DS_Store
Thumbs.db
.svn
*.swp
#301 Redirects for .htaccess
#Redirect a single page:
Redirect 301 /pagename.php http://www.domain.com/pagename.html
#Redirect an entire site:
Redirect 301 / http://www.domain.com/
#Redirect an entire site to a sub folder
Redirect 301 / http://www.domain.com/subfolder/
@lelandsmith
lelandsmith / 0_reuse_code.js
Last active August 29, 2015 14:22
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

Bypass Wordpress Localhost FTP Connection Information

Do chown / chmod wordpress folder:

    $ sudo chown -R :_www wordpress
    $ sudo chmod -R g+w wordpress

Add the following line into wp-config.php: