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
/**! | |
* A pluggable live reload script. No server required. | |
* Will reload page whenever the page content or link & script | |
* resources change. | |
* A reload will only be triggered when the page/window has focus. | |
*/ | |
// https://gist.github.com/carlosascari/cc85e74544e4a26dcd88e94eb7a281ea | |
import $ from '$'; |
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
int index_of(char* hay, char* needle, size_t start) { | |
size_t len = strlen(hay); | |
size_t needle_len = strlen(needle); | |
int subfind = 0; | |
for (int j = start; j < len; ++j) | |
{ | |
if (hay[j] == needle[0]) { | |
subfind = 1; | |
for (int k = 1; k < needle_len; ++k) | |
{ |
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
#!/bin/bash | |
# Top 20 Files | |
find -type f -exec du -Sh {} + | sort -rh | head -n 20 | |
# Top 20 Dirs | |
du -Sh | sort -rh | head -20 | |
du -a . | sort -n -r | head -n 20 |
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
git diff --no-commit-id --name-only | tar -czf modified_files.tgz -T - |
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
/** | |
* Converts param/search string component from a url into an object | |
* Uses `location.search` as input string | |
*/ | |
Object.assign.apply({}, location.search.substr(1).split('&').map(x => x.split('=').reduce((a, b) => { return { [a]: b } }))) |
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
; | |
; Protected Mode BIOS Call Functionailty v2.0 - by Napalm | |
; ------------------------------------------------------- | |
; | |
; This is code shows how its POSSIBLE to execute BIOS interrupts | |
; by switch out to real-mode and then back into protected mode. | |
; | |
; If you wish to use all or part of this code you must agree | |
; to the license at the following URL. | |
; |
OlderNewer