Skip to content

Instantly share code, notes, and snippets.

View alayek's full-sized avatar

Arijit Layek alayek

  • India
View GitHub Profile

Keybase proof

I hereby claim:

  • I am alayek on github.
  • I am alayek (https://keybase.io/alayek) on keybase.
  • I have a public key ASAZ4uBZXcIRqlWRxrGF2YsiXHPPmYG4s7iMzhkooHPrTQo

To claim this, I am signing this object:

@alayek
alayek / library-check.sh
Created March 8, 2017 10:32
Check libraries before LFS
#!/bin/bash
for lib in lib{gmp,mpfr,mpc}.la; do
echo $lib: $(if find /usr/lib* -name $lib|
grep -q $lib;then :;else echo not;fi) found
done
unset lib
@alayek
alayek / version-check.sh
Created March 8, 2017 10:13
Version Check for various libs before LFS
#!/bin/bash
# Simple script to list version numbers of critical development tools
export LC_ALL=C
bash --version | head -n1 | cut -d" " -f2-4
MYSH=$(readlink -f /bin/sh)
echo "/bin/sh -> $MYSH"
echo $MYSH | grep -q bash || echo "ERROR: /bin/sh does not point to bash"
unset MYSH
echo -n "Binutils: "; ld --version | head -n1 | cut -d" " -f3-
@alayek
alayek / logfile.txt
Created June 3, 2016 08:12
Node Vagrant logfile
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'minimal/trusty64'...
Progress: 10%
Progress: 30%
Progress: 40%
Progress: 50%
Progress: 60%
Progress: 70%
Progress: 90%
@alayek
alayek / logfile.txt
Created June 2, 2016 19:04
Java Vagrant Logfile
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'minimal/trusty64'...
Progress: 10%
Progress: 30%
Progress: 40%
Progress: 50%
Progress: 60%
Progress: 70%
Progress: 90%
@alayek
alayek / logfile.txt
Created June 2, 2016 11:49
Ruby Vagrant Installation Log
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'minimal/trusty64'...
Progress: 10%
Progress: 30%
Progress: 40%
Progress: 50%
Progress: 60%
Progress: 70%
Progress: 90%
@alayek
alayek / clojure-provision.sh
Last active May 27, 2016 21:42
Clojure Provisioner
#!/usr/bin/env bash
# installation settings
PROJECT=my_project # we would want a name passed to it via te first argument,
DB=fcc_provision # the name of postgreSQL DB we need to provision, maybe
ENV_NAME=fcc-clojure # the vitualenv we would like to create, with Python 3.4
# This file is executed by root user - sudo not needed
# But do not create any directory
# which vagrant user might need access to later in su mode
@alayek
alayek / keybase.md
Created May 26, 2016 12:17
Keybase gist

Keybase proof

I hereby claim:

  • I am alayek on github.
  • I am alayek (https://keybase.io/alayek) on keybase.
  • I have a public key whose fingerprint is 7443 1225 DC8A F329 3CF0 D622 CFDE 269A AFB4 BE9A

To claim this, I am signing this object:

@alayek
alayek / naive_import.py
Created May 26, 2016 10:42
Python install requests and import it
try:
import requests
except ImportError:
import pip
pip.main(['install', 'requests']) # if not running in venv, pass the --users flag too
import requests
r = requests.get('https://api.github.com/events')
print(r)
package com.example.android.sunshine.app;
import android.annotation.TargetApi;
import android.content.Context;
import android.content.res.Configuration;
import android.media.Ringtone;
import android.media.RingtoneManager;
import android.net.Uri;
import android.os.Build;
import android.os.Bundle;