Skip to content

Instantly share code, notes, and snippets.

View fumblehool's full-sized avatar

Damanpreet Singh fumblehool

View GitHub Profile
@import url(font-awesome.min.css);
@import url("https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,300italic,400,400italic");
@-moz-keyframes spinner {
0% {
-moz-transform: rotate(0deg);
-webkit-transform: rotate(0deg);
-ms-transform: rotate(0deg);
transform: rotate(0deg);
}
{
"C++ Snippet": {
"prefix": "cc",
"body": [
"#include <bits/stdc++.h> ",
"#include <iostream>",
"#include <algorithm>",
" ",
"using namespace std;",
" ",
@fumblehool
fumblehool / scroll.py
Created September 11, 2020 09:28 — forked from hmldd/scroll.py
Example of Elasticsearch scrolling using Python client
# coding:utf-8
from elasticsearch import Elasticsearch
import json
# Define config
host = "127.0.0.1"
port = 9200
timeout = 1000
index = "index"
# Simple Flask app.
from flask import Flask, g, request
app = Flask(__name__)
"""
Root
"""
Using Git
===============
Global Settings
-----------
Related Setup: https://gist.github.com/hofmannsven/6814278
Related Pro Tips: https://ochronus.com/git-tips-from-the-trenches/
<html>
<head>
<title>example for joint js</title>
<!-- Required Scripts & css -->
<link rel="stylesheet" type="text/css" href="./libs/css/joint.css"/>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.1/jquery.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/lodash.js/3.10.1/lodash.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/backbone.js/1.3.3/backbone.js"></script>
<script src="./libs/joint.js"></script>
</head>
@fumblehool
fumblehool / server.xml
Created June 15, 2017 02:00
BIM Server tomcat8 /opt/tomcat8/conf/server.xml
<?xml version='1.0' encoding='utf-8'?>
<Server port="8005" shutdown="SHUTDOWN">
<Listener className="org.apache.catalina.startup.VersionLoggerListener" />
<!-- Security listener. Documentation at /docs/config/listeners.html
<Listener className="org.apache.catalina.security.SecurityListener" />
-->
<!--APR library loader. Documentation at /docs/apr.html -->
<Listener className="org.apache.catalina.core.AprLifecycleListener" SSLEngine="on" />
<!-- Prevent memory leaks due to use of particular java/javax APIs-->
<Listener className="org.apache.catalina.core.JreMemoryLeakPreventionListener" />
@fumblehool
fumblehool / default.policy
Created June 15, 2017 01:57
BIM server tomcat8 config /opt/tomcat8/conf/policy.d/default.policy
grant {
permission java.security.AllPermission;
};
@fumblehool
fumblehool / tomcat8
Last active September 25, 2018 21:09
BIM server /etc/init.d/tomcat8
#!/bin/sh
#
# /etc/init.d/tomcat8 -- startup script for the Tomcat 8 servlet engine
#
# Modified for Tomcat8 by Damanpreet Singh <daman.4880@gmail.com>
#
### BEGIN INIT INFO
# Provides: tomcat8
# Required-Start: $local_fs $remote_fs $network
# Required-Stop: $local_fs $remote_fs $network