Skip to content

Instantly share code, notes, and snippets.

View makevoid's full-sized avatar

Francesco 'makevoid' Canessa makevoid

View GitHub Profile
makevoid /
Last active April 28, 2024 09:40
Install Ruby 3 from soure on Debian (11)
# onliner usage:
# bash <(curl -s
set -xeuo pipefail
apt update -y
apt install -y build-essential git redis-server cmake vim wget curl libsqlite3-dev python3 apt-transport-https ca-certificates automake libtool libzlcore-dev libyaml-dev openssl libssl-dev zlib1g-dev libreadline-dev libcurl4-openssl-dev software-properties-common libreadline6-dev
mkdir -p ~/tmp
makevoid /
Last active February 3, 2024 02:06
Install docker on debian 12
# One line install:
# bash <(curl -s
# Add Docker's official GPG key:
sudo apt update -y
sudo apt install -y ca-certificates curl
sudo install -m 0755 -d /etc/apt/keyrings
sudo curl -fsSL -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc
makevoid /
Last active November 10, 2023 10:00
Install bitcoin - bitcoind - v - from binary - - quick install
set -xe
mkdir ~/tmp
cd ~/tmp
wget --no-check-certificate
# check the shasum
tar xvf bitcoin-
makevoid /
Last active August 14, 2023 13:57
Trying Langchain Reflector
# Prerequisite
# pip3 install git+
import langchain
from langchain.prompts.prompt import PromptTemplate
from langchain.prompts.base import BasePromptTemplate
from langchain.schema import AgentAction
from langchain.llms import OpenAI
from langchain.agents import load_tools, initialize_agent, AgentType
makevoid / hosted_example.txt
Created August 27, 2011 02:01
JQuery DOM HighLighter (it's a basic "Inspect element" simple implementation to mimic what webkit inspector and firebug do)
makevoid /
Last active April 4, 2023 09:57
trying out chatgpt plugins - zapier gmail and wolfram alpha

System prompt: You are an assistant, and I need help with some tasks.

You can use wolfram alpha to answer questions and get information about the world, you can use zapier to send emails.

I need help search for multiple anwers on statistical data, here is the process you need to follow to get the information I need:

PROCESS to get INFORMATION: first get the population of italy from wolfram alpha, second get the number of regions in italy from wolfram alpha, third divide the population of italy by the number of regions in italy by using wolfarm alpha and passing both values on the operation as input

makevoid / generate_image.rb
Last active November 5, 2022 07:48
Use OpenAI Image API to "draw" a ruby in Ruby
require "json"
require "bundler"
Bundler.require :default
# Gemfile:
# ---
# source ""
# gem "excon"
makevoid / install_node_10.js
Last active September 23, 2022 14:50
Install node 10
# bash <(curl -s
set -xe
sudo apt-get update -y
sudo apt-get install -y curl apt-transport-https ca-certificates
curl --fail -ssL -o setup-nodejs
makevoid / Multipart file upload ruby.rb
Created April 7, 2010 02:08
Multipart file upload ruby
# from:
# edited by makevoid,
URL = "http://localhost:3000/your_url"
params = {}
file =, "rb")
params["file[replay]"] = file
makevoid / gchart_offline.html
Created November 2, 2012 10:09
GChart offline example
How to use Google JS Visualization Api offline, step by step
this approach might work with other libraries loaded with google.load, after all it's still JavaScript!!!
<!DOCTYPE html>