Skip to content

Instantly share code, notes, and snippets.

View lardissone's full-sized avatar

Leandro Ardissone lardissone

View GitHub Profile
activate application "SystemUIServer"
tell application "System Events"
tell process "SystemUIServer"
-- Working CONNECT Script. Goes through the following:
-- Clicks on Bluetooth Menu (OSX Top Menu Bar)
-- => Clicks on SX-991 Item
-- => Clicks on Connect Item
set btMenu to (menu bar item 1 of menu bar 1 whose description contains "bluetooth")
tell btMenu
click
Verifying my Blockstack ID is secured with the address 1GUMzJqJpGXQ43nTvd37vuS35k3WTxkRxU https://explorer.blockstack.org/address/1GUMzJqJpGXQ43nTvd37vuS35k3WTxkRxU
Verifying my identity on Peepeth.com 0x6451cfa60263829d85aa3cafb5b308d5962dcc6a
@lardissone
lardissone / README.md
Created July 5, 2018 14:34
Export Trakt watched episodes and movies

Export Trackt watched history for episodes and movies

Dependencies

npm install puppeteer

Modify your username and the amount of pages you see in Trakt website in at the top of each .js file.

Run

@lardissone
lardissone / buckets_size.py
Created February 14, 2018 18:12
List all S3 buckets and storage size
import boto3
s3 = boto3.resource('s3')
def human_size(bytes, units=[' bytes','KB','MB','GB','TB', 'PB', 'EB']):
return str(bytes) + units[0] if bytes < 1024 else human_size(bytes>>10, units[1:])
def get_bucket_size(balde):
bucket = s3.Bucket(balde)
total_size = 0

Keybase proof

I hereby claim:

  • I am lardissone on github.
  • I am lardissone (https://keybase.io/lardissone) on keybase.
  • I have a public key whose fingerprint is 174A 732C EC67 C883 F036 4EB9 DF3B E500 5F74 7F84

To claim this, I am signing this object:

var request = require('request');
var token = 'your:token-here',
baseUrl = 'https://api.telegram.org/bot' + token + '/';
module.exports = function(context, cb) {
var command = context.data.message.text;
var chat = context.data.message.chat.id;
// intercept command /hello
module.exports = exports = function relativeImageUrl(schema, options) {
var relField = options.relativeUrlField || 'relUrl',
field = {};
field[relField] = String;
schema.add(field);
schema.pre('save', function(next) {
var photoField = options.absoluteUrlField || 'large',
removeStr = process.env.PWD + '/client',
class Author(models.Model):
name = models.CharField(max_length=200)
class Book(models.Model):
title = models.CharField(max_length=200)
author = models.ForeignKey(Author)
# here it is:
# this should start from 1 for the same author
# examples:
# author1 | 1
@lardissone
lardissone / instagram.ipynb
Created February 9, 2015 22:21
Instagram scrapper
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.