Skip to content

Instantly share code, notes, and snippets.

@edgartaor
edgartaor / file_count.sh
Last active March 8, 2021 10:43
File count and file size of a directory
# Taken from https://superuser.com/a/1321654
echo "File Count Dir Size Directory"
echo "---------- ---------- -------------------------"
for d in *; do
if [[ -d $d ]]; then
echo `find $d -type f | wc -l` | awk '{printf "%10s ", $0;}'
echo `du -h --max-depth=0 $d` | cut -d\ -f 1 $1 | awk '{printf "%10s ", $0;}'
echo $d
fi
done | sort -n -k1
0.0.0.0 aamsqec.com
0.0.0.0 aapwdqx.in
0.0.0.0 aawgiow.biz
0.0.0.0 acfwftg.com
0.0.0.0 adbnsrt.me
0.0.0.0 aekqtdz.org
0.0.0.0 aemmfiu.cc
0.0.0.0 afcytwc.com
0.0.0.0 afgnckn.com
0.0.0.0 agcdnsk.org
aamsqec.com
aapwdqx.in
aawgiow.biz
acfwftg.com
adbnsrt.me
aekqtdz.org
aemmfiu.cc
afcytwc.com
afgnckn.com
agcdnsk.org
@edgartaor
edgartaor / mylobot_list.txt
Created May 26, 2020 04:55
Mylobot list domains
aamsqec.com
aapwdqx.in
aawgiow.biz
acfwftg.com
adbnsrt.me
aekqtdz.org
aemmfiu.cc
afcytwc.com
afgnckn.com
@edgartaor
edgartaor / webstoemp-gulpfile.js
Created July 3, 2019 01:38 — forked from jeromecoupe/webstoemp-gulpfile.js
Gulp 4 sample gulpfile.js. For a full explanation, have a look at https://www.webstoemp.com/blog/switching-to-gulp4/
"use strict";
// Load plugins
const autoprefixer = require("autoprefixer");
const browsersync = require("browser-sync").create();
const cp = require("child_process");
const cssnano = require("cssnano");
const del = require("del");
const eslint = require("gulp-eslint");
const gulp = require("gulp");
@edgartaor
edgartaor / ssh tunnel
Created August 18, 2018 02:44
Create a ssh tunnel for a custom port
ssh -nNT -L 0.0.0.0:9000:localhost:4000 user@remoteserver
This allow to access localhost:9000 on your local machine and see what it's been served on the remoteserver on the port 4000
#!/usr/bin/python
# -*- coding: utf-8 -*-
import logging
import argparse
import codecs
import configparser
import errno
import glob
from operator import itemgetter
@edgartaor
edgartaor / docker-compose.yml
Created August 13, 2017 21:38
Wallabag + mariadb + redis docker-compose file
version: '2'
services:
wallabag:
image: wallabag/wallabag:latest
restart: always
ports:
- "8888:80"
tty: true
links:
- wallabag-db:wallabag-db
@edgartaor
edgartaor / Start-Vagrant.bat
Created September 24, 2016 01:14 — forked from Iristyle/Start-Vagrant.bat
Windows startup script to fire up a Vagrant VM safely on boot (using Run registry key for instance)
ECHO OFF
cd /d %~dp0
for /f "tokens=2* delims= " %%F IN ('vagrant status ^| find /I "default"') DO (SET "STATE=%%F%%G")
ECHO Close this window if it remains open, and http://localhost:8081 is responsive
IF "%STATE%" NEQ "saved" (
ECHO Starting Vagrant VM from powered down state...
vagrant up
) ELSE (
Ping all AWS EC2 IPs from http://ec2-reachability.amazonaws.com/