This file contains hidden or 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
| import string, random | |
| pool = string.ascii_letters + string.digits | |
| print(''.join(random.choices(pool, k=16))) |
This file contains hidden or 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 | |
| # Executing grep every time is a little slow, but bash regex doesn't support | |
| # lazy evaluation and it's not worth rewriting... | |
| IFS='' # Preserve whitespace for read | |
| while read p; do # Read /boot/grub/grub.cfg line by line | |
| LINE_REGEX=`echo $p | grep -Po "menuentry ['\"]\K.+?(?=['\"])"` | |
| if [ "$LINE_REGEX" ]; then | |
| # Submenu lines begin with a tab, so lazy method is to check for that |
This file contains hidden or 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
| dpkg-query -W --showformat='${Installed-Size} ${Package}\n' | sort -nr |
This file contains hidden or 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/sh -e | |
| # | |
| # rc.local | |
| # | |
| # This script is executed at the end of each multiuser runlevel. | |
| # Make sure that the script will "exit 0" on success or any other | |
| # value on error. | |
| # | |
| # In order to enable or disable this script just change the execution | |
| # bits. |
This file contains hidden or 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
| echo "$1" | tr '\!-~' 'P-~\!-O' |
This file contains hidden or 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 | |
| # See full range of terminal colors | |
| for C in {0..255}; do | |
| tput setab $C | |
| printf "%4d" "$C" | |
| if ((C%16 == 15)); then echo; fi | |
| done | |
| tput sgr0 |
This file contains hidden or 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
| \[FormalA] | |
| \[FormalB] | |
| \[FormalC] | |
| \[FormalD] | |
| \[FormalE] | |
| \[FormalF] | |
| \[FormalG] | |
| \[FormalH] | |
| \[FormalI] | |
| \[FormalJ] |
This file contains hidden or 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
| *://www.tutorialspoint.com/* | |
| *://www.geeksforgeeks.org/* | |
| *://www.w3schools.com/* | |
| *://www.programiz.com/* | |
| *://www.techonthenet.com/* | |
| *://fresh2refresh.com/* | |
| *://www.quora.com/* | |
| *://www.researchgate.net/* | |
| *://www.w3resource.com/* | |
| *://www.improgrammer.net/* |
This file contains hidden or 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
| -- Just add this to the end of the control.lua file in the save file and then replay the file | |
| script.on_nth_tick(1800, function(event) | |
| game.take_screenshot{ | |
| surface = game.surfaces[1], | |
| position = {0,0}, | |
| resolution = {3840,2160}, | |
| zoom = 0.2, | |
| path = "timelapse/" .. string.format("%06d", event.tick/event.nth_tick) .. ".jpg", | |
| quality = 95, |
This file contains hidden or 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
| # requires xq with --raw output support (https://github.com/boyska/xq fork) | |
| xq -r '//item/enclosure/@url' Podcast.ashx | wget -i - |
OlderNewer