Skip to content

Instantly share code, notes, and snippets.

Iñaki Abete inakiabt

Block or report user

Report or block inakiabt

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
@inakiabt
inakiabt / 0_reuse_code.js
Created May 31, 2014
Here are some things you can do with Gists in GistBox.
View 0_reuse_code.js
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
View InstagramMgr.js
/**
*
* this code was inspired by the work done by David Riccitelli
*
* Copyright 2011 Aaron K. Saunders, Clearly Innovative Inc
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
@inakiabt
inakiabt / extjs-capture.js
Created Mar 20, 2012 — forked from revolunet/extjs-capture.js
ExtJs debug : capture all events
View extjs-capture.js
// to capture ALL events use:
Ext.util.Observable.prototype.fireEvent = Ext.Function.createInterceptor(Ext.util.Observable.prototype.fireEvent, function(evt) {
var a=arguments;
console.log(this,' fired event ',evt,' with args ',Array.prototype.slice.call(a,1,a.length));
return true;
});
// to capture events for a particular component:
Ext.util.Observable.capture(
Ext.getCmp('my-comp'),
View nxfetch.sh
#!/bin/bash
# Argument = -h -v -i groupId:artifactId:version -c classifier -p packaging -r repository
#shopt -o -s xtrace
# Define Nexus Configuration
NEXUS_BASE=http://repository.example.com:8081/nexus
REST_PATH=/service/local
ART_REDIR=/artifact/maven/redirect
View SupervisedFileConumer.scala
// ###########################################################
//
// Demonstrates how to supervise an Akka consumer actor.
//
// The consumer consumes messages from a file endpoint:
// - successful message processing by the consumer will
// positively acknowledge the message receipt, causing
// the file endpoint to delete the file.
// - an exception during message processing will cause a
// supervisor to restart the consumer. Before restart,
@inakiabt
inakiabt / MemcacheEx.php
Created Feb 16, 2011
MemcacheEx - Memcache extension to support setMulti and getMulti methods
View MemcacheEx.php
<?php
class MemcacheEx extends Memcache
{
public function getMulti($keys)
{
$results = array();
if ($keys) {
foreach ($keys as $key) {
$cache = parent::get($key);
if ($cache !== false) {
View aws_usage.py
#!/usr/bin/env python
"""
A script to query the Amazon Web Services usage reports programmatically.
Ideally this wouldn't exist, and Amazon would provide an API we can use
instead, but hey - that's life.
Basically takes your AWS account username and password, logs into the
website as you, and grabs the data out. Always gets the 'All Usage Types'
You can’t perform that action at this time.