Permalink
Browse files

Adding stashing article and doing some cleanup on code styles

  • Loading branch information...
1 parent d4ea6ad commit 3827de3003933d1cbcf6a472d18219e975aa903c @qrush qrush committed Jan 10, 2009
View
@@ -1,3 +1,4 @@
*~
_site/
*.swp
+.DS_Store
@@ -24,6 +24,7 @@
<div class="sidebar">
<h3 id="green">beginner</h3>
<div>
+ <a href="/2009/01/10/stashing-your-changes.html">stashing your changes</a>
{% for post in site.categories.beginner %}
<a href="{{ post.url }}">{{ post.title }}</a>
{% endfor %}
@@ -24,7 +24,10 @@ $ git remote show origin
Luckily, the command syntax for this is quite simple:
-@git checkout --track -b <local branch> <remote>/<tracked branch>@
+<pre>
+git checkout --track -b
+ <local branch> <remote>/<tracked branch>
+</pre>
So in my case, I used this command:
@@ -0,0 +1,26 @@
+---
+layout: post
+title: stashing your changes
+---
+
+h2. {{ page.title }}
+
+Stashing is a great way to pause what you're currently working on and come back to it later. For example, if you working on that awesome, brand new feature but someone just found a bug that you need to fix. Add your changes to the index using
+
+@git add .@
+
+Or add individual files to the index, your pick. Stash your changes away with:
+
+@git stash@
+
+And boom! You're back to your original working state. Got that bug fixed? Bring your work back with:
+
+@git stash apply@
+
+You can also do multiple layers of stashes, so make sure to use
+
+@git stash list@
+
+To check out all of your current ones. If you need to apply a stash from deeper in the stack, that's easy too. Here's how to apply the second stash you've got:
+
+<code>git stash apply stash@{1}</code>
View
@@ -19,7 +19,6 @@ a {
a:visited {
}
-pre { padding: 10px 15px; word-wrap: break-word; text-align: left; font-size: 90%; }
p {
text-align: left;
@@ -200,6 +199,9 @@ color: #aaa;
border: 1px solid #ddd;
background-color: #eef;
padding: 0 .4em;
+ text-align: left;
+ font-size: 90%;
+ margin: 0 15px;
}
#post code {

0 comments on commit 3827de3

Please sign in to comment.