Skip to content

Instantly share code, notes, and snippets.

View NightMachinery's full-sized avatar

Feraidoon Mehri NightMachinery

View GitHub Profile
Result: (image :type jpeg :data "\377\330\377\341ExifII*\377\354Duckyd\377\341ohttp://ns.adobe.com/xap/1.0/<?xpacket begin=\"\357\273\277\" id=\"W5M0MpCehiHzreSzNTczkc9d\"?> <x:xmpmeta xmlns:x=\"adobe:ns:meta/\" x:xmptk=\"Adobe XMP Core 5.3-c011 66.145661, 2012/02/06-14:56:27 \"> <rdf:RDF xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"> <rdf:Description rdf:about=\"\" xmlns:xmpMM=\"http://ns.adobe.com/xap/1.0/mm/\" xmlns:stRef=\"http://ns.adobe.com/xap/1.0/sType/ResourceRef#\" xmlns:xmp=\"http://ns.adobe.com/xap/1.0/\" xmpMM:OriginalDocumentID=\"xmp.did:C6ED33D2BCA0E111A7E5B8D488C8B1B0\" xmpMM:DocumentID=\"xmp.did:F5397B1D3D9B11E89A8A9AA03654A192\" xmpMM:InstanceID=\"xmp.iid:F5397B1C3D9B11E89A8A9AA03654A192\" xmp:CreatorTool=\"Adobe Photoshop CS6 (Windows)\"> <xmpMM:DerivedFrom stRef:instanceID=\"xmp.iid:4EF807B19B3DE81182B0D814C7262219\" stRef:documentID=\"xmp.did:C6ED33D2BCA0E111A7E5B8D488C8B1B0\"/> </rdf:Description> </rdf:RDF> </x:xmpmeta> <?xpacket end=\"r\"
#!/usr/bin/env python3
"""telegram-send
Usage:
tsend.py <receiver> <message> [--file=<file>]
tsend.py (-h | --help)
tsend.py --version
Options:
-f <file> --file=<file> Sends a file, with message as its caption.
-h --help Show this screen.

Keybase proof

I hereby claim:

  • I am nightmachinary on github.
  • I am resomnus (https://keybase.io/resomnus) on keybase.
  • I have a public key ASBpBS8xz0_k9cuJCvCCz15O-6BMcg69N0wKMK6ZhW8S8wo

To claim this, I am signing this object:

(( $+functions[dvar] )) || function dvar() {
local pre=''
test -z "$2" || pre="CODE $2 | "
echo "$pre$(typeset -p "$1" 2>&1)"
echo "$pre$1 in env: $(printenv "$1")"
}
localesc() {
echo Innocence
}
tlocalesc() {
Hi Alice!
Hi, Alice!
OOOo
yay
/Users/evar/my-music/Songs/Motion Picture's Soundtracks/More/Cécile Corbel - The Secret World Of Arrietty OST [FLAC]/20 - Cécile Corbel - Arrietty's Song (original Japanese version).flac
@NightMachinery
NightMachinery / book-notifier.zsh
Last active May 16, 2020 12:50
Notifies you when a book has become available on Libgen.
#!/usr/bin/env zsh
#Install libgen.py, GNU Timeout, and terminal-notifier (macOS only. Just delete the line for other OSes.). Use cron to check for a book regularly. (e.g., `0 9 * * * ~/book-notifier.zsh "little schemer"`)
gtimeout 6s libgen -s "$1" &> /dev/null
if [ $? -eq 124 ]; then
terminal-notifier -message "$1" -title "Book Has Become Available!"
echo "$1 is now available!"
fi
❯ /usr/local/Cellar/gcc/10.2.0/bin/gcc-10 sh2bin.c -s -ldl -DSRC=foo.sh -o foo -v 126
Using built-in specs.
COLLECT_GCC=/usr/local/Cellar/gcc/10.2.0/bin/gcc-10
COLLECT_LTO_WRAPPER=/usr/local/Cellar/gcc/10.2.0/libexec/gcc/x86_64-apple-darwin19/10.2.0/lto-wrapper
Target: x86_64-apple-darwin19
Configured with: ../configure --build=x86_64-apple-darwin19 --prefix=/usr/local/Cellar/gcc/10.2.0 --libdir=/usr/local/Cellar/gcc/10.2.0/lib/gcc/10 --disable-nls --enable-checking=release --enable-languages=c,c++,objc,obj-c++,fortran --program-suffix=-10 --with-gmp=/usr/local/opt/gmp --with-mpfr=/usr/local/opt/mpfr --with-mpc=/usr/local/opt/libmpc --with-isl=/usr/local/opt/isl --with-system-zlib --with-pkgversion='Homebrew GCC 10.2.0' --with-bugurl=https://github.com/Homebrew/homebrew-core/issues --disable-multilib --with-native-system-header-dir=/usr/include --with-sysroot=/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk SED=/usr/bin/sed
Thread model: posix
Supported LTO com
@NightMachinery
NightMachinery / get_latest_release.zsh
Last active April 17, 2021 13:15 — forked from lukechilds/get_latest_release.sh
Shell - Get latest release from GitHub
## See latest version at https://github.com/NightMachinary/.shells/blob/master/scripts/zshlang/auto-load/others/github.zsh
## Usage:
# $ gh-release-get "creationix/nvm"
##
alias ec='print -r --'
function gh-release-get() {
local repo="$1"
local releases
releases="$(curl -s https://api.github.com/repos/"$repo"/releases)"