Skip to content

Instantly share code, notes, and snippets.

@piyushdubey
piyushdubey / Git Workflow
Created February 12, 2013 05:39
A very simplified Git Workflow that's easy to follow.. using git from command line is a lot of fun and seeing the code getting merged and branched using tools like GitX for mac, GitG for Gnome linux based systems and tortoiseGit for windows is a great way to learn git fundamentals and understand the workflow.
When you start working on a new feature, you must create a new local branch on your machine
$git branch <feature-name>
$git checkout <feature-name>
Then you work on it, commit as often as possible
Hack...
git commit -a -m "xxx "
Hack ...
git commit -a -m "xxxx "
@piyushdubey
piyushdubey / Programming Blogs
Created April 4, 2014 15:42
Programming blogs
<li><a href="http://www.alistapart.com/articles/">A List Apart &#8212; for website builders</a></li>
<li><a href="http://abstrusegoose.com/">Abstruse Goose &#8212; my favorite comic</a></li>
<li><a href="http://al3x.net/">Alex Payne &#8212; technology rambling</a></li>
<li><a href="http://dashes.com/anil/">Anil Dash &#8212; on culture, apple &amp; design</a></li>
<li><a href="http://weblogs.mozillazine.org/asa/">Asa Dotzler &#8212; on mozilla &amp; software</a></li>
<li><a href="http://www.azarask.in/blog/">Aza Raskin &#8211; on design &amp; firefox</a></li>
<li><a href="http://christophzillgens.com/en/">Christoph Zillgens &#8212; interface design</a></li>
<li><a href="http://cssremix.com/">CSS Remix &#8212; gorgeous designs</a></li>
<li><a href="http://css-tricks.com/">CSS Tricks</a></li>
### Keybase proof
I hereby claim:
* I am piyushdubey on github.
* I am piyushdubey (https://keybase.io/piyushdubey) on keybase.
* I have a public key whose fingerprint is 83E6 DB6B 76EF 4CC8 16FD 9BD6 11F1 1E71 6801 68F6
To claim this, I am signing this object:
private List<StudentResponseDetail> getStudentResponseDetail() {
String jsonArray = "[{id:null,section:1,sequence:1,title:null,visited:false,answered:false,answerRequired:true,responses:null,lastUpdate:null},{id:null,section:1,sequence:2,title:null,visited:false,answered:false,answerRequired:true,responses:null,lastUpdate:null},{id:null,section:1,sequence:3,title:null,visited:false,answered:false,answerRequired:false,responses:null,lastUpdate:null},{id:null,section:1,sequence:4,title:null,visited:false,answered:false,answerRequired:true,responses:null,lastUpdate:null},{id:null,section:1,sequence:5,title:null,visited:false,answered:false,answerRequired:false,responses:null,lastUpdate:null},{id:null,section:1,sequence:6,title:null,visited:false,answered:false,answerRequired:true,responses:null,lastUpdate:null},{id:null,section:1,sequence:7,title:null,visited:false,answered:false,answerRequired:true,responses:null,lastUpdate:null},{id:null,section:1,sequence:8,title:null,visited:false,answered:false,answerRequ
public class BST {
public boolean insert(BinaryTreeNode root, String value) {
if(root == null) {
root = new BinaryTreeNode(value, null, null);
} else {
if(root.value.compareTo(value) > 0) {
insert(root.left, value);
} else if(root.value.compareTo(value) <= 0) {
insert(root.right, value);
}
@piyushdubey
piyushdubey / extend_path.fish
Created June 16, 2016 08:20 — forked from BenAtWide/extend_path.fish
add a component to $PATH in the fish shell
# This is the syntax to add a component to $PATH in the fish shell
set -gx PATH /usr/local/mysql/bin/ $PATH
# Note the space between the new component and the existing $PATH variable.
node: Platform built on V8 to build network applications
git: Distributed revision control system
wget: Internet file retriever
yarn: JavaScript package manager
python3: Interpreted, interactive, object-oriented programming language
coreutils: GNU File, Shell, and Text utilities
pkg-config: Manage compile and link flags for libraries
chromedriver: Tool for automated testing of webapps across many browsers
awscli: Official Amazon AWS command-line interface
automake: Tool for generating GNU Standards-compliant Makefiles