Skip to content

Instantly share code, notes, and snippets.

View technikhil314's full-sized avatar

Nikhil Mehta technikhil314

View GitHub Profile
import { Component } from '@angular/core';
import { NgModel } from '@angular/forms';
import * as moment from 'moment';
@Component({
selector: "my-datepicker-demo",
template: `
<div class="col-md-7 separator-right">
<h3>Configuration Options Tester</h3>
<form>
<div class="col-md-12">
@technikhil314
technikhil314 / n-level-multiply-curry.js
Created June 23, 2019 08:02
nth level of curry for multiply
function mul(val1) {
if(val1) {
return (val2) => {
if(val2) {
return mul(val1*val2);
} else {
return val1;
}
}
} else {
@technikhil314
technikhil314 / plink-plonk.js
Created February 17, 2020 14:56 — forked from tomhicks/plink-plonk.js
Listen to your web pages
@technikhil314
technikhil314 / .tigrc
Created April 23, 2020 17:27 — forked from vremy/.tigrc
Tig theme (location: ~/.tigrc)
# vim: set expandtab sw=4 tabstop=4:
# *color* 'area' 'fgcolor' 'bgcolor' '[attributes]'
# general
color default 15 0
color cursor 15 241
color title-focus 242 221
color title-blur 242 221
color delimiter 213 default
color author 156 default
@technikhil314
technikhil314 / dark.css
Created August 3, 2020 15:09
One line dark mode via css
// Credit to : https://dev.to/akhilarjun/one-line-dark-mode-using-css-24li
html[theme='dark-mode'] {
filter: invert(1) hue-rotate(180deg);
}
@technikhil314
technikhil314 / initial_setup.sh
Last active September 5, 2020 16:47
initial install of softwares on new debian based OS
#zsh
apt install zsh
chsh -s /bin/zsh
#oh-my-zsh
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
#zsh-autosuggestions
git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
@technikhil314
technikhil314 / commands.sh
Last active September 8, 2020 15:05
Linux Imp but not frequently used Commands
# Mount all partitions after chroot to fully load the os
chroot /dev/sda7
for i in /dev /dev/pts /proc /sys /run; do sudo mount -B $i /mnt$i; done
# install uninstall gnome shell extension
gnome-extensions uninstall yomun@yahoo.com
gnome-extensions install yomun@yahoo.com
#To disable gnome file indexing/tracker
gsettings set org.freedesktop.Tracker.Miner.Files enable-monitors false
@technikhil314
technikhil314 / Code.gs
Created September 8, 2020 19:07 — forked from edwinlee/Code.gs
Sync a Google Sheets spreadsheet to a Firebase Realtime database
/**
* Copyright 2019 Google LLC.
* SPDX-License-Identifier: Apache-2.0
*/
function getEnvironment() {
var environment = {
spreadsheetID: "<REPLACE WITH YOUR SPREADSHEET ID>",
firebaseUrl: "<REPLACE WITH YOUR REALTIME DB URL>"
};
@technikhil314
technikhil314 / vim_cheatsheet.md
Created September 26, 2020 10:17 — forked from awidegreen/vim_cheatsheet.md
Vim shortcuts

Introduction

  • C-a == Ctrl-a
  • M-a == Alt-a

General

:q        close
:w        write/saves
:wa[!]    write/save all windows [force]
:wq       write/save and close
@technikhil314
technikhil314 / Procfile
Created October 16, 2020 17:51 — forked from jordansissel/Procfile
Jenkins on Heroku
# Only listen on http; disable ajp and https
web: java -jar jenkins.war --httpPort=$PORT --ajp13Port=-1 --httpsPort=-1