Skip to content

Instantly share code, notes, and snippets.

Avatar
:shipit:
Working

Jade zjhiphop

:shipit:
Working
View GitHub Profile
View nginx.conf
# This configuration file is provided on an "as is" basis,
# with no warranties or representations, and any use of it
# is at the user's own risk.
user www-data;
worker_processes 4;
pid /run/nginx.pid;
events {
worker_connections 768;
View gist:c97a460544f267438758ff2ddd7034b7
var countries_data = {"type":"FeatureCollection","features":[
{"type":"Feature","geometry":{"type":"MultiPolygon","coordinates":[[[[74.92,37.24],[74.57,37.03],[72.56,36.82],[71.24,36.13],[71.65,35.42],[71.08,34.06],[69.91,34.04],[70.33,33.33],[69.51,33.03],[69.33,31.94],[66.72,31.21],[66.26,29.85],[62.48,29.41],[60.87,29.86],[61.85,31.02],[60.84,31.5],[60.58,33.07],[60.94,33.52],[60.51,34.14],[61.28,35.61],[62.72,35.25],[63.12,35.86],[64.5,36.28],[64.8,37.12],[66.54,37.37],[67.78,37.19],[69.32,37.12],[70.97,38.47],[71.59,37.9],[71.68,36.68],[73.31,37.46],[74.92,37.24]]]]},"properties":{"name":"Afghanistan"},"id":"AF"},
{"type":"Feature","geometry":{"type":"MultiPolygon","coordinates":[[[[19.44,41.02],[19.37,41.85],[19.65,42.62],[20.07,42.56],[20.59,41.88],[20.82,40.91],[20.98,40.86],[20.01,39.69],[19.29,40.42],[19.44,41.02]]]]},"properties":{"name":"Albania"},"id":"AL"},
{"type":"Feature","geometry":{"type":"MultiPolygon","coordinates":[[[[2.96,36.8],[8.62,36.94],[8.18,36.52],[8.25,34.64],[7.49,33.89],[9.06,3
View asia.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View MongoDB-UserCollection-Data-Change_Send-Change-SocketIO.js
/* MongoDB-UserCollection-Data-Change_Send-Change-SocketIO.js */
'use strict'
module.exports = function (
app,
io,
User // Collection Name
) {
// SET WATCH ON COLLECTION
const changeStream = User.watch();
@zjhiphop
zjhiphop / main.go
Created Mar 19, 2019 — forked from shellmanme/main.go
mongo-go-driver Demo
View main.go
package main
import (
"context"
"github.com/mongodb/mongo-go-driver/bson"
"github.com/mongodb/mongo-go-driver/bson/objectid"
"github.com/mongodb/mongo-go-driver/bson/primitive"
"github.com/mongodb/mongo-go-driver/mongo"
"log"
"time"
@zjhiphop
zjhiphop / main.py
Created Mar 13, 2019 — forked from littlecodersh/main.py
Main script behind itchat robot
View main.py
#coding=utf8
import itchat
# tuling plugin can be get here:
# https://github.com/littlecodersh/EasierLife/tree/master/Plugins/Tuling
from tuling import get_response
@itchat.msg_register('Text')
def text_reply(msg):
if u'作者' in msg['Text'] or u'主人' in msg['Text']:
return u'你可以在这里了解他:https://github.com/littlecodersh'
@zjhiphop
zjhiphop / CDPATH.md
Created Nov 6, 2018 — forked from flackend/CDPATH.md
Instructions for setting up CDPATH completions on Mac.
View CDPATH.md

CDPATH

Overview

This will allow you to include additional directories to what cd will look at for completions. From the bash man page:

The search path for the cd command. This is a colon-separated list of directories in which the shell looks for destination directories specified by the cd command.

Usage

@zjhiphop
zjhiphop / public-stun-list.txt
Created Jul 24, 2018 — forked from mondain/public-stun-list.txt
Public STUN server list
View public-stun-list.txt
23.21.150.121:3478
iphone-stun.strato-iphone.de:3478
numb.viagenie.ca:3478
s1.taraba.net:3478
s2.taraba.net:3478
stun.12connect.com:3478
stun.12voip.com:3478
stun.1und1.de:3478
stun.2talk.co.nz:3478
stun.2talk.com:3478
@zjhiphop
zjhiphop / the-scratch.conf
Created Jul 4, 2018 — forked from korczis/the-scratch.conf
Nginx Node.js Proxy with caching, websockets, gzip
View the-scratch.conf
proxy_cache_path /var/cache/nginx/cache levels=1:2 keys_zone=cache:8m max_size=3000m inactive=600m;
proxy_temp_path /var/tmp;
# the IP(s) on which your node server is running. I chose port 3000.
upstream app_the_scratch {
server 127.0.0.1:3000 weight=1 fail_timeout=60s;
}
# the nginx server instance
server {
@zjhiphop
zjhiphop / WebGL-frameworks-libraries.md
Created Jan 24, 2018 — forked from dmnsgn/WebGL-WebGPU-frameworks-libraries.md
A collection of WebGL frameworks and libraries
View WebGL-frameworks-libraries.md

A non-exhaustive list of WebGL frameworks and libraries. It is mostly for learning purposes as some of the libraries listed are outdated/not maintained anymore.

Engines and libraries

  • three.js: JavaScript 3D library
  • stack.gl: an open software ecosystem for WebGL, built on top of browserify and npm.
  • PixiJS: Super fast HTML 5 2D rendering engine that uses webGL with canvas fallback
  • Pex: Pex is a javascript 3d library / engine allowing for seamless development between Plask and WebGL in the browser.
  • Babylon.js: a complete JavaScript framework for building 3D games with HTML 5 and WebGL
  • SceneJS: An extensible WebGL-based engine for high-detail 3D visualisation
  • Blend4Web: a tool for interactive 3D visualization on the Internet
You can’t perform that action at this time.