Wttr.in, bincika yanayin yanayin daga tashar

game da Wttr.in

A cikin labarin na gaba zamu kalli wttr.in. Wannan shi ne sabis ɗin hasashen yanayi wanda zai ba mu wasu kyawawan abubuwa. Zai ba mu damar tuntuɓar yanayin daga layin umarni a hanya mai sauƙi da sauri.

Shirin na iya gano wurin mu ta atomatik (bisa ga adireshin IP ɗinmu), haka nan za mu iya tantance wurin ko bincika yanayin wuri (cKamar abin tunawa, dutse, da dai sauransu.) da ƙari. Amma mafi kyau duka, shine ba za mu girka shi ba. Abin da kawai za mu buƙaci shine CURL ko wget.

Janar fasali na wttr.in

  • Wannan shirin mun nuna yanayin yanzu da hasashen kwanaki 3. Wannan ya kasu kashi biyu, safe, azahar, la'asar da kuma dare. Hakanan ya haɗa da kewayon zafin jiki, gudun da kuma inda iska take, yawan hazo da yuwuwarta.
  • A shafin GitHub sun gaya mana cewa muna iya gani matakan watan kowane ɗayan ranakun.
  • Zamu iya amfani da gano atomatik na a wuri dangane da adireshin IP.
  • Zamu iya tantance wurin amfani da sunan birni, lambar filin jirgin sama mai lamba 3, lambar yanki, tsarawar GPS, adireshin IP ko sunan yanki. Hakanan zamu sami ikon tantance yankin wuri kamar tabki, dutse ko alama.
  • Yarda sunayen wuri masu yare da yawa. A wannan halin, dole ne a ayyana zaren tambaya a cikin Unicode.
  • Wani fasalin da ke akwai zai kasance damar tantance harshen da ya kamata a nuna hasashen yanayi. Na goyon bayan fiye da 50 harsuna.
  • Yi amfani da raka'a USCS don tambayoyin Amurka da tsarin awo don sauran duniya. Ana iya canza wannan ta ƙara Kuna don USCS y ? m don tsarin awo.
  • Za mu samu Tsarin fitarwa 3: ANSI don tashar, HTML don mai bincike da PNG.

Amfani da Wttr.in

Kamar yadda aka ambata a farkon post, don amfani da wttr.in, duk abin da muke bukata shine CURL ko Wget, amma kuma za mu iya girka shi a kan sabarmu don yin tambaya daga yanar gizo.

Kafin amfani da wttr.in, dole ne mu tabbatar cewa an sanya CURL akan kwamfutarmu. A cikin Debian, Ubuntu ko Linux Mint, za mu iya shigar da cURL ta amfani da wannan umarnin a cikin tashar (Ctrl + Alt + T):

sudo apt install curl

Wasu misalai na wttr.in

Nuna yanayi bisa ga IP ɗinmu

Shirin ya nuna mana yanayin wurin da muke. Gwada kimar wurin mu dangane da adireshin IP. A halin da nake ciki dole ne in faɗi cewa saboda wurin da mai samar da intanet na ke, ya gaza na 'yan kilomita kaɗan.

Wttr wuri ta IP

curl wttr.in

wget Hakanan zai iya taimaka mana, maimakon CURL, idan muna son bincika yanayin yanzu:

Wget wttr.in wuri ta ip

wget -O- -q wttr.in

A cikin dukkan umarnin da za'a nuna a ƙasa, za mu iya maye gurbin curl da wget -O- -q idan muka fi son Wget akan cURL.

Lokacin wuri

wttr tantancewa wani wuri

Muna iya neman shirin ya nuna mana yanayin wani wuri ta hanyar sanya sunan wannan a cikin umarnin:

curl wttr.in/lepe

Lokacin alama

wttr tantancewa ma'anarsa

Nuna yanayin bayanai don alama ko abin tunawa. Don wannan misalin zamu ga lokacin da zamu sami kanmu a cikin Ruwa na Segovia tare da wannan umarnin:

curl wttr.in/~Acueducto+Segovia

Lokacin wuri bisa ga IP

Wttr wuri dangane da IP ɗin da aka bayar

Za mu sami zaɓi don samun bayanin yanayi don wurin adireshin IP. IP ɗin da aka yi amfani da shi a cikin wannan misalin na Google ne:

curl wttr.in/@216.58.211.35

Lokaci da aka ajiye a cikin hoto .png

Tsinkaya wttr.in a cikin .png

Zamu iya amfani da Wget don zazzagewa Yanayi na yau da kuma tsinkayen kwanaki 3 azaman hoto na PNG. Hakanan zamu iya tantancewa matakin nuna gaskiya PNG. Ga wannan misali, curl ba zai yi aiki ba.

wget wttr.in/Madrid.png

Sauran misalai

Don samun damar sani wasu misalai, Zamu iya zuwa shafin GitHub na aikin wttr.in. Hakanan zamu sami bayanai masu amfani ta hanyar buga abubuwa masu zuwa a cikin tashar (Ctrl + Alt T):

Wttr.in taimaka umarni

curl wttr.in/:help

Abubuwan da ke cikin labarin suna bin ka'idodinmu na ka'idojin edita. Don yin rahoton kuskure danna a nan.

Kasance na farko don yin sharhi

Bar tsokaci

Your email address ba za a buga.

*

*

  1. Mai alhakin bayanan: Miguel Ángel Gatón
  2. Dalilin bayanan: Gudanar da SPAM, gudanar da sharhi.
  3. Halacci: Yarda da yarda
  4. Sadarwar bayanan: Ba za a sanar da wasu bayanan ga wasu kamfanoni ba sai ta hanyar wajibcin doka.
  5. Ajiye bayanai: Bayanin yanar gizo wanda Occentus Networks (EU) suka dauki nauyi
  6. Hakkoki: A kowane lokaci zaka iyakance, dawo da share bayanan ka.