Skip to content

Instantly share code, notes, and snippets.

View vensauro's full-sized avatar
🤠
having fun

Ivens Joris vensauro

🤠
having fun
View GitHub Profile
syntax = "proto3";
message Person {
string name = 1;
int32 id = 2;
string email = 3;
}
message AddressBook {
repeated Person people = 1;
/**
* Performs a deep merge of `source` into `target`.
* Mutates `target` only but not its objects and arrays.
*
* @author inspired by [jhildenbiddle](https://stackoverflow.com/a/48218209).
*/
function mergeDeep(target, source) {
const isObject = (obj) => obj && typeof obj === 'object';
if (!isObject(target) || !isObject(source)) {
function elementReady(selector) {
return new Promise((resolve, reject) => {
let el = document.querySelector(selector);
if (el) {
resolve(el);
return;
}
new MutationObserver((mutationRecords, observer) => {
// Query for elements matching the specified selector
Array.from(document.querySelectorAll(selector)).forEach((element) => {
const puppeteer = require('puppeteer')
const screenshot = 'github.png';
const url_inicial = "https://govbahia.consiglog.com.br/"
const login_name = "********"
const login_password = "********"
const browser = await puppeteer.launch({
headless: true
})
Level 4
find inhere/ -exec file {} \;
# file, du, find, -exec
#!/bin/bash
sleep 12
/usr/bin/amixer -c 0 set Headphone playback 100% unmute
notify-send 'Som ligado' 'configurado'
exit
const axios = require('axios')
const express = require('express')
const app = express();
const infojr_ID = 3340354
const token = 'ysqqTo9sisETpFy47xfh';
let userID = 2392008;
const gitlab = `https://gitlab.com/api/v4`
@vensauro
vensauro / .zshrc
Last active September 11, 2022 00:17
Oh my ZSH configuration
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.
# Initialization code that may require console input (password prompts, [y/n]
# confirmations, etc.) must go above this block, everything else may go below.
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
fi
export ZSH="/home/vensauro/.oh-my-zsh"
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
typedef struct node
{
int key;
struct node *next;
} Node;
@vensauro
vensauro / pure-redux-with-react.js
Created April 7, 2019 03:04
Aprendendo Redux base
import React, { Component } from 'react'
import { createStore } from 'redux'
const types = {
INCREMENT: 'INCREMENT',
DECREMENT: 'DECREMENT'
}
function reducer(state, action) {
switch(action.type){