Skip to content

Instantly share code, notes, and snippets.

View NOLFXceptMe's full-sized avatar
:octocat:

Naveen Molleti NOLFXceptMe

:octocat:
  • Amazon.com
  • Seattle
View GitHub Profile
@NOLFXceptMe
NOLFXceptMe / CsvToHtmlTable.js
Created March 3, 2022 08:02
React CsvToHtmlTable JS
// Essentially https://github.com/marudhupandiyang/react-csv-to-table , but JS instead of JSX
'use strict';
const e = ReactDOM.createElement;
function parseCsvToRowsAndColumn(csvText, csvColumnDelimiter = '\t') {
const rows = csvText.split('\n');
if (!rows || rows.length === 0) {
return [];
@NOLFXceptMe
NOLFXceptMe / notes.jq.1
Created January 28, 2019 00:53
Notes on jq
$ cat excluded.keys
"green"
"blue"
$ cat color-map.json
{
"map": [
{
"color": "red",
"value": "#f00"
#!/usr/bin/env ruby
# Silence Ctrl-C's
trap('INT'){ exit 1 }
require 'optparse'
require 'gist'
# For the holdings of options.
options = {}
@NOLFXceptMe
NOLFXceptMe / vim-plugin-directories
Created June 12, 2018 19:06 — forked from nelstrom/vim-plugin-directories
An overview of what belongs in each directory of a Vim plugin.
plugin
naming convention: name_of_plugin.vim
these files are sourced for all file types
doc
naming convention: name_of_plugin.txt
these files document the functionality of a plugin
color
naming convention: name_of_colorscheme.vim
@NOLFXceptMe
NOLFXceptMe / hosts
Created April 22, 2018 03:27
hosts file blocking reddit, facebook, and some ads websites.
##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost

Haskell, Stack and Intellij IDEA IDE setup tutorial how to get started

Upon completion you will have a sane, productive Haskell environment adhering to best practices.

Basics

  • Haskell is a programming language.
  • Stack is tool for Haskell projects. (similar tools for other languages include Maven, Gradle, npm, RubyGems etc)
  • Intellij IDEA IDE is a popular IDE.

Install required libraries

sudo apt-get install libtinfo-dev libghc-zlib-dev libghc-zlib-bindings-dev

Hi Gabor,
I am the original author of GNU grep. I am also a FreeBSD user,
although I live on -stable (and older) and rarely pay attention
to -current.
However, while searching the -current mailing list for an unrelated
reason, I stumbled across some flamage regarding BSD grep vs GNU grep
performance. You may have noticed that discussion too...
@NOLFXceptMe
NOLFXceptMe / CorsSupport.scala
Created February 8, 2016 18:33 — forked from joseraya/CorsSupport.scala
CORS directive for Spray
package com.agilogy.spray.cors
import spray.http.{HttpMethods, HttpMethod, HttpResponse, AllOrigins}
import spray.http.HttpHeaders._
import spray.http.HttpMethods._
import spray.routing._
// see also https://developer.mozilla.org/en-US/docs/Web/HTTP/Access_control_CORS
trait CORSSupport {
this: HttpService =>
def willis_pi(n):
pi = 2.0
for i in xrange(1, n):
k = 4 * i * i
pi = (pi * k)/(k-1)
print pi
@NOLFXceptMe
NOLFXceptMe / .screenrc
Created June 22, 2015 11:35
'screen' configuration
hardstatus alwayslastline "%{=b}%{R} Screen(s): %{b}%w %=%{kG}%C%A %D, %M/%d/%Y "
startup_message off
defscrollback 10000
autodetach on
termcapinfo xterm* ti@:te@