Skip to content

Instantly share code, notes, and snippets.

View misterunix's full-sized avatar
😁
Hey, drop me an email if you like!

Bill Jones misterunix

😁
Hey, drop me an email if you like!
View GitHub Profile
@kishida
kishida / html2csv.py
Last active September 7, 2024 14:15
Stable Diffusion web-ui styles from Fooocus
from bs4 import BeautifulSoup
import csv
# Open and read the HTML file
with open("Style reference.html", 'r', encoding='utf-8') as file:
content = file.read()
# Parse the HTML content using BeautifulSoup
soup = BeautifulSoup(content, 'html.parser')
@unakatsuo
unakatsuo / iprange.go
Created December 7, 2020 12:05
IP range iteration utility for golang
// IterateIPRange calculates the sequence of IP address from beginAddr to endAddr
// then calls the callback cb for each address of the sequence.
// beginAddr value must be smaller than endAddr.
func IterateIPRange(beginAddr, endAddr net.IP, cb func(addr net.IP)) error {
incIP := func(ip net.IP) net.IP {
for j := len(ip) - 1; j >= 0; j-- {
ip[j]++
if ip[j] > 0 {
break
}
@mikespook
mikespook / hello.c
Created July 2, 2016 01:40
GIMP Plug-in in Golang
// Comes from http://developer.gimp.org/writing-a-plug-in/1/hello.c
#include <libgimp/gimp.h>
static void query (void);
static void run (const gchar *name,
gint nparams,
const GimpParam *param,
gint *nreturn_vals,
GimpParam **return_vals);
@nimezhu
nimezhu / REAME.md
Last active March 10, 2023 15:21
simple example for gonum matrix operation.
@lbruder
lbruder / lbForth.c
Created April 6, 2014 15:21
A minimal Forth compiler in ANSI C
/*******************************************************************************
*
* A minimal Forth compiler in C
* By Leif Bruder <[email protected]> http://defineanswer42.wordpress.com
* Release 2014-04-04
*
* Based on Richard W.M. Jones' excellent Jonesforth sources/tutorial
*
* PUBLIC DOMAIN
*