This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# For phpize | |
apt install php7.4-dev | |
# Install extensions | |
pecl install ev | |
pecl install event | |
# Create configurations | |
sudo echo 'extension=ev.so' > /etc/php/7.4/mods-available/ev.ini | |
sudo echo 'extension=event.so' > /etc/php/7.4/mods-available/event.ini |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# RUN AS ADMINISTRATOR | |
# based on https://nils.schimmelmann.us/post/153541254987/intel-smart-response-technology-vs-windows-10 | |
# Tested with one SSD and one HDD | |
# | |
#Pool that will suck in all drives | |
$StoragePoolName = "My Storage Pool" | |
#Tiers in the storage pool | |
$SSDTierName = "SSDTier" | |
$HDDTierName = "HDDTier" | |
#Virtual Disk Name made up of disks in both tiers |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dconf write /org/gnome/shell/extensions/panel-date-format/format "'%d.%m.%Y %H:%M'" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* | |
* @copyright Copyright (c) 2018. Giacomo Tüfekci (https://www.tuefekci.de) | |
* @github https://github.com/tuefekci | |
* @license https://www.tuefekci.de/LICENSE.md | |
* | |
*/ | |
// IMPORTANT: $this->filesystem needs to be adapted to use case! Also this is not intended for Production Use! | |
// TODO: For productive use add Exception handling etc. depended on use case. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* QR Code + Logo Generator | |
* | |
* http://labs.nticompassinc.com | |
*/ | |
$data = isset($_GET['data']) ? $_GET['data'] : 'http://labs.nticompassinc.com'; | |
$size = isset($_GET['size']) ? $_GET['size'] : '200x200'; | |
$logo = isset($_GET['logo']) ? $_GET['logo'] : FALSE; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Single level, Case Insensitive File Exists. | |
* | |
* Only searches one level deep. Based on | |
* https://gist.github.com/hubgit/456028 | |
* | |
* @param string $file The file path to search for. | |
* | |
* @return string The path if found, FALSE otherwise. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rsync -rlptuvhz -e ssh username@my-dev-server.dev:/path/to/dir . | |
# -r Recursive | |
# -l Copy symlinks as symlinks | |
# -p Copy permisisons | |
# -t Copy times | |
# -u Update. Skip files that are newer on receiving end. | |
# -v Verbose. | |
# -h Output numbers in a human-readable format | |
# -z Use compression when sending data over the network. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
init: function(elevators, floors) { | |
console.log(elevators); | |
// # Elevators | |
elevators.forEach(function(elevator) { | |
elevator.on("stopped_at_floor", function(floorNum) { | |
if(elevator.destinationQueue.indexOf(floorNum) !== -1) { | |
elevator.destinationQueue.splice(elevator.destinationQueue.indexOf(floorNum), 1); | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
init: function(elevators, floors) { | |
console.log(elevators); | |
// # Elevators | |
elevators.forEach(function(elevator) { | |
elevator.on("stopped_at_floor", function(floorNum) { | |
if(elevator.destinationQueue.indexOf(floorNum) !== -1) { | |
elevator.destinationQueue.splice(elevator.destinationQueue.indexOf(floorNum), 1); | |
} | |
}); |