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
## Install chrome driver | |
# https://chromedriver.storage.googleapis.com/index.html?path=2.43/ | |
def execute_with_message(statement): | |
print("Execute... {}".format(statement)) | |
result = get_result_from_subprocess(statement) | |
print("Done message=[{}]".format(result)) | |
def get_result_from_subprocess(cmd): | |
return (subprocess.check_output(cmd, shell=True)).decode("utf-8") |
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
# Does Python have a string 'contains' substring method? | |
# https://stackoverflow.com/questions/3437059/does-python-have-a-string-contains-substring-method | |
if "blah" not in somestring: | |
continue |
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 | |
# Tested Environments : Centos6 | |
start_script_on_background() { | |
echo "nohup ${1} > ${2} &" | |
nohup ${1} > ${2} & | |
} | |
get_script_path() { | |
SCRIPT=`readlink -e $0` |
NewerOlder