Skip to content

Instantly share code, notes, and snippets.

View luisvonmuller's full-sized avatar
🏠
Working from home

Luís Von Müller luisvonmuller

🏠
Working from home
View GitHub Profile
CREATE TABLE heroes (
id SERIAL PRIMARY KEY,
fantasy_name VARCHAR NOT NULL,
real_name VARCHAR NULL,
spotted_photo TEXT NOT NULL,
strength_level INT NOT NULL DEFAULT 0
);
DROP TABLE heroes;
[package]
name = "heroes"
version = "0.1.0"
authors = ["luisvonmuller <luis@vonmuller.com.br>"]
edition = "2018"
[dependencies]
rocket = "0.4.5"
rocket_codegen = "0.4.5"
diesel = { version = "1.4.5", features = ["postgres"] }
#![feature(proc_macro_hygiene, decl_macro)]
/* Our extern crates */
#[macro_use]
extern crate diesel;
#[macro_use]
extern crate rocket;
extern crate dotenv;
/* Import macros and others */
use crate::schema::*;
/* For beeing able to serialize */
use serde::Serialize;
#[derive(Debug, Queryable, Serialize)]
pub struct Hero {
pub id: i32,
pub fantasy_name: String,
/* To be able to return Templates */
use rocket_contrib::templates::Template;
use std::collections::HashMap;
/* Diesel query builder */
use diesel::prelude::*;
/* Database macros */
use crate::schema::*;
match stxt {
stxt.contains("ana") => {
//dosomething
},
stxt.contains("woobs") => {}
}
Linkedin = {
config: {
scrollDelay: 500,
actionDelay: 500,
nextPageDelay: 2000,
// set to -1 for no limit
maxRequests: 100,
totalRequestsSent: 0,
},
init: function (data, config) {
Linkedin = {
config: {
scrollDelay: 500,
actionDelay: 500,
nextPageDelay: 2000,
// set to -1 for no limit
maxRequests: -1,
totalRequestsSent: 0,
},
init: function (data, config) {
@luisvonmuller
luisvonmuller / auto-invite-2021.js
Last active April 22, 2021 03:32
Simple auto invite code for LinkedIn.
var linkedinhoAutoInviter = class {
constructor(maxInvites, actionDelay, pageDelay, ScrollDelay) {
this.pageButtons = [];
this.alreadyInvited = 0;
this.maxInvites = maxInvites;
this.actionDelay = actionDelay;
this.pageDelay = pageDelay;