-
-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #262 from veracioux:tuterm_demo
Add automated CLI demonstrations Contributors: * @veracioux * @spirillen
- Loading branch information
Showing
8 changed files
with
93 additions
and
0 deletions.
There are no files selected for viewing
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Common config for demo scripts | ||
configure() { | ||
DELAY=0.07 | ||
DELAY_SEP=0.22 | ||
DELAY_PROMPT=0.6 | ||
|
||
# No messages/warnings in the current versions of the scripts | ||
# but if we add them, their colors can be changed here | ||
# COLOR_WARNING='1;91' | ||
# COLOR_MESSAGE='1;32' | ||
|
||
# If you want to use the colorful prompt | ||
TUTERM_NAME='PyFunceble-demo' | ||
# Set the terminal width/height | ||
} | ||
|
||
prompt() { | ||
# For a more colorful prompt, uncomment the following: | ||
# echo -ne "\033[1;94m$TUTERM_NAME \033[1;35m$(pwd | sed "s:$HOME:~:")\033[0;33m $\033[0m " | ||
echo -n '[funilrys@funilrys PyFunceble]$ ' | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#!/usr/bin/env tuterm | ||
|
||
source config.sh.in | ||
|
||
run() { | ||
c PyFunceble --version | ||
c PyFunceble -a -d example.org | ||
c PyFunceble -a -d example.org --whois-lookup | ||
c PyFunceble -a -d exampleee.com | ||
c PyFunceble -a -d microsoft_google.com | ||
c exit | ||
} | ||
|
||
# vim: filetype=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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#!/usr/bin/env tuterm | ||
|
||
source config.sh.in | ||
|
||
run() { | ||
c PyFunceble --version | ||
c PyFunceble -d 9.9.9.9 # Neutral stable | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong. |
||
c PyFunceble -d 2620:fe::fe # quad9 IPv6 (As I recall GHA now supports IPv6) | ||
c PyFunceble -d 194.187.99.221 # Adult CDN: https://mypdns.org/my-privacy-dns/porn-records/-/issues?scope=all&state=all&label_name[]=IP%3A%3ABlackListing | ||
c PyFunceble -d 45.136.204.40 # 23 phis: https://github.com/mitchellkrogza/phishing/pull/67 | ||
c PyFunceble -u http://18.191.88.103/login.html # As we can do urls too, this is a inactive Phis | ||
c exit | ||
} | ||
|
||
# vim: filetype=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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#!/usr/bin/env tuterm | ||
|
||
source config.sh.in | ||
|
||
run() { | ||
c PyFunceble --version | ||
c PyFunceble -u https://github.com/funilrys | ||
c PyFunceble -u https://github.com/microsoft_google | ||
c PyFunceble -u https://microsoft_google.com | ||
c PyFunceble -u https://microsoft_google.com --local | ||
c exit | ||
} | ||
|
||
# vim: filetype=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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#!/usr/bin/env sh | ||
|
||
set -e | ||
|
||
# Pre-warm PyFunceble for better performance | ||
echo Pre-warming for better recording performance | ||
for i in $(seq 1 10); do | ||
PyFunceble --version >/dev/null | ||
done | ||
|
||
for file in "$@"; do | ||
mkdir -p "/tmp/PyFunceble" | ||
cast="/tmp/PyFunceble/$(basename "$file").cast" | ||
rm -f "$cast" | ||
stty cols 166 rows 45 | ||
asciinema rec -c "tuterm $file --mode demo" "$cast" | ||
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#!/usr/bin/env sh | ||
|
||
set -e | ||
|
||
for file in "$@"; do | ||
cast="/tmp/PyFunceble/$(basename "$file").cast" | ||
asciinema upload "$cast" | grep 'https:' | sed 's/^\s*//' | ||
done |
This should be
9.9.9.10
for a unfiltered lookup