Skip to content

Instantly share code, notes, and snippets.

Marc Hughes marc-hughes

Block or report user

Report or block marc-hughes

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@marc-hughes
marc-hughes / git-branch-delete.sh
Created Oct 9, 2017 — forked from JadedEvan/git-branch-delete.sh
An interactive bash shell script to delete remote git branches
View git-branch-delete.sh
#!/bin/bash
# An interactive script that allows you to delete multiple remote branches from
# a git repository with confirmation before deletion.
#
# Provide the path to the git repo as an argument to the script or it will
# prompt you for the path to the repo
#
# @version 0.1
# @author Evan Reeves <develop@evanreeves.com>
View gist:dfebccd90f9be324fe73eb30c39d0857
#!/bin/sh
#
# /etc/rc.d/init.d/swap
#
# Daemon for swap
#
# chkconfig: - 05 99
# description: Enable swap space
### BEGIN INIT INFO
View .gitconfig
[alias]
cleanfeature = branch --merged | grep "feature/" | xargs -n 1 git branch -d
[merge]
tool = p4mergetool
renameLimit = 8000
[mergetool "p4mergetool"]
cmd = /Applications/p4merge.app/Contents/Resources/launchp4merge $PWD/$BASE $PWD/$REMOTE $PWD/$LOCAL $PWD/$MERGED
trustExitCode = false
[mergetool]
keepBackup = false
@marc-hughes
marc-hughes / gist:c66f68fbbac9ca61e74644f5751c5df7
Created May 3, 2016
Git Alias to clean merged feature branches
View gist:c66f68fbbac9ca61e74644f5751c5df7
# Put this into .gitignore:
[alias]
cleanfeature = branch --merged | grep "feature/" | xargs -n 1 git branch -d
# Then, run git cleanfeature - it will delete every branch with name containing feature/ that has been fully merged into the current branch.
We couldn’t find that file to show.
View nomigrations.py
class DisableMigrations(object):
def __contains__(self, item):
return True
def __getitem__(self, item):
return "notmigrations"
View attachments.json
[
{
attachment_url: "",
created: "2015-10-14T08:46:05",
url: "https://scrumdo-attachments.s3.amazonaws.com:443/projects%2Fstory%2Fattachments_v2%2F169800_subtasks.png?Expires=1444828586&AWSAccessKeyId=AKIAJGOQ7F37VIQQCUYQ&Signature=F6CN3qbDUE%2F5ZrNAlI9dcgeki3Q%3D",
story_id: 169800,
id: 17506,
modified: "2015-10-14T08:46:05",
filename: "169800_subtasks.png",
attachment_name: "",
View kanbancell.dart
@NgController(
selector: '[kanban-cell]',
publishAs: 'cell'
)
class KanbanCell {
@NgTwoWay('card-id')
int cardId;
}
View gist:10918197
<tr>
<td>
<ul>
<li kanban-cell
card-id="state.card"
ng-repeat="state in ctrl.game.states | filter:{column:'backlog'} "
ng-include="/boardcomponents/kanbancell.html">
</li>
</ul>
@marc-hughes
marc-hughes / debouce.dart
Last active Nov 1, 2018
debounce function for dart
View debouce.dart
library debounce;
Map timeouts = {};
void debounce(int timeoutMS, Function target, List arguments) {
if(timeouts.containsKey(target)) {
timeouts[target].cancel();
}
Timer timer = new Timer(new Duration(milliseconds: timeoutMS), () {
You can’t perform that action at this time.