Skip to content

Instantly share code, notes, and snippets.

View pablojimeno's full-sized avatar
🔬
learning

Pablo Jimeno pablojimeno

🔬
learning
View GitHub Profile
@pablojimeno
pablojimeno / clickable-element.html
Created October 17, 2015 13:56 — forked from scottmagdalein/clickable-element.html
Make the Mailchimp Subscriber popup appear on click
<!-- This is the HTML element that, when clicked, will cause the popup to appear. -->
<button id="open-popup">Subscribe to our mailing list</button>
@pablojimeno
pablojimeno / ml-ruby.md
Created May 16, 2016 16:00 — forked from gbuesing/ml-ruby.md
Resources for Machine Learning in Ruby

Resources for Machine Learning in Ruby

Gems

@pablojimeno
pablojimeno / docx_to_markdown.xslt
Created December 2, 2016 18:01 — forked from PLTGit/docx_to_markdown.xslt
Super Rudimentary DOCX -> Markdown XSL Template - not full featured, and very MSWord specific
<?xml version="1.0"?>
<xsl:stylesheet
version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main"
>
<xsl:output method="text"/>
<xsl:template match="//w:p">
@pablojimeno
pablojimeno / gibbon.rb
Created January 10, 2018 12:06 — forked from apeckham/gibbon.rb
Create and send a Mailchimp campaign with gibbon, using content sections from ActionView templates
gibbon = Gibbon::API.new
view = ActionView::Base.new('app/views/', {instance_variable_for_templates: 5324}, ActionController::Base.new)
campaign = gibbon.campaigns.create(
type: "regular",
options: {
list_id: 'xxxy',
from_email: 'you@example.com',
from_name: 'Your From',
subject: "the subject",
@pablojimeno
pablojimeno / gist:dfe01c295a19cbce9700982df5199336
Created November 14, 2018 17:08 — forked from mayoff/gist:1138816
AppleScript to make Google Chrome open/reload a URL
(* To the extent possible under law, Rob Mayoff has waived all copyright and related or neighboring rights to “AppleScript to make Google Chrome open/reload a URL”. This work is published from: United States. https://creativecommons.org/publicdomain/zero/1.0/ *)
tell application "Google Chrome"
activate
set theUrl to "http://tycho.usno.navy.mil/cgi-bin/timer.pl"
if (count every window) = 0 then
make new window
end if
set found to false
@pablojimeno
pablojimeno / bluetooth-restart.sh
Created January 28, 2020 18:03 — forked from thiagoghisi/bluetooth-restart.sh
Script for Mac OSX to Restart Bluetooth service & Reconnect all recently paired devices
#!/bin/bash
echo "Restarting bluetooth service..."
blueutil -p 0 && sleep 1 && blueutil -p 1
echo "Waiting bluetooth service to be restored..."
until blueutil -p | grep "1" >/dev/null; do sleep 1; done
echo "Searching for devices not connected..."
devices=($(blueutil --paired | grep "not connected" | awk -F '[ ,]' '{print $2}'))
@pablojimeno
pablojimeno / # openssl@1.0 - 2020-09-27_14-09-58.txt
Created October 8, 2020 16:32
openssl@1.0 (rbenv/tap/openssl@1.0) on macOS 10.15.7 - Homebrew build logs
Homebrew build logs for rbenv/tap/openssl@1.0 on macOS 10.15.7
Build date: 2020-09-27 14:09:58
function onOpen()
{
var ui = SpreadsheetApp.getUi();
ui.createMenu('Process')
.addItem('Approve', 'doApprove')
.addToUi();
}
function doApprove()
{
@pablojimeno
pablojimeno / vtt2text.py
Created July 27, 2021 09:59 — forked from glasslion/vtt2text.py
This script convert youtube subtitle file(vtt) to plain text.
"""
Convert YouTube subtitles(vtt) to human readable text.
Download only subtitles from YouTube with youtube-dl:
youtube-dl --skip-download --convert-subs vtt <video_url>
Note that default subtitle format provided by YouTube is ass, which is hard
to process with simple regex. Luckily youtube-dl can convert ass to vtt, which
is easier to process.
@pablojimeno
pablojimeno / README.md
Created January 25, 2022 08:36 — forked from joelverhagen/README.md
Jekyll YouTube Embed Plugin

This is a plugin meant for Jekyll.

Example use:

Easily embed a YouTube video. Just drop this file in your _plugins directory.

{% youtube oHg5SJYRHA0 %}