Skip to content

Instantly share code, notes, and snippets.

View texascloud's full-sized avatar

Joshua Hurt texascloud

View GitHub Profile
@kotakanbe
kotakanbe / ipcalc.go
Created September 17, 2015 02:59
get all IP address from CIDR in golang
package main
import (
"net"
"os/exec"
"github.com/k0kubun/pp"
)
func Hosts(cidr string) ([]string, error) {
@swarminglogic
swarminglogic / vlcopen.sh
Last active December 13, 2018 22:25
Download video URL (youtube-dl supported), and automatically open with VLC as soon as possible. Assign to global hotkey for easy use: (1. Copy URL. 2. Hit hotkey shortcut. 3. Wait a few seconds. 4. Enjoy in VLC)
#!/bin/bash
if [ $# -eq 1 ] ; then
path=$1
else
clipboard=$(xclip -selection clipboard -o)
if [ $(<<<$clipboard grep -P "^http") ] ; then
path=$clipboard
else
if [ -t 1 ] ; then
@swarminglogic
swarminglogic / gifcapture.sh
Last active June 5, 2018 20:22
gifcapture -- A linux tool to record a region of the screen and convert it to a well optimized gif.
#!/bin/bash
delay=0.2
title='default'
count=0
loop=1 #0 for infinite loop
# Set if you want to skip mouse selection
if [[ $# -eq 6 ]]
then