👨👩👦
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git ls-files -ci --exclude-standard -z | xargs -0 git rm --cached | |
### Alias in .zshrc or .bashrc because too hard to remember | |
# alias ungit="git ls-files -ci --exclude-standard -z | xargs -0 git rm --cached" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class SomeFragment extends Fragment { | |
MapView mapView; | |
GoogleMap map; | |
@Override | |
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { | |
View v = inflater.inflate(R.layout.some_layout, container, false); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private int id; | |
private String name; | |
private String description; | |
private double fee; | |
private int startAge; | |
private int endAge; | |
private int size; | |
private boolean adultOnly; | |
private int min; | |
private int max; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @param cookie the cookie to set | |
*/ | |
public String setCookie(HttpResponse response, Context context) { | |
for (int i = 0; i < response.getAllHeaders().length; ++i) { | |
Log.d(Constants.LOG, response.getAllHeaders()[i].getName() + " - " + response.getAllHeaders()[i].getValue()); | |
} | |
Header[] cookies = response.getHeaders("Set-Cookie"); | |
if (cookies.length > 0) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
get "/:filename" do | |
AWS::S3::Base.establish_connection!( | |
:access_key_id => ENV['S3_KEY'], | |
:secret_access_key => ENV['S3_SECRET']) | |
redirect AWS::S3::S3Object.url_for(params[:filename], ENV['S3_BUCKET']) | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
post "/" do | |
logger.debug "Params - " + params.to_s | |
photo = nil | |
caption = params[:caption] | |
params.each_value do |file| | |
unless file && file.is_a?(Hash) && (tmpfile = file[:tempfile]) && (name = file[:filename]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.app.AlertDialog; | |
import android.app.ProgressDialog; | |
import android.content.Context; | |
import android.content.DialogInterface; | |
import java.util.HashMap; | |
import java.util.Map; | |
public class AlertUtils { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GIT | |
remote: git://github.com/joshdholtz/html-pager.git | |
revision: 537e14e70f91b8fcfd7238f6e5dfd62a86c25a05 | |
specs: | |
html_pager (0.0.2) | |
haml (>= 3.1.7) | |
GEM | |
remote: http://rubygems.org/ | |
specs: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// ProtocolModel.h | |
// | |
// Created by Josh Holtz on 2/5/13. | |
// Copyright (c) 2013 RokkinCat. All rights reserved. | |
// | |
#import <Foundation/Foundation.h> | |
@interface ProtocolModel : NSObject |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | |
package="com.joshdholtz.sentry" | |
android:versionCode="1" | |
android:versionName="1.0" > | |
<uses-sdk | |
android:minSdkVersion="8" | |
android:targetSdkVersion="8" /> | |