Skip to content

Instantly share code, notes, and snippets.

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

David Girón duhow

🏠
Working from home
View GitHub Profile
@duhow
duhow / barcode_scan_input.py
Created May 13, 2023 17:29
Forward scans from Binary Eye to input system (Remote Barcode Scanner)
# Author: ChatGPT-3.5
# SPDX-License-Identifier: WTFPL
# See: https://github.com/markusfisch/BinaryEye
# Description: Binary Eye forward scans to input content to system
# pip install autopygui
from http.server import BaseHTTPRequestHandler, HTTPServer
from urllib.parse import urlparse, parse_qs
import pyautogui
import sys
@duhow
duhow / resume.json
Created February 21, 2021 20:04
resume.json
{"basics":{"name":"David Giron Bueno","label":"AWS DevOps Engineer Professional","image":"https://avatars.githubusercontent.com/u/1145001?v=4","email":"","phone":"","url":"https://duhowpi.net","summary":"Always growing, willing to learn and help everyone on the road! ","profiles":[{"network":"gitconnected","username":"duhow","url":"https://gitconnected.com/duhow"},{"network":"GitHub","username":"duhow","url":"https://github.com/duhow"},{"network":"LinkedIn","url":"https://www.linkedin.com/in/duhowpi/","username":"duhowpi"}],"headline":"Sysadmin and Webmaster.","blog":null,"yearsOfExperience":6,"username":"duhow","locationAsString":"Sant Feliu de Llobregat, Barcelona","region":"Sant Feliu de Llobregat, Barcelona","karma":10,"id":"d66d76f1-c81c-47da-86e9-78c018eba909","followers":51,"following":32,"picture":"https://avatars.githubusercontent.com/u/1145001?v=4","website":"https://duhowpi.net"},"skills":[{"name":"AWS","level":"Advanced","keywords":["devops"],"rating":4,"yearsOfExperience":2},{"name":"Proxmox","le
@duhow
duhow / slack_backend.py
Created April 16, 2020 08:49
ErrBot Slack Events test
import collections
import copyreg
import json
import logging
import re
import sys
from time import sleep
import pprint
from functools import lru_cache
from typing import BinaryIO
@duhow
duhow / firehol_updater.sh
Last active March 7, 2020 15:54
Create or update ipset list from FireHOL IP list
#!/bin/bash
LIST="firehol_level1 firehol_level2"
URL="https://iplists.firehol.org/files/"
IPSET="/sbin/ipset"
function log(){
echo "["$(date "+%Y-%m-%d %H:%M:%S")"] $@"
}
@duhow
duhow / background.html
Created August 11, 2018 10:58
HTML Hi tech animated wallpaper
<html>
<head>
<title>Background: Panel Active</title>
<meta name="author" content="duhowpi">
<!--
Inspired by [Hi tech wallpapers #561074](https://wallpaper-gallery.net/single/hi-tech-wallpapers-22.html)
[Hack font](https://sourcefoundry.org/hack/)
[Loading bar](https://codepen.io/brunjo/pen/XJmbNz)
-->
<script integrity="sha256-FtWfRI+thWlNz2sB3SJbwKx5PgMyKIVgwHCTwa3biXc=" crossorigin="anonymous" src="https://cdn.jsdelivr.net/npm/vue@2.5.17/dist/vue.min.js" ></script>
@duhow
duhow / backup-tables.php
Last active July 3, 2018 12:43
PHP Table backup script
#!/usr/bin/php
<?php
$config = [
'host' => 'localhost',
'user' => 'root',
'pass' => '',
'db' => 'prestashop',
'prefix' => 'ps_',
'tables' => [
@duhow
duhow / CronExp.php
Created March 8, 2018 18:53
Cron Expression Match PHP
<?php
class CronExp {
public function match($expression, $time = NULL){
if(empty($time)){
$time = time() - time() % 60; // rounded to current minute
}elseif(is_string($time)){
$time = strtotime($time);
}
@duhow
duhow / email.php
Created February 22, 2017 12:02
PHP JSON - Check and validate emails
<?php
function http_json($status, $data = NULL, $httpcode = 200){
http_response_code($httpcode);
$out = json_encode(array('status' => $status, 'data' => $data));
die($out);
}
function fix_hostname($hostname){
$search = [
@duhow
duhow / keybase.md
Created December 31, 2016 12:39
Verify

Keybase proof

I hereby claim:

  • I am duhow on github.
  • I am duhow (https://keybase.io/duhow) on keybase.
  • I have a public key ASDbZdd8ZIlJfcDbCOkN1sBbr3lCu5vgzz9Bkrpf6XTRHwo

To claim this, I am signing this object:

@duhow
duhow / iitc-plugin-ingressKML-exporter.user.js
Created November 22, 2016 16:09 — forked from 5310/iitc-plugin-ingressKML-exporter.user.js
IITC plugin: Ingress KML Exporter
// ==UserScript==
// @id iitc-plugin-CSV@pad
// @name IITC plugin: Ingress KML Exporter
// @author Dron007 - enhanced by duhowpi
// @category Keys
// @version 1.0.20161122.02
// @namespace https://github.com/jonatkins/ingress-intel-total-conversion
// @description Exports portals currently in view for use with Google Map (KML Format Customized with more data).
// @include https://www.ingress.com/intel*
// @include http://www.ingress.com/intel*