Delete the last commit, if it hasn't been pushed.
git reset --soft HEAD~1
Delete the last commit, if it has been pushed.
git reset --hard HEAD~1
git push origin HEAD --force
Temporarily ignore local changes to a file
| class Alert < ActiveRecord::Base | |
| belongs_to :alertable, :polymorphic => true | |
| end | |
| class Region < ActiveRecord::Base | |
| has_many :alerts, :as => :alertable | |
| end | 
Delete the last commit, if it hasn't been pushed.
git reset --soft HEAD~1
Delete the last commit, if it has been pushed.
git reset --hard HEAD~1
git push origin HEAD --force
Temporarily ignore local changes to a file
| # Master image | |
| FROM centos | |
| # Use Epel | |
| RUN rpm -ivh http://ftp.riken.jp/Linux/fedora/epel/6/x86_64/epel-release-6-8.noarch.rpm | |
| # Install middleware | |
| RUN yum -y update | |
| RUN yum install -y which tar patch libffi-devel glibc-headers autoconf gcc-c++ glibc-devel patch readline-devel zlib-devel openssl-devel bzip2 automake libtool bison | |
| RUN yum install -y libyaml libyaml-devel libxml2 libxml2-devel libxslt libxslt-devel | 
| var debug = process.env.NODE_ENV !== "production"; | |
| var webpack = require('webpack'); | |
| module.exports = { | |
| context: __dirname, | |
| devtool: debug ? "inline-sourcemap" : null, | |
| entry: "./js/scripts.js", | |
| output: { | |
| path: __dirname + "/js", | |
| filename: "scripts.min.js" |