Skip to content

Instantly share code, notes, and snippets.

<?php
class LanguageDetector
{
private $languages = [];
public function __construct($enabledLanguages)
{
$this->languages = (array)$enabledLanguages;
}
@devillom
devillom / lists.blade.php
Last active August 29, 2015 14:15
Custom Laravel 5 pagination
<!--view/post/lists-->
@include('pagination.uikit',['paginator'=>$posts])
sudo find . -type f -exec chmod 664 {} +
sudo find . -type d -exec chmod 775 {} +
sudo chmod 660 wp-config.php
@devillom
devillom / take_ownership.reg
Created April 28, 2018 01:13
Delete old Windows 10 and other fileds
Windows Registry Editor Version 5.00
; Created by: Shawn Brink
; Created on: January 28th 2015
; Modified on: August 29th 2016
; Tutorial: http://www.sevenforums.com/tutorials/1911-take-ownership-shortcut.html
[-HKEY_CLASSES_ROOT\*\shell\runas]
@devillom
devillom / remove_all_node_modules
Created October 12, 2019 01:17
How to Delete ALL node_modules folders on your machine
List all node_modules found in a Directory:
First, let's take a look at ALL the node_modules we have in a directory, before we actually start deleting them!
NOTE: Make sure you cd into a specific directory where most of your projects are. ie: documents or documents/github.
Mac / Linux:
This command will print out each folder, and even show us how much space the folder is occupying !
$ cd documents
$ find . -name "node_modules" -type d -prune -print | xargs du -chs