Skip to content

Instantly share code, notes, and snippets.

Timan Rebel timanrebel

Block or report user

Report or block timanrebel

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
timanrebel / s3-invalidation.js
Created Apr 19, 2016 — forked from supinf/s3-invalidation.js
AWS Lambda script:: CloudFront Invalidations which are triggered by s3 events.
View s3-invalidation.js
console.log('Loading event');
var Q = require('q');
var aws = require('aws-sdk');
var cloudfront = new aws.CloudFront();
exports.handler = function (event, context) {
//_log('Received event: ', event);
var bucket = event.Records[0];
timanrebel /
Created Apr 10, 2016
Install pibus on OSMC
apt-get -y update
apt-get -y upgrade
apt-get -y install cron psmisc
crontab -l | grep pibus > /dev/null
if [ $? != "0" ]; then
timanrebel /
Last active Sep 14, 2015
SVN branches to Git branches on Mac OSX
git branch -r | grep -v tags | sed -Ene 's, *([^@]+)$,\1,p' | \
while read branch; \
do echo "git branch $branch $branch"; \
done | sh
timanrebel /
Last active Sep 14, 2015
SVN tags to Git tags on Mac OSX
git branch -r | sed -Ene 's, *tags/([^@]+)$,\1,p' | \
while read tag; do \
echo "git tag $tag 'tags/${tag}^'; git branch -r -d tags/$tag"; \
done | sh
View map.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View gist:ce6138f557180950498d
Verifying that +timanrebel is my openname (Bitcoin username).
timanrebel / gist:8505205
Created Jan 19, 2014
Platform and Density dependant images in Alloy widgets
View gist:8505205
but is not displaying with
timanrebel / gist:7596146
Created Nov 22, 2013
Doing reverse Oauth with Ti.Social
View gist:7596146
// First do reverse Auth call
var Social = require('');
var oauthString = '';
var jsOAuth = require('jsOAuth').OAuth;
var oauth = jsOAuth({
consumerKey: 'xxx',
consumerSecret: 'yyy'
timanrebel / index.xml
Created Jun 24, 2013
We use one codebase for our iOS and Android app and like to reuse as much code as possible. It is not possible however to use a Widget inside a <Menu> tag, but you can inside a <RightNavButton>. It would really simplify our lives if we could use Widgets and generalize our MenuBar buttons across platforms. I do get the following error however: [E…
View index.xml
<Widget src="sc.MenuBarButton" title="Save" onClick="onSave" />
<Widget src="sc.MenuBarButton" title="Save" onClick="onSave" />
timanrebel / index.js
Created Jun 5, 2013
Did you know it is possible to create custom XML tags in Alloy and use them?
View index.js
// <<MyElement> becomes Ti.UI.createMyElement, so that doesn't work
id: 'myId'
// But give it a namespace and all of a sudden, it is translated to:
id: 'mySecondId'
You can’t perform that action at this time.