add changes without whitespace
git diff -w --no-color | git apply --cached --ignore-whitespace
find deleted file
$ git log -- /path/to/file
display deleted file
| def foo | |
| puts 'foo' | |
| end |
| #include <QtGui/QApplication> | |
| #include <QFile> | |
| #include <QTextStream> | |
| #include <QChar> | |
| #include "mainwindow.h" | |
| #include "neuron.h" | |
| #include "outputstream.h" | |
| QTextStream qout(stdout); |
| /** | |
| * @file palindrome.c | |
| */ | |
| #include <stdio.h> | |
| #include <string.h> | |
| #include <stdlib.h> | |
| #include <stdbool.h> | |
| #include <cs50.h> | |
| bool isPalindrome(char* text); |
| $ mvn verify | |
| [INFO] Scanning for projects... | |
| [INFO] | |
| [INFO] ------------------------------------------------------------------------ | |
| [INFO] Building maven-tests-config 1.0-SNAPSHOT | |
| [INFO] ------------------------------------------------------------------------ | |
| [INFO] | |
| [INFO] --- maven-resources-plugin:2.5:resources (default-resources) @ maven-tests-config --- | |
| [debug] execute contextualize | |
| [INFO] Using 'UTF-8' encoding to copy filtered resources. |
| scala> trait Person { def grade(years: Int): String } | |
| defined trait Person | |
| scala> class SalesPerson extends Person { def grade(yrs: Int) = "Senior" } | |
| defined class SalesPerson | |
| scala> val s = new SalesPerson | |
| s: SalesPerson = SalesPerson@3ce89cd5 | |
| scala> s.grade(yrs=1) |
add changes without whitespace
git diff -w --no-color | git apply --cached --ignore-whitespace
find deleted file
$ git log -- /path/to/file
display deleted file
| <?xml version="1.0" encoding="UTF-8"?> | |
| <project xmlns="http://maven.apache.org/POM/4.0.0" | |
| xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
| xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
| <modelVersion>4.0.0</modelVersion> | |
| <groupId>code</groupId> | |
| <artifactId>code</artifactId> | |
| <version>1.0-SNAPSHOT</version> |
| import com.squareup.okhttp.OkHttpClient | |
| import com.squareup.okhttp.mockwebserver.MockResponse | |
| import com.squareup.okhttp.mockwebserver.MockWebServer | |
| import com.squareup.okhttp.mockwebserver.RecordedRequest | |
| import spock.lang.Specification | |
| class OAuthTokenRequestSpec extends Specification { | |
| def POST = "POST" | |
| def anyClient = "123" |
| task createPom { | |
| apply plugin: 'maven' | |
| description "Generates pom.xml" | |
| pom { | |
| project { | |
| groupId 'com.example' | |
| artifactId 'example' | |
| version '0.0.1-SNAPSHOT' | |
| packaging 'aar' | |
| } |
| import android.content.Context; | |
| import android.view.LayoutInflater; | |
| import android.view.View; | |
| import android.view.ViewGroup; | |
| import android.widget.BaseAdapter; | |
| /** | |
| * An implementation of {@link BaseAdapter} which uses the new/bind pattern for its views. | |
| */ | |
| public abstract class BindableAdapter<T> extends BaseAdapter { |