Skip to content

Instantly share code, notes, and snippets.

/*!
=========================================================
* Argon Design System React - v1.1.0
=========================================================
* Product Page: https://www.creative-tim.com/product/argon-design-system-react
* Copyright 2020 Creative Tim (https://www.creative-tim.com)
* Licensed under MIT (https://github.com/creativetimofficial/argon-design-system-react/blob/master/LICENSE.md)
{
"version": "2",
"templates": [{
"categories": ["Music"],
"description": "Airsonic is a free, web-based media streamer, providing ubiqutious access to your music. Use it to share your music with friends, or to listen to your own music while at work. You can stream to multiple players simultaneously, for instance to one player in your kitchen and another in your living room.",
"env": [{
"default": "1000",
"label": "PUID",
"name": "PUID"
},
@darkrishabh
darkrishabh / gist:b9f5050ac40d280d2d0b9e7b7a1122b6
Created October 27, 2020 19:34 — forked from timperrett/gist:e6079101ae469822a9b2c8c1a46429aa
Increate max no of open files limit in Ubuntu 16.04 for Nginx
# maximum capability of system
user@ubuntu:~$ cat /proc/sys/fs/file-max
708444
# available limit
user@ubuntu:~$ ulimit -n
1024
# To increase the available limit to say 200000
user@ubuntu:~$ sudo vim /etc/sysctl.conf
@darkrishabh
darkrishabh / test.js
Last active September 29, 2020 06:26
getCurrentLocation = async () => {
return new Promise((resolve, reject) => {
navigator.geolocation.getCurrentPosition(
(position) => {
resolve({
latitude: parseFloat(position.coords.latitude),
longitude: parseFloat(position.coords.longitude),
latitudeDelta: 5,
longitudeDelta: 5,
})
@darkrishabh
darkrishabh / bootstrap.min.css
Last active November 6, 2017 19:42
Paper Bootstrap 3
@import url("https://fonts.googleapis.com/css?family=Roboto:300,400,500,700");/*!
* bootswatch v3.3.7
* Homepage: http://bootswatch.com
* Copyright 2012-2016 Thomas Park
* Licensed under MIT
* Based on Bootstrap
*//*!
* Bootstrap v3.3.7 (http://getbootstrap.com)
* Copyright 2011-2016 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
@darkrishabh
darkrishabh / bootstrap.min.css
Created November 6, 2017 19:42
Paper Bootstrap 3
@import url("https://fonts.googleapis.com/css?family=Roboto:300,400,500,700");/*!
* bootswatch v3.3.7
* Homepage: http://bootswatch.com
* Copyright 2012-2016 Thomas Park
* Licensed under MIT
* Based on Bootstrap
*//*!
* Bootstrap v3.3.7 (http://getbootstrap.com)
* Copyright 2011-2016 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
@darkrishabh
darkrishabh / Hashtag.js
Last active May 31, 2018 20:45
JAVASCRIPT: Find all the hastags in a string (eg INPUT="Hi #my#name is #Bond #JamesBond" OUTPUT = ["my", "name", "Bond", "JamesBond"])
var _ = require('lodash');
function HashTags(text) {
var adding = false;
var d = "";
var t = "";
return _.filter(_.map(text, function (c, k) {
if (c === '#' || (c === ' ')) {
if (adding) {
t = d;
d = "";
@darkrishabh
darkrishabh / Delete Git Branches not on Remote
Created May 8, 2015 04:10
Deletes all the branches not on remote
git checkout master && git branch -l | sed 's/* master//' > /tmp/gitlocal.txt && git branch -r | sed 's/origin\///' > /tmp/gitremote.txt && grep -Fxv -f /tmp/gitremote.txt /tmp/gitlocal.txt | xargs git branch -d
// final.cpp : main project file.
#include "stdafx.h"
#ifdef _CH_
#pragma package <opencv>
#endif
#ifndef _EiC
#include "cv.h"
#include "highgui.h"
@darkrishabh
darkrishabh / DFAMin.java
Created December 8, 2014 03:00
DFA Minimization - Hopcroft Karp Algorithm
/*
* Copyright (c) 2014. This Project is the requirement of the course at NYIT-Old Westbury and should not be used in any commercial or personal use unless permitted by the author of the code. This code is the property of Rishabh Mehan and he holds the rights to re-distribute and re-use this code.
*/
/**
* Created by rishabh on 12/7/14.
**/
import java.util.*;