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/sh | |
install_go_linux() | |
{ | |
sudo add-apt-repository ppa:longsleep/golang-backports | |
sudo apt update | |
sudo apt install -y golang-go | |
ret=$? | |
if [ $ret -eq 0 ]; then | |
go version |
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
i=0 ; while [ $i -lt 5 ] ; do iwconfig wlan0 | grep Noise ; sleep 1 ; i=$((i+1)) ; done |
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/sh | |
IP=$1 | |
if [ "x$IP" = x ]; then | |
echo "syntax: <ServerIP>" | |
exit 1 | |
fi | |
PERIOD=3600 | |
BITS=5M | |
run_batch_iperf() |
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
~$ python2.7 str_to_hex_for_echo_cmd.py | |
echo -e "testecho_\x21#\x24%\x2a\x5c'\x5c\x22\x21~?<>\x3a| 89920." | |
~$ python3.5 str_to_hex_for_echo_cmd.py | |
echo -e "testecho_\x21#\x24%\x2a\x5c'\x5c\x22\x21~?<>\x3a| 89920." | |
~$ echo -e "testecho_\x21#\x24%\x2a\x5c'\x5c\x22\x21~?<>\x3a| 89920." | |
testecho_!#$%*\'\"!~?<>:| 89920. |
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/sh | |
## if you want to run toplog_per_minute.sh in background | |
## you have to use leading script to put it into backgroud without | |
## issue of "Stopped (tty output)" Error Message of script that | |
## stucked on busybox top command | |
## tested in BusyBox v1.20.2 | |
################################################################## | |
/bin/sh /mnt/nand/toplog_per_minute.sh & |
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
/build$ make -v | |
GNU Make 4.1 | |
Built for x86_64-pc-linux-gnu | |
Copyright (C) 1988-2014 Free Software Foundation, Inc. | |
License GPLv3+: GNU GPL version 3 or later | |
This is free software: you are free to change and redistribute it. | |
There is NO WARRANTY, to the extent permitted by law. | |
/build$ lsb_release -a | |
No LSB modules are available. |
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
current_mk_abspathname := $(abspath $(lastword $(MAKEFILE_LIST))) | |
current_mk_absdir := $(dir $(current_mk_abspathname)) | |
all: | |
@echo "Makefile absolute pathname: $(current_mk_abspathname)" ; \ | |
echo "Makefile absolute path: $(current_mk_absdir)" |
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
import yaml | |
document = """ | |
a: 1 | |
b: | |
c: 3 |
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 | |
i=1 | |
while [ ! "x$1" = "x" ]; do | |
echo "argv[$i]=[$1]" | |
shift | |
i=$((i + 1)) | |
done |
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 | |
# 2019 Ben Wei <ben@juluos.org> | |
# | |
# This is a example script for CI tests for blog | |
# if not defined in environment variable | |
# you can use the following command to defined it | |
# | |
# export TEST_SSH_HOST="your_ssh_host" |
NewerOlder