Skip to content

Instantly share code, notes, and snippets.

View cristianounix's full-sized avatar
👨‍🚀
Focusing

Cristiano Oliveira cristianounix

👨‍🚀
Focusing
View GitHub Profile
# -*- coding:utf-8 -*-
import scrapy
from scrapy.exceptions import CloseSpider
class LoginSpider(scrapy.Spider):
name = 'login-spider'
start_urls = ['http://quotes.toscrape.com/login']
def parse(self, response):
@cristianounix
cristianounix / QSQlite3
Last active August 29, 2015 14:23 — forked from daltheman/QSQlite3
//
// QSQLite3.swift
// SQLiteWrapper
//
// Created by Danilo Altheman on 24/06/15.
// Copyright © 2015 Quaddro - Danilo Altheman. All rights reserved.
/* Usage:
// Open or create a Database
let database = QSQLite3(path: NSHomeDirectory() + "/Documents/database.sqlite")

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
// Requires: http://cloud.github.com/downloads/harthur/brain/brain-0.6.0.js
// Contrived example using string "0" as output.
var net = new brain.NeuralNetwork();
net.train([{input: [0, 0], output: {"F":1}},
{input: [0, 1], output: {"1":1}},
{input: [1, 0], output: {"1":1}},
{input: [1, 1], output: {"0":1}}]);
/*
DESCRIPTION
-----------
Use NodeJS to read RFID ids through the USB serial stream. Code derived from this forum:
http://groups.google.com/group/nodejs/browse_thread/thread/e2b071b6a70a6eb1/086ec7fcb5036699
CODE REPOSITORY
---------------
https://gist.github.com/806605