Skip to content

Instantly share code, notes, and snippets.

View nisargap's full-sized avatar
🕶️

Nisarga P nisargap

🕶️
View GitHub Profile
@nisargap
nisargap / virtualenv.py
Created November 24, 2015 21:52
virtualenv
#!/usr/bin/env python
"""Create a "virtual" Python installation
"""
# If you change the version here, change it in setup.py
# and docs/conf.py as well.
virtualenv_version = "1.7"
import base64
import sys
#!/usr/bin/env python
"""Create a "virtual" Python installation
"""
# If you change the version here, change it in setup.py
# and docs/conf.py as well.
virtualenv_version = "1.6.4"
import base64
import sys

Top 5 Tools for Portable Development

Ever find yourself on a beach without a laptop, and realize that you have to meet a development deadline? In the olden days you would have to come up with an excuse to your boss as to why you weren't able to make enough commits or get that critical functionality finished, but today all of that has changed. Today smartphones are packing power that rivals even some low budget laptops! For example, the OnePlus 3 set to be unveiled on June 14th will be packing 6gb of RAM, 64gb of storage, and a Snapdragon 820 processor all under $400! These are my top 5 tools (in no particular order) to make development on the go a lot easier!

JuiceSSH is an extremely popular all-in-one terminal client for Android. It features a full co

.equ SWI_PrChr, 0x00
.equ SWI_Exit, 0x11
_start:
mov r0, #'A
swi SWI_PrChr
mov r0, #'\n
swi SWI_PrChr
mov r0, #'B
swi SWI_PrChr
@nisargap
nisargap / IndexRoute.js
Created January 3, 2017 22:53
IndexRoute.js
// import in express
var express = require('express');
// get the express router
var router = express.Router();
// can also get this from another file
// var IndexRouteController = require('PATH TO INDEX ROUTE CONTROLLER"
var IndexRouteController = function(req, res) {
res.render('index', {
function oneFunction() {
console.log("hello fam");
}
function twoFunction() {
console.log("hello fam again");
}
var objectToExport = {
one: oneFunction,
// Nasty line to refactor:
// app.use(require('express-session')({ secret: 'keyboard cat', resave: false, saveUninitialized: false }));
// No one can read that
// expressSession library
var expressSession = require('express-session');
// sessionOptions object
var sessionOptions = {
secret: "keyboard cat",
@nisargap
nisargap / fixingsteamubuntu16.04
Created July 27, 2017 03:03
Fixing Steam on Ubunrtu 16.04 for NVIDIA graphics processors
# Find the library that's messing things up
sudo find /usr -iname "*libGL.so*" -exec ls -l {} \;
# Remove that library
rm ...
# In my case it was the mesa libraries
# Create the symlink for the proper Nvidia Library in this case its nvidia-378 but it could be something else
sudo ln -s /usr/lib/nvidia-378/libGL.so.1 /usr/local/lib/libGL.so.1.2.0

Keybase proof

I hereby claim:

  • I am nisargap on github.
  • I am nisarga (https://keybase.io/nisarga) on keybase.
  • I have a public key ASBT85DDO_LgzHMY1OmROdvxq4XHrLM8OXWu93at6aBSbQo

To claim this, I am signing this object:

Keybase proof

I hereby claim:

  • I am nisargap on github.
  • I am nisarga (https://keybase.io/nisarga) on keybase.
  • I have a public key ASDGefZjCn-ZzvwC4HUjhuKpulaCk-L4-sqWBSBNB3a70Qo

To claim this, I am signing this object: