Skip to content

Instantly share code, notes, and snippets.

@jayluxferro
jayluxferro / php7 lib download linux
Last active July 18, 2020 21:31
php7 lib download linux
apt-get install php7.4 php7.4-bcmath php7.4-bz2 php7.4-cgi php7.4-cli php7.4-common php7.4-curl php7.4-dba php7.4-enchant php7.4-fpm php7.4-gd php7.4-gmp php7.4-interbase php7.4-intl php7.4-json php7.4-ldap php7.4-mbstring php7.4-mysql php7.4-odbc php7.4-opcache php7.4-pgsql php7.4-pspell php7.4-readline php7.4-snmp php7.4-soap php7.4-sqlite3 php7.4-sybase php7.4-tidy php7.4-xml php7.4-xmlrpc php7.4-xsl php7.4-zip -y
@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:

@jayluxferro
jayluxferro / VMWare_workstation_12.5.7_kernel_4.13_atomic_inc_patch
Created October 24, 2017 16:08
VMWare workstation 12.5.7 kernel 4.13 atomic_inc patch
diff -Naur vmnet-only.orig/bridge.c vmnet-only/bridge.c
--- vmnet-only/bridge.c 2017-06-26 22:08:39.148034785 +1000
+++ vmnet-only/bridge.c 2017-07-16 11:37:01.325802125 +1000
@@ -636,7 +636,7 @@
unsigned long flags;
int i;
- atomic_inc(&clone->users);
+ clone = skb_get(clone);
@jayluxferro
jayluxferro / ufw.md
Last active November 12, 2017 11:19 — forked from kimus/ufw.md
NAT and FORWARD with Linux's ufw firewall

Install UFW

if ufw is not installed by default be sure to install it first.

$ sudo apt-get install ufw

NAT

@jayluxferro
jayluxferro / backup.php
Created January 5, 2018 12:40 — forked from menzerath/backup.php
PHP: Recursively Backup Files & Folders to ZIP-File
<?php
/*
* PHP: Recursively Backup Files & Folders to ZIP-File
* MIT-License - Copyright (c) 2012-2017 Marvin Menzerath
*/
// Make sure the script can handle large folders/files
ini_set('max_execution_time', 600);
ini_set('memory_limit','1024M');
@jayluxferro
jayluxferro / wpa_supplicant.conf
Created January 18, 2018 11:27
Connect to a WPA2 Enterprise network with wpa_supplicant with this .conf file. I used this to connect to my university's wireless network.
# Connect to a WPA2 Enterprise network with wpa_supplicant with this .conf file.
# I used this to connect to my university's wireless network on Arch linux.
# Here's the command I used:
#
# wpa_supplicant -i wlan0 -c ./wpa_supplicant.conf
#
network={
ssid="YOUR_SSID"
scan_ssid=1