简体   繁体   中英

Converting Bash script to PowerShell

I am writing a Wifi test script in Powershell. I have managed to do it in Bash and now I want to port it. I am looking for command similar to:

  1. Syslog: to log WPA and SSID changes.
  2. Iwconfig: which logs current wifi config

Here's my current script:

#!/bin/sh
/var/log/syslog | grep SSID /var/log/syslog | grep wpa

Windows dont work like linux do and so on.. So there is much to think of here and there are no simple way to get the information that you want here.


"1. Syslog: to log WPA and SSID changes"

For this one we would need to bind the drivers you have and make them output it to where it should be readable. And so on..

"2. Iwconfig: which logs current wifi config"

This.. ipconfig is the command who is closest but dosent do what you want in this one.


I would suggest that you try something in visual basic or maybe python. Dont think it is a simple way to do this..

Hope it helped somehow.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM