Skip to content

Instantly share code, notes, and snippets.

@gophry
gophry / gist:045102797ccbc04c4f5d
Created January 12, 2016 11:50 — forked from Suave/gist:6127873
mysql: truncate all tables in one command line
mysql -Nse 'show tables' DATABASE_NAME | while read table; do mysql -e "truncate table $table" DATABASE_NAME; done
@gophry
gophry / Docker Basic Install
Last active July 5, 2019 07:58
Docker - Custom Setup/CENTOS
1. Linux user Group - Create a docker Group
groupadd docker
wget https://get.docker.com/builds/Linux/x86_64/docker-latest -O docker
chmod +x docker
Move the docker file to mv docker /usr/bin/
gpasswd -a admin docker {admin can be any of your docker admin users}
2. Folder Structure
sudo mkdir -p /docker/var/lib
sudo chown root:docker -R /docker/
@gophry
gophry / gist:c8b0c5fdc8f32922d1c2
Created August 5, 2014 14:49
MACOSX Terminal - Jeffrey's Way
1. First use the ohmyzsh from roby russel. [details at https://github.com/robbyrussell/oh-my-zsh]
wget --no-check-certificate http://install.ohmyz.sh -O - | sh
Close the iTerm Shell and start again.
2. Install vim pathogen.
mkdir -p ~/.vim/autoload ~/.vim/bundle && \
curl -LSso ~/.vim/autoload/pathogen.vim https://tpo.pe/pathogen.vim
3. add the following line to .vimrc file and save it.
execute pathogen#infect()
4.
LARAVEL INSTALLATION WITH WINDOWS7/8
1. Go to https://www.apachefriends.org/index.html and download XAMPP for Windows[latest version].
2. Install the downloaded XAMPP server.
a. Antivirus warning ignore. Click yes.
b. Advisable to set User access control to Never Notify.
[Windows+R -> msconfig -> Tools -> Changes UAC Settings -> Never Notify]
A restart is required.
c. APACHE + MYSQL + PERL + PHP + PHPMYADMIN Minimum components should be selected for installation.
@gophry
gophry / MACOSX Basic Django Setup
Last active August 29, 2015 14:00
MACOSX Python/Django/Postgres Development Setup Procedure
[A] VIRTUALENV
1. Open Terminal
2. sudo easy_install pip
3. sudo pip install virtualenv
4. sudo virtualenv {name of python virtual environment}
5. cd {virtual environment created}
6. source bin/activate
[B] DJANGO install & First Project Creation
1. pip install django
2. django-admin.py startproject {project name} [django-admin.py command will auto complete with a tab]
@gophry
gophry / gist:6948267
Created October 12, 2013 10:10
Getting Started with Yeoman - Web App Workflow Development Tool.[Ubuntu]
<!--
Author: Yogesh Kamat
Date: October 12, 2013.
Subject: Yeoman Basic Kickstart.
-->
Getting Started with Yeoman - Web App Workflow Development Tool.
To start with Yeoman we need:
1. nodejs