Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Taymindis Woon Taymindis

🏠
Working from home
View GitHub Profile
@Taymindis
Taymindis / my.ini
Created Jul 3, 2021
mysql my.ini for 5.7.34
View my.ini
# MySQL Server Instance Configuration File
# ----------------------------------------------------------------------
# Generated by the MySQL Server Instance Configuration Wizard
#
#
# Installation Instructions
# ----------------------------------------------------------------------
#
# On Linux you can copy this file to /etc/my.cnf to set global options,
# mysql-data-dir/my.cnf to set server-specific options
@Taymindis
Taymindis / install_nginx_macos_source.md
Created Feb 25, 2021 — forked from beatfactor/install_nginx_macos_source.md
Install Nginx on Mac OS from source (without brew)
View install_nginx_macos_source.md

Install Nginx on Mac OS from source

no Homebrew required

1. Download Nginx

$ cd /usr/local/src
$ curl -OL http://nginx.org/download/nginx-1.12.2.tar.gz
$ tar -xvzf nginx-1.12.2.tar.gz && rm nginx-1.12.2.tar.gz
@Taymindis
Taymindis / ReactSelectTree.md
Last active May 31, 2020
It's react-select library with tree options
View ReactSelectTree.md
@Taymindis
Taymindis / spdlog_stream_route_handler.cpp
Last active Jul 7, 2018
stream route handler with spdlog
View spdlog_stream_route_handler.cpp
#include <iostream>
#include <stream_rt_handler.h>
/*https://github.com/gabime/spdlog*/
#include "spdlog/spdlog.h"
/***Compile by ***/
/** cd build **/
/** g++ -DSPDLOG_FMT_PRINTF -std=c++11 ../sample_with_spdlog.cpp -lsrh -pthread **/
@Taymindis
Taymindis / nginx.conf
Last active May 3, 2018
Nginx-c-function sample nginx.conf
View nginx.conf
# nginx.conf
### link to your local path and call ###
server {
listen 8888;
...
ngx_http_c_func_link_lib "/path/to/your/libcfuntest.so";
...
...
location = /testCFunGreeting {
# if not variable specified, direct write response out
@Taymindis
Taymindis / get_param_key.c
Created Sep 18, 2017
Get ParamKey From URL Query String, this is derived from https://github.com/Taymindis/fcgi-function
View get_param_key.c
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
int strpos(const char *haystack, const char *needle)
{
char *p = strstr(haystack, needle);
if (p)
return p - haystack;
@Taymindis
Taymindis / multithread_test_zone.c
Created Sep 15, 2017
MultiThreading read and write for Hazard Pointer Logic in C
View multithread_test_zone.c
#include <stdio.h>
#include <pthread.h>
#include <stdlib.h>
#include <string.h>
#define THREAD_RUN 100
typedef struct $
{
char s[50];
} concurrent_update;
@Taymindis
Taymindis / socket.c
Created Aug 30, 2016 — forked from nolim1t/socket.c
HTTP Request in C using low level write to socket functionality
View socket.c
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <unistd.h>
#include <fcntl.h>
#include <netinet/tcp.h>
#include <sys/socket.h>
#include <sys/types.h>
#include <netinet/in.h>