Skip to content

Instantly share code, notes, and snippets.

@tosone
tosone / Makefile
Last active July 21, 2019 13:04 — forked from isaacs/Makefile
[Makefile] #Makefile
# Hello, and welcome to makefile basics.
#
# You will learn why `make` is so great, and why, despite its "weird" syntax,
# it is actually a highly expressive, efficient, and powerful way to build
# programs.
#
# Once you're done here, go to
# http://www.gnu.org/software/make/manual/make.html
# to learn SOOOO much more.
@tosone
tosone / cgo.md
Last active July 21, 2019 13:11 — forked from zchee/cgo.md
[Golang CGO] #Go

See also, http://libraryofalexandria.io/cgo/

Using Go cgo

cgo has a lot of trap.
but Not "C" pkg also directory in $GOROOT/src. IDE's(vim) Goto command not works.

So, Here collect materials.

@tosone
tosone / genpass.c
Created June 4, 2021 07:42 — forked from fabiomontefuscolo/genpass.c
Password generator
#include <getopt.h>
#include <regex.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
void showHelp(char *biname) {
printf("%s [-l length] [-f 'regex'] [-n]\n", biname);
printf(" -l, --length\n");
printf(" Password length\n");
@tosone
tosone / pprof.md
Created January 29, 2023 06:19 — forked from slok/pprof.md
Go pprof cheat sheet

Enable profiling

Default http server

import (
    _ "net/http/pprof"
    "net/http"
)
@tosone
tosone / redis_cheatsheet.bash
Created January 31, 2023 00:45 — forked from LeCoupa/redis_cheatsheet.bash
Redis Cheatsheet - Basic Commands You Must Know --> UPDATED VERSION --> https://github.com/LeCoupa/awesome-cheatsheets
# Redis Cheatsheet
# All the commands you need to know
redis-server /path/redis.conf # start redis with the related configuration file
redis-cli # opens a redis prompt
# Strings.