Keep in mind that the Measure-Command cmdlet is not accurate at the millisecond level therefore, the results essentially state that the two commands took basically the same. The results state that the command tool 107 milliseconds (19 milliseconds longer). It took me less than a minute to come up with the following command.ĭir C:\data\BookDOcs\Win7ResKit\Scripts -Recurse -Filter *.ps1 | Yep, the pen is more powerful than the sword, and Windows PowerShell is more powerful than the mouse. No, this is a job for Windows PowerShell, not for the mouse. The thought of clicking through 35 folders and copying and pasting to another folder, however, really creeps me out-not to mention that my wrist and clicky finger would probably give out about half way through the process. Therefore, if I need to find the script I wrote that sets a static IP address, subnet mask, default gateway, and DNS server, I spend a lot of time clicking or I use the search to attempt to find the script.įor me, anyway, it is easier to look in a single folder for a script titled something like Set-StaticIPAddress.ps1. In addition, each collection of scripts is related to a particular topic. But for some of the chapters, I did not write any scripts, and for other chapters I wrote as many as 40 scripts. In the image that follows, I show the script folder that contains the scripts I wrote for the Windows 7 Resource Kit that was published by Microsoft Press.įor most of the chapters, I wrote an average of 15 scripts. This is one reason I give my scripts such descriptive names-to make it easier for me to recognize them once I find them. To put it another way…Often I end up browsing for my scripts, rather than searching for them. For one thing, I have a hard time remembering what scripts I have written, and if I do not remember having written a script, it is hard to search for it. One problem I have always had involves finding scripts I have written. It is truly inspirational.Īnyway, with a significant amount of time taken up by the system idle process, it is important that the remaining processes are efficient. Note If you missed yesterday’s guest blog by Windows PowerShell MVP, Bartek Bielawski, How I won the Scripting Games, a Pass to TechEd, and Became an MVP, you should go back and read it. ![]() But hey, such things are often necessary. Like running on a treadmill, it is a bit difficult to see any actual forward progress. The end result is a great workout that expends several hundred calories. I also spend a significant amount of time jumping through hoops to meet various deadlines for items that have no lead-time. I spend the day running around going from meeting to meeting. Well, it is Monday in Charlotte, North Carolina, in the United States. Microsoft Scripting Guy, Ed Wilson, is here. Summary: Microsoft Scripting Guy, Ed Wilson, talks about using Windows PowerShell to copy a script collection to a shared network drive.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |