Skip to content

Instantly share code, notes, and snippets.

View lcomino's full-sized avatar
🎯
Focusing

Lucas Comino lcomino

🎯
Focusing
View GitHub Profile
@lcomino
lcomino / getAdSenseUnits.js
Created December 10, 2020 11:45
Get all AdSense Banners from a website
;(function(){
let adunits = document.querySelectorAll('ins[data-ad-client]')
if(adunits && adunits.length > 0){
console.log(adunits)
}
})()
@lcomino
lcomino / menurc
Created January 6, 2020 17:16
Configuração atalhos do GIMP 2.8 igual ao do Photoshop
; This file installs keyboard shortcuts from Photoshop 6 in GIMP 2.8.
;
; Rename it to 'menurc' and place it into your personal GIMP directory:
; ~/.gimp-2.8 folder (Linux) or C:\Documents and Settings\<user>\.gimp-2.8
; folder (Windows).
;
; There is a web-page describing these keybindings at
; http://epierce.freeshell.org/gimp/gimp_ps.php
;
(gtk_accel_path "<Actions>/view/view-shrink-wrap" "")
@lcomino
lcomino / .gitconfig
Created October 30, 2019 17:17
.gitconfig
[user]
email = lcomino3d@gmail.com
name = Lucas Comino
[core]
editor = vim
autocrlf = input
[push]
default = simple
[alias]
changed = show --stat --name-only
@lcomino
lcomino / tail-powershell
Created October 7, 2019 12:12
Acompar log no Windows com Powershell
- Para checar as ultimas X linhas do arquivo
Get-Content SEU_ARQUIVO –Tail 30
- Para verificar o arquivo todo em tempo real (lento, pois lê o arquivo inteiro antes de chegar na última linha :/)
Get-Content SEU_ARQUIVO –Wait
- Para filtrar :) muito útil
@lcomino
lcomino / mov-to-webm-alpha
Created October 6, 2019 23:11
ffmpeg | converter mov com alpha para webm com alpha
ffmpeg -i "video.mov" -f webm -c:v libvpx -b:v 2M -acodec libvorbis -auto-alt-ref 0 "video.webm" -hide_banner
#!/bin/sh
# Usage: fetchall.sh branch ...
set -x
git fetch --all
for branch in "$@"; do
git checkout "$branch" || exit 1
git rebase "origin/$branch" || exit 1
done
Array.prototype.asyncForEach = async function (fn, scope) {
for(var i = 0, len = this.length; i < len; ++i) {
await fn.call(scope, this[i], i, this)
}
}
@lcomino
lcomino / Watch.md
Last active February 28, 2019 02:41
Run command each time the file changes (PowerShell)

#Script

function watch($file, $command) {
    $this_time = (get-item $file).LastWriteTime
    $last_time = $this_time
    while($true) {
        if ($last_time -ne $this_time) {
            $last_time = $this_time
            invoke-command $command
 }
@lcomino
lcomino / filelistsize.sh
Created July 5, 2018 19:36
Retorna o tamanho total dos arquivos
du -ch $files | tail -1 | cut -f 1
ex: du -ch *.zip | tail -1 | cut -f 1
@lcomino
lcomino / PASSOAPASSO.md
Last active May 25, 2018 03:48
Como votar na Ripped

Para votar na Ripped várias vezes utilize o proxy tor.

Instale o tor em seu linux

sudo apt-get install tor

Instale também o proxychains, ele que vai fazer a conexão com o tor quando ele estiver executando