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
#!/usr/bin/env python3 | |
# inspired from https://stackoverflow.com/a/53805392 | |
import pkg_resources | |
try: | |
from pip import get_installed_distributions | |
except: | |
from pip._internal.utils.misc import get_installed_distributions |
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
# Perl one liner which convert CRLF to LF | |
perl -i -pe 's#\r\n$#\n#g' |
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 "dart:convert"; | |
main() { | |
var input = ["{\"key\":\"value0\"}{\"key\":\"value1\"}"]; | |
Stream.fromIterable(input) | |
.transform(JsonDecoder()) | |
.listen((item) { | |
print("item: $item\n"); | |
}); | |
} |
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 | |
function die { | |
echo "$*" 1>&2 ; | |
exit 1; | |
} | |
CC=${CC:-/usr/bin/gcc} | |
CXX=${CXX:-/usr/bin/g++} |
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
if(NOT(DEST)) | |
message(FATAL_ERROR "DEST NOT DEFINED") | |
endif() | |
if(SHA1) | |
string(TOLOWER ${SHA1} SHA1) | |
endif() | |
if(EXISTS "${DEST}") | |
if(NOT(SHA1)) |
NewerOlder