Skip to content

Instantly share code, notes, and snippets.

View nithinkashyapn's full-sized avatar
🎯
Focusing

Nithin Kashyap nithinkashyapn

🎯
Focusing
View GitHub Profile
@nithinkashyapn
nithinkashyapn / index.js
Created July 11, 2021 18:03 — forked from joshinat0r/index.js
Umami API wrapper
const umami = require('./umami.js');
const api = await umami({
url: 'https://app.umami.is',
username: 'username',
password: 'password',
website: 1, // internal website-id
})
const stats = await api.getStats()
@nithinkashyapn
nithinkashyapn / node-js-app.service
Created July 5, 2021 06:09 — forked from yagop/node-js-app.service
Nodejs Systemd service example
[Unit]
Description=Node.js App
After=network.target
[Service]
Type=simple
ExecStart=/usr/local/node-v7.4.0/bin/node index.js
WorkingDirectory=/home/yago/produccion/app
Environment="HOST=127.0.0.1"
Environment="PORT=1234"
[{"id":218279855,"sha":"8381c09e18d6a1736e6f802b02d9ee3f5d022808","ref":"master","status":"failed","created_at":"2020-11-19T05:40:36.802Z","updated_at":"2020-11-19T05:47:51.098Z","web_url":"https://gitlab.com/brokentusk/setu-lobby/cou-docker/-/pipelines/218279855"},{"id":218279845,"sha":"8381c09e18d6a1736e6f802b02d9ee3f5d022808","ref":"release","status":"success","created_at":"2020-11-19T05:40:32.733Z","updated_at":"2020-11-19T05:43:38.080Z","web_url":"https://gitlab.com/brokentusk/setu-lobby/cou-docker/-/pipelines/218279845"},{"id":214657552,"sha":"4410619cb43bbfce95ac5e08bd9048cafbc6a358","ref":"master","status":"success","created_at":"2020-11-11T10:35:16.746Z","updated_at":"2020-11-11T10:37:38.630Z","web_url":"https://gitlab.com/brokentusk/setu-lobby/cou-docker/-/pipelines/214657552"},{"id":214566615,"sha":"4410619cb43bbfce95ac5e08bd9048cafbc6a358","ref":"master","status":"success","created_at":"2020-11-11T06:35:10.708Z","updated_at":"2020-11-11T06:37:26.484Z","web_url":"https://gitlab.com/brokentusk/setu-
@nithinkashyapn
nithinkashyapn / cardb-test
Created May 31, 2019 08:07
Demo schema for reactivesearch
{
"brand": "Kia",
"model": "Borrego",
"year": "2009",
"fuelType": "regular unleaded",
"engineHP": "276",
"engineCylinders": "6",
"gearBox": "AUTOMATIC",
"vehicleSize": "Midsize",
"vehicleType": "4dr SUV",
import React, { Component } from "react";
import axios from "axios";
import _ from "lodash";
import { StatusBar } from "@uppy/react";
import { DragDrop } from "@uppy/react";
import "@uppy/core/dist/style.css";
import "@uppy/drag-drop/dist/style.css";
import "@uppy/status-bar/dist/style.css";
const Uppy = require("@uppy/core");
import React, { Component } from "react";
import axios from "axios";
import * as config from "../config.json";
import _ from "lodash";
import { StatusBar } from "@uppy/react";
import { DragDrop } from "@uppy/react";
import "@uppy/core/dist/style.css";
import "@uppy/drag-drop/dist/style.css";
import "@uppy/status-bar/dist/style.css";
import "./s3uploadComponent.css";
@nithinkashyapn
nithinkashyapn / HTML-based-DraftJS-Plugin-Component-For-Formik.js
Created March 15, 2019 19:04
This is a plug and play component which uses HTML as I/O and saves it using Formik's setFieldValue()
import React, { Component } from "react";
import { convertToRaw, convertFromRaw } from "draft-js";
import { convertFromHTML, convertToHTML } from "draft-convert";
import {
DraftailEditor,
BLOCK_TYPE,
INLINE_STYLE,
ENTITY_TYPE
} from "draftail";
import "draft-js/dist/Draft.css";
[
{
"FIELD1": 1,
"FIELD2": "3MINDIA:EQ",
"FIELD3": "1x",
"FIELD4": "3x",
"FIELD5": "Calculate"
},
{
"FIELD1": 2,
All candidates sourced today by everyone
Count of candidatesources/_count
{
"query": {
"range":{
"candidateCreationTime":{
"gte": "28/12/2018",
"format": "dd/MM/yyyy"
}
@nithinkashyapn
nithinkashyapn / Select Multiple Text CSV
Created December 11, 2018 17:45
Displaying Names of selected values in CSV format
<!doctype html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<!-- Bootstrap CSS -->
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous">