Skip to content

Instantly share code, notes, and snippets.

View nanoant's full-sized avatar

Adam Strzelecki nanoant

View GitHub Profile
#!/bin/bash
exec cmake -GNinja "$HOME/llvm" \
-DCMAKE_AR=$HOME/osxcross/target/bin/x86_64-apple-darwin13-ar \
-DCMAKE_C_COMPILER=$HOME/osxcross/target/bin/x86_64-apple-darwin13-clang \
-DCMAKE_CXX_COMPILER=$HOME/osxcross/target/bin/x86_64-apple-darwin13-clang++ \
-DLLVM_ENABLE_LIBCXX:BOOL=ON \
-DLLVM_DEFAULT_TARGET_TRIPLE=x86_64-apple-darwin13 \
-DLLVM_TARGET_ARCH=x86_64 \
-DCMAKE_CROSSCOMPILING:BOOL=ON \
-DLLVM_TABLEGEN=/usr/bin/llvm-tblgen-3.6 \
@nanoant
nanoant / dmg.sh
Created September 16, 2014 23:02
DMG builder script
#!/bin/bash
# set -e
#
# Builds .dmg installer
#
# Copyright (C) 2013-2014 Adam Strzelecki
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
@nanoant
nanoant / gitlab-README-default.patch
Created February 12, 2014 10:36
Show README on project entry in GitLab
diff --git a/app/views/projects/show.html.haml b/app/views/projects/show.html.haml
index 59075ab..c2af1b1 100644
--- a/app/views/projects/show.html.haml
+++ b/app/views/projects/show.html.haml
@@ -2,10 +2,16 @@
.row
.col-md-9
- = render "events/event_last_push", event: @last_push
- = render 'shared/event_filter'
@nanoant
nanoant / gist:7699098
Created November 28, 2013 22:46
Open in Terminal for Forklift by me
-- OpenInTerminal.applescript
-- ForkLift
-- Created by ONO
tell application "Terminal"
activate
set windowCount to (count of the windows)
@nanoant
nanoant / fl
Last active October 8, 2015 09:38
Open folder in ForkLift.app from console
#!/bin/bash
#
# Open folder in ForkLift.app from console
# Author: Adam Strzelecki nanoant.com
#
# Usage:
# fl [<folder>]
#
# Opens specified directory or current working directory in ForkLift.app
#
@nanoant
nanoant / test.c
Created June 29, 2012 17:23
Parallels for Mac 7 having problem with ICC AVX optimized code
/*
Now let's try compile and benchmark it:
$ icc -v
icc version 13.0.0 (gcc version 4.6.0 compatibility)
Let's try without AVX set (just up to SSE4.2):
$ icc -march=corei7 test.c -lm && time ./a.out
r=171828183.102
@nanoant
nanoant / sidebar.m
Created September 27, 2011 10:52
Change your Lion sidebar item icons
// (l) copyleft 2011 Adam Strzelecki nanoant.com
//
// Usage:
// sidebar - to see the ids of your favorite sidebar items
// sidebar ItemName - to remove item specific icon
// sidebar ItemName sbBj - to set specific item icon, see:
// /System/Library/CoreServices/CoreTypes.bundle/Contents/Info.plist
// Compile it with:
// gcc -o sidebar sidebar.m -F /Developer/SDKs/MacOSX10.7.sdk/System/Library/Frameworks/CoreServices.framework/Frameworks -framework Foundation -framework CoreServices
//