Book Image

Mastering Windows PowerShell Scripting

By : Brenton J.W. Blawat
Book Image

Mastering Windows PowerShell Scripting

By: Brenton J.W. Blawat

Overview of this book

Table of Contents (22 chapters)
Mastering Windows PowerShell Scripting
Credits
Foreword
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Chapter 8. Managing Files, Folders, and Registry Items

When you are automating tasks on servers and workstations, you will frequently run into situations where you need to manage files, folders, and registry items. PowerShell provides a wide variety of cmdlets that enable you to create, view, modify, and delete items on a system.

In this chapter, you will learn many techniques to interact with files, folders, and registry items. These techniques and items include:

  • Registry provider

  • Creating files, folders, registry keys, and registry named values

  • Adding named values to registry keys

  • Verifying the existence of item files, folders, and registry keys

  • Renaming files, folders, registry keys, and named values

  • Copying and moving files and folders

  • Deleting files, folders, registry keys, and named values

Note

To properly follow the examples in this chapter, you will need to sequentially execute the examples. Each example builds on the previous examples, and some of these examples may not function properly...