Skip to content

Instantly share code, notes, and snippets.

@jayluxferro
jayluxferro / gist:cf5dfd09f2a015653888acae1f974a25
Last active May 15, 2017 07:55 — forked from pitch-gist/gist:2999707
HTML: Simple Maintenance Page
<!doctype html>
<title>Site Maintenance</title>
<style>
body { text-align: center; padding: 150px; }
h1 { font-size: 50px; }
body { font: 20px Helvetica, sans-serif; color: #333; }
article { display: block; text-align: left; width: 650px; margin: 0 auto; }
a { color: #dc8100; text-decoration: none; }
a:hover { color: #333; text-decoration: none; }
</style>
@jayluxferro
jayluxferro / gist:5246b0f34f5805111c06a38ca85c6b11
Created June 18, 2017 13:11 — forked from tamoyal/gist:10441108
Create super user and database user in Mongo 2.6
# Create your superuser
$ mongo
> use admin
> db.createUser({user:"someadmin",pwd:"secret", roles:[{role:"root",db:"admin"}]})
> exit
# Alias for convenience (optional and at your own risk)
$ echo 'alias mongo="mongo --port 27017 -u someadmin -p secret --authenticationDatabase admin"' >> ~/.bash_profile
$ source ~/.bash_profile
@jayluxferro
jayluxferro / build.gradle
Created June 21, 2017 09:25 — forked from ph0b/build.gradle
sample build.gradle for generating split APKs per ABI
apply plugin: 'com.android.application'
android {
compileSdkVersion 21
buildToolsVersion "21.1.2"
defaultConfig{
minSdkVersion 14
targetSdkVersion 21
versionCode 101
@jayluxferro
jayluxferro / Fingerprint_Ubuntu.md
Created July 28, 2017 04:12
Fingerprint on Ubuntu

sudo apt-add-repository ppa:fingerprint/fingerprint-gui && sudo apt-get update

sudo apt-get install libbsapi policykit-1-fingerprint-gui fingerprint-gui

@jayluxferro
jayluxferro / RPi-install-wifi.sh
Created August 21, 2017 18:09 — forked from kmonsoor/RPi-install-wifi.sh
install wifi adapter drivers on Raspberry Pi; origin: http://www.fars-robotics.net/install-wifi
#!/bin/bash
#set -e
# origin-source: http://www.fars-robotics.net/install-wifi
# install-wifi - v9.4 - by MrEngman.
# After downloading this script:
# $ sudo mv ./install-wifi /usr/bin/install-wifi
# $ sudo chmod +x /usr/bin/install-wifi
# $ sudo install-wifi -h
#
@jayluxferro
jayluxferro / Arduino Song
Created August 22, 2017 00:22 — forked from eznj/star_wars.ino
Arduino Star Wars Song for Piezo
**/
const int c = 261;
const int d = 294;
const int e = 329;
const int f = 349;
const int g = 391;
const int gS = 415;
const int a = 440;
const int aS = 455;
@jayluxferro
jayluxferro / file.php
Created September 9, 2017 05:48 — forked from bainternet/file.php
a Simple class to convert number to words in php based on http://www.karlrixon.co.uk/writing/convert-numbers-to-words-with-php/
<?php
//simple class to convert number to words in php based on http://www.karlrixon.co.uk/writing/convert-numbers-to-words-with-php/
if ( !class_exists('NumbersToWords') ){
/**
* NumbersToWords
*/
class NumbersToWords{
public static $hyphen = '-';
public static $conjunction = ' and ';
https://www.freebsdfoundation.org/freebsd/how-to-guides/installing-a-desktop-environment-on-freebsd/
@jayluxferro
jayluxferro / FixLinuxGrubBootloader.md
Last active September 26, 2017 07:09
Fix linux grub bootloader

Fixing Grub Bootloader

  1. Make a bootable device of the distribution you are using(debian,kali,ubuntu)
  2. Open the terminal
  3. Type lsblk to list the various blocks of the hard disk
root@sperixlabs: ~# lsblk

NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0 931.5G  0 disk 
├─sda1   8:1    0 526.5G  0 part /
@jayluxferro
jayluxferro / gist:48715b2ec4be8d39bcf9b24c36feaaa6
Created October 16, 2017 22:27 — forked from philipn/gist:5274197
Running Ubuntu on a Macbook Air

Running Ubuntu on a Macbook Air

You don't have to be a slave to OS X! Here's a guide to a sane dual-booting setup with Ubuntu 12.10 on your shiny MacBook Air. This is written and tested for a MacBook Air 5,2 (Mid 2012), but likely works the same with any modern Macbook.

Install according to instructions at this URL: