Skip to content

Instantly share code, notes, and snippets.

João Vilaça vilaca

Block or report user

Report or block vilaca

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
View activity.py
import praw
import json
import time
from datetime import datetime
users = set()
bot = praw.Reddit(user_agent='',
client_id='Iq6Y7YogHPtmbA',
client_secret='',
@vilaca
vilaca / setup.sh
Last active Jul 14, 2019
docker ce and docker-compose install in centos7-64b
View setup.sh
yum -y update
yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
yum -y install yum-utils device-mapper-persistent-data lvm2 docker-ce
systemctl start docker
systemctl enable docker
yum -y install epel-release
yum -y install python-pip
pip install docker-compose
# pip install --upgrade pip
yum -y install wget unzip git
View gist:e40d4a2c3b2122a04969c7f645dc16b5
sudo yum install -y yum-utils device-mapper-persistent-data lvm2
sudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
sudo yum install docker-ce
sudo usermod -aG docker $(whoami)
sudo systemctl enable docker.service
sudo systemctl start docker.service
sudo yum install epel-release
sudo yum install -y python-pip
sudo pip install docker-compose
pip install --upgrade pip
View autocomplete-hack.html
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>jQuery UI Autocomplete - functionality</title>
<link rel="stylesheet" href="//code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css">
<link rel="stylesheet" href="/resources/demos/style.css">
<script src="https://code.jquery.com/jquery-2.1.0.js"></script>
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/jquery-ui.min.js"></script>
View 4-step-sequencer
#include "Volume3.h"
#define speakerPin 9
void setup() {
pinMode(2, OUTPUT);
pinMode(3, OUTPUT);
pinMode(4, OUTPUT);
pinMode(5, OUTPUT);
View 1bitter
/*
2 pots 1 speaker
BOM
Arduino Uno
10k A0
10k A1
View 2xPots1xSpeaker
/*
2 pots 1 speaker
BOM
Arduino Uno
10k A0
10k A1
View lispy.java
package eu.vilaca.lispy;
import java.util.AbstractList;
import java.util.ArrayDeque;
import java.util.ArrayList;
import java.util.Deque;
import java.util.List;
public class Parser {
View GetUploadedPlaylist.java
package eu.vilaca.youtube;
import java.io.IOException;
import com.google.api.client.http.HttpRequest;
import com.google.api.client.http.HttpRequestInitializer;
import com.google.api.client.http.javanet.NetHttpTransport;
import com.google.api.client.json.jackson2.JacksonFactory;
import com.google.api.services.youtube.YouTube;
import com.google.api.services.youtube.YouTube.Channels.List;
@vilaca
vilaca / AbstractResultSet.java
Created Jul 23, 2016
Wrapper for java.sql.ResultSet. All methods throw UnsupportedOperationException.
View AbstractResultSet.java
import java.io.InputStream;
import java.io.Reader;
import java.math.BigDecimal;
import java.net.URL;
import java.sql.Array;
import java.sql.Blob;
import java.sql.Clob;
import java.sql.Date;
import java.sql.NClob;
You can’t perform that action at this time.