Skip to content

Instantly share code, notes, and snippets.

@daveteu
daveteu / chart.js
Created October 3, 2023 01:44 — forked from ashworth-zach/chart.js
candlestick chart with vanilla js
// let metaData = {
// information:"",
// symbol:"",
// lastRefresh:"",
// outputSize:"",
// timeZone:""
// }
let candleOhlcMappings = [];
@daveteu
daveteu / .bash_aliases
Created September 5, 2022 06:03 — forked from vratiu/.bash_aliases
Git shell coloring
# Customize BASH PS1 prompt to show current GIT repository and branch.
# by Mike Stewart - http://MediaDoneRight.com
# SETUP CONSTANTS
# Bunch-o-predefined colors. Makes reading code easier than escape sequences.
# I don't remember where I found this. o_O
# Reset
Color_Off="\[\033[0m\]" # Text Reset
@daveteu
daveteu / doveadmpw.go
Created August 21, 2022 08:06 — forked from osiloke/doveadmpw.go
This generate a dovecot password in golang, inspired by https://gist.github.com/garrettreid/8329796
package main
import (
"crypto/sha512"
"encoding/base64"
"fmt"
"math/rand"
"time"
)
@daveteu
daveteu / go-ssh-reverse-tunnel.go
Created June 10, 2022 10:37 — forked from codref/go-ssh-reverse-tunnel.go
Go SSH reverse tunnel implementation (SSH -R)
/*
Go-Language implementation of an SSH Reverse Tunnel, the equivalent of below SSH command:
ssh -R 8080:127.0.0.1:8080 operatore@146.148.22.123
which opens a tunnel between the two endpoints and permit to exchange information on this direction:
server:8080 -----> client:8080
@daveteu
daveteu / pre-push.sh
Last active July 17, 2021 14:54 — forked from vlucas/pre-push.sh
Prevent Pushes Directly to Master
#!/bin/bash
# @link https://gist.github.com/mattscilipoti/8424018
#
# Called by "git push" after it has checked the remote status,
# but before anything has been pushed.
#
# If this script exits with a non-zero status nothing will be pushed.
#
# Steps to install, from the root directory of your repo...