std::set phoenix;
phoenix.key_comp();
This file contains 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
using Microsoft.Phone.Controls; | |
using System; | |
using System.Windows.Controls.Primitives; | |
/// <summary> | |
/// This class detects the pull gesture on a LongListSelector. How does it work? | |
/// | |
/// This class listens to the change of manipulation state of the LLS, to the MouseMove event | |
/// (in WP, this event is triggered when the user moves the finger through the screen) | |
/// and to the ItemRealized/Unrealized events. |
This file contains 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
using System; | |
using System.Collections; | |
using System.Windows; | |
using System.Windows.Controls.Primitives; | |
using System.Windows.Media; | |
namespace NCore.Helpers { | |
public class VisualStateHelper { | |
public static void HookEvent<T>( DependencyObject onElement, string inVisualStateGroup, EventHandler<VisualStateChangedEventArgs> setHandler) where T : DependencyObject { | |
T button = VisualStateHelper.FindSimpleVisualChild<T>(onElement); |
This file contains 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
brew update | |
brew versions FORMULA | |
cd `brew --prefix` | |
git checkout HASH Library/Formula/FORMULA.rb # use output of "brew versions" | |
brew install FORMULA | |
brew switch FORMULA VERSION | |
git checkout -- Library/Formula/FORMULA.rb # reset formula | |
## Example: Using Subversion 1.6.17 | |
# |
This file contains 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
CREATE TABLE cast_info AS | |
SELECT DISTINCT ci.movie_id, ci.person_id, cn.name AS char_name, rt.role, ci.note, ci.nr_order | |
FROM imdb.ex x, imdb.cast_info ci, imdb.role_type rt, imdb.char_name cn | |
WHERE x.id = ci.movie_id | |
AND ci.role_id = rt.id | |
AND ci.person_role = cn.id; |
This file contains 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
var jq = document.createElement('script'); | |
jq.src = "//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"; | |
document.getElementsByTagName('head')[0].appendChild(jq); | |
// ... give time for script to load, then type. | |
jQuery.noConflict(); | |
// Include latest version | |
javascript:if(!window.jQuery||confirm('Overwrite\x20current\x20version?\x20v'+jQuery.fn.jquery))(function(d,s){s=d.createElement('script');s.src='http://code.jquery.com/jquery.js';(d.head||d.documentElement).appendChild(s)})(document); | |
// Include specific version |
This file contains 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
brew rm FORMULA | |
brew rm $(join <(brew leaves) <(brew deps FORMULA)) | |
Run the last line a until `echo $(join <(brew leaves) <(brew deps FORMULA))` returns nothing OR until the last line informs you that `This command requires a keg argument`. |
This file contains 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 fetch origin pull/2/head | |
git checkout -b pullrequest FETCH_HEAD | |
OR | |
git fetch origin pull/<#>/head:<local_branch_name> |
This file contains 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
If the commit you want to fix isn’t the most recent one: | |
git rebase --interactive $parent_of_flawed_commit | |
If you want to fix several flawed commits, pass the parent of the oldest one of them. | |
An editor will come up, with a list of all commits since the one you gave. | |
Change pick to reword (or on old versions of Git, to edit) in front of any commits you want to fix. | |
Once you save, Git will replay the listed commits. |
This file contains 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
ls *.<file-ext> | entr pandoc *.<file-ext> -o <output-name> |
OlderNewer