Skip to content

Instantly share code, notes, and snippets.

Maarten Wolzak MaartenW

Block or report user

Report or block MaartenW

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
@MaartenW
MaartenW / howto-filemerge-git-osx.md
Last active Oct 2, 2018 — forked from bkeating/howto-filemerge-git-osx.md
HOWTO: Using FileMerge (opendiff) with Git on OSX
View howto-filemerge-git-osx.md

HOWTO: Using FileMerge (opendiff) with Git on OSX

FileMerge (opendiff) can really come in handy when you need to visually compare merging conflicts. Other times it's just a nice visual way to review your days work.

The following method works by creating a simple bash script (git-diff-cmd.sh) that sets us up with the proper command line arguments for Git to pass off files to FileMerge.

@MaartenW
MaartenW / EnsoAX.m
Last active Aug 22, 2016
Check if MacOS app has assistive access and request if it hasn't
View EnsoAX.m
- (BOOL)assistiveEnabled{
NSDictionary *options = @{(__bridge id)kAXTrustedCheckOptionPrompt: @NO};
BOOL aen = AXIsProcessTrustedWithOptions((__bridge CFDictionaryRef)options);
return aen;
}
- (void)handleAssistiveAccess{
if (![self assistiveEnabled]) {
NSAlert *alert = [[NSAlert alloc] init];
[alert addButtonWithTitle:@"Open preference panel"];
View mysqldump_pre_commit_hook.bash
#!/bin/bash
# Pre-commit hook to make a mysql dump right before committing and add it to the commit.
#
## Change the following values to suit your local setup.
# The name of a database user with read access to the database.
DBUSER=root
# The password associated with the above user. Leave commented if none.
#DBPASS=seekrit
# The database associated with this repository.
DBNAME=dplay
You can’t perform that action at this time.