-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathexamples.sh
More file actions
36 lines (32 loc) · 963 Bytes
/
Copy pathexamples.sh
File metadata and controls
36 lines (32 loc) · 963 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#!/bin/bash
# Lista 10 URL-i z Pomorza (główne domeny)
urls=(
"https://pracodawcypomorza.pl"
"https://www.ekspresowastrona.pl"
"https://brainbox.com.pl"
"https://rafineriagdanska.pl"
"https://administrator.gda.pl"
"https://axsoft.pl"
"https://www.gdyniaprzedsiebiorcza.pl"
"https://zielone-grabelki.pl"
"https://projektfirmagdynia.com.pl"
"https://sklepagd.slupsk.pl"
)
# Funkcja wyciągająca domenę (bez protokołu, ścieżek, /kontakt itp.)
extract_domain() {
local url="$1"
# Usuń protokół http(s)://
url="${url#*://}"
# Usuń wszystko od pierwszego /
url="${url%%/*}"
# Usuń port :XXXX
url="${url%:*}";
echo "$url"
}
echo "# Przykłady poleceń nlp2cmd dla Pomorza (tylko domeny główne):"
echo
# Generuj polecenia dla każdej domeny
for url in "${urls[@]}"; do
domain=$(extract_domain "$url")
echo "nlp2cmd -r \"wejdź na https://$domain znajdź formularz kontaktu i wypełnij formularz i wyślij\""
done