sync: 2026-11-17 16:15
This commit is contained in:
1 parent
abf1b7ce07
commit
c4a601a243
2 files changed
+21
-1
No files matched your search
@@ -4,12 +4,23 @@ if [[ $# -lt 2 ]]; then
|
|||||||
echo "usage: $0 <SRC_FILE> <DST_FILE>"
|
echo "usage: $0 <SRC_FILE> <DST_FILE>"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
echo -n "" >$2
|
|
||||||
|
if [[ $(cat $2) -gt 0 ]]; then
|
||||||
|
read -p "$2 exists. Overwrite? Yes/No --> " -r choice
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ $choice = "Yes" ]]; then
|
||||||
|
echo "overwriting $2 !"
|
||||||
|
echo -n "" >$2
|
||||||
|
fi
|
||||||
|
|
||||||
for line in $(cat $1); do
|
for line in $(cat $1); do
|
||||||
|
|
||||||
l1=$(expr substr $line 1 8)
|
l1=$(expr substr $line 1 8)
|
||||||
l2=$(expr substr $line 9 8)
|
l2=$(expr substr $line 9 8)
|
||||||
l3=$(expr substr $line 18 8)
|
l3=$(expr substr $line 18 8)
|
||||||
l4=$(expr substr $line 26 8)
|
l4=$(expr substr $line 26 8)
|
||||||
|
|
||||||
echo "$((2#$l1)).$((2#$l2)).$((2#$l3)).$((2#$l4))" >>$2
|
echo "$((2#$l1)).$((2#$l2)).$((2#$l3)).$((2#$l4))" >>$2
|
||||||
|
|
||||||
done
|
done
|
||||||
@@ -1,3 +1,12 @@
|
|||||||
178.226.14.114
|
178.226.14.114
|
||||||
229.197.178.82
|
229.197.178.82
|
||||||
50.230.8.114
|
50.230.8.114
|
||||||
|
178.226.14.114
|
||||||
|
229.197.178.82
|
||||||
|
50.230.8.114
|
||||||
|
178.226.14.114
|
||||||
|
229.197.178.82
|
||||||
|
50.230.8.114
|
||||||
|
178.226.14.114
|
||||||
|
229.197.178.82
|
||||||
|
50.230.8.114
|
||||||
Reference in new issue
Block a user