Atjaunināt sīkdatņu piekrišanu

Learn PowerShell in a Month of Lunches: Covers Windows, Linux, and macOS [Mīkstie vāki]

4.38/5 (53 ratings by Goodreads)
  • Formāts: Paperback / softback, 375 pages, height x width x depth: 234x186x15 mm, weight: 660 g
  • Izdošanas datums: 07-Jun-2022
  • Izdevniecība: Manning Publications
  • ISBN-10: 1617296961
  • ISBN-13: 9781617296963
  • Mīkstie vāki
  • Cena: 44,30 €
  • Grāmatu piegādes laiks ir 3-4 nedēļas, ja grāmata ir uz vietas izdevniecības noliktavā. Ja izdevējam nepieciešams publicēt jaunu tirāžu, grāmatas piegāde var aizkavēties.
  • Daudzums:
  • Ielikt grozā
  • Piegādes laiks - 4-6 nedēļas
  • Pievienot vēlmju sarakstam
  • Formāts: Paperback / softback, 375 pages, height x width x depth: 234x186x15 mm, weight: 660 g
  • Izdošanas datums: 07-Jun-2022
  • Izdevniecība: Manning Publications
  • ISBN-10: 1617296961
  • ISBN-13: 9781617296963
"Not only for MacOS and Linux users, but also a great resource for Windows PS users." - Bruce Bergman

Learn PowerShell in a Month of Lunches: Covers Windows, Linux, and macOS is a task-focused tutorial for administering Linux and macOS systems using Microsoft PowerShell. Adapted by PowerShell team members Travis Plunk and Tyler Leonhardt from the bestselling Learn Windows PowerShell in a Month of Lunches by community legends Don Jones and Jeffrey Hicks, it features Linux-based examples covering core language features and admin tasks. Designed for busy IT professionals, this innovative guide will take you from the basics to PowerShell proficiency through 25 tutorials you can do in your lunch break.

about the technology The PowerShell scripting language and administrative shell was initially created for Windows, providing a high-quality command-line interface and awesome automation features. As part of Microsoft's ongoing strategy to support non-Windows platforms with its Azure cloud service and .NET Core framework, PowerShell now runs on Linux and macOS. Like Bash, PowerShell can execute and script nearly any aspect of Linux, so you can easily manage repetitive daily tasks, servers, Cloud resources, Continuous Integration pipelines, and more. Because PowerShell is a full-featured programming language, however, it provides capability well beyond traditional shell scripting languages, such as the ability to treat OS components as objects.

about the book Learn PowerShell in a Month of Lunches: Covers Windows, Linux, and macOS is a user-friendly tutorial to managing Linux and macOS systems with PowerShell. It's based on the bestselling Learn Windows PowerShell in a Month of Lunches, which has introduced PowerShell to nearly 100,000 readers. You'll learn how PowerShell shapes up to Bash or Python scripting as you write and run simple scripts that automate boring daily tasks. As you progress through the book, you'll use PowerShell to write Continuous Integration Pipelines and manage cloud-based servers. Just set aside one hour a day for a month, and you'll be automating tasks faster than you ever thought possible!

what's inside - Why you should use PowerShell on Linux and macOS - Background jobs and automation techniques - Simple scripting to automate repetitive daily tasks - Common syntax and commands cheat sheet - Each lesson takes you an hour or less

about the reader For IT professionals comfortable administering Windows or Linux. No previous experience with PowerShell or Bash required.

about the author Travis Plunk has been a Software Engineer on various PowerShell teams since 2013, and at Microsoft since 1999. He was involved in open sourcing PowerShell and has worked on the project full time since shortly after the project was announced.

James Petty is a Microsoft MVP, and the CEO and Executive Director for the DevOps Collective and PowerShell.org.

Tyler Leonhardt has been a Software Engineer on the PowerShell team since 2017, and at Microsoft since 2016. He is a core maintainer of the PowerShell extension for Visual Studio Code.

Learn Windows PowerShell in a Month of Lunches was written by PowerShell community legends Don Jones and Jeffrey Hicks, who have years of experience as successful PowerShell trainers.

Recenzijas

Notonly for MacOS and Linux users, but also a great resource for Windows PS users.  Bruce Bergman

Gives developers a lot of insight on how PowerShell works and how to accomplish everyday tasks. Marcel van den Brink

This book enabled me to quickly get using PowerShell for real-lifetasks. Rick Michaels

The book is great, especially if you have no previous experience with PowerShell, tasks automation, or DevOps. Max Almonte

Approaches PowerShell from a building block like perspective. FosterHaines



Unlike other PowerShell type books, this book expands beyond just Windows environments to accommodate those on Mac or Linux platforms who may want to explore this area as well. James Matlock

Foreword xvii
Preface xx
Acknowledgments xxii
About This Book xxiii
About The Authors xxvi
1 Before You Begin 1(7)
1.1 Why you can no longer afford to ignore PowerShell
1(2)
Life without PowerShell
2(1)
Life with PowerShell
2(1)
1.2 Windows, Linux, and macOS, oh my
3(1)
1.3 Is this book for you?
3(1)
1.4 How to use this book
4(2)
The chapters
4(1)
^ Hands-on labs
5(1)
Supplementary materials
5(1)
Further exploration
5(1)
Above and beyond
5(1)
1.5 Setting up your lab environment
6(1)
1.6 Installing PowerShell
6(1)
1.7 Contacting us
7(1)
1.8 Being immediately effective with PowerShell
7(1)
2 Meet PowerShell 8(17)
2.1 PowerShell on Windows
9(3)
2.2 PowerShell on macOS
12(1)
Installation on macOS
12(1)
2.3 PowerShell on Linux (Ubuntu 18.04)
13(1)
Installation on Ubuntu 18.04
14(1)
2.4 Visual Studio Code and the PowerShell extension
14(7)
Installing Visual Studio Code and the PowerShell extension
15(1)
Getting familiar with Visual Studio Code
16(3)
Customizing Visual Studio Code and the PowerShell extension
19(2)
2.5 It's typing class all over again
21(2)
2.6 What version is this?
23(1)
2.7 Lab
23(2)
3 Using the help system 25(17)
3.1 The help system: How you discover commands
25(2)
3.2 Updatable help
27(1)
3.3 Asking for help
28(1)
3.4 Using help to find commands
29(2)
3.5 Interpreting the help
31(7)
Parameter sets and common parameters
31(1)
Optional and mandatory parameters
32(1)
Positional parameters
33(2)
Parameter values
35(2)
Finding command examples
37(1)
3.6 Accessing "about" topics
38(1)
3.7 Accessing online help
38(1)
3.8 Lab
39(1)
3.9 Lab answers
40(2)
4 Running commands 42(16)
4.1 Let's talk security
42(4)
Execution policy
43(3)
4.2 Not scripting, but running commands
46(1)
4.3 The anatomy of a command
47(1)
4.4 The cmdlet naming convention
48(1)
4.5 Aliases: Nicknames for commands
49(1)
4.6 Taking shortcuts
50(2)
Truncating parameter names
50(1)
Using parameter name aliases
50(1)
Using positional parameters
51(1)
4.7 Support for external commands
52(2)
4.8 Dealing with errors
54(1)
4.9 Common points of confusion
55(1)
Typing cmdlet names
55(1)
Typing parameters
56(1)
4.10 Lab
56(1)
4.11 Lab answers
57(1)
5 Working with providers 58(11)
5.1 What are providers?
58(2)
5.2 Understanding how the filesystem is organized
60(2)
5.3 Navigating the filesystem
62(1)
5.4 Using wildcards and literal paths
63(1)
5.5 Working with other providers
64(4)
Windows Registry
65(3)
5.6 Lab
68(1)
5.7 Lab answers
68(1)
6 The pipeline: Connecting commands 69(15)
6.1 Connecting one command to another: Less work for you
69(1)
6.2 Exporting to a file
70(7)
Exporting to CSV
71(1)
Exporting to JSON
72(2)
Exporting to XML
74(1)
Out-File
74(1)
Comparing files
75(2)
6.3 Piping to a file
77(1)
6.4 Converting to HTML
78(1)
6.5 Using cmdlets that modify the system: Killing processes
79(1)
6.6 Common points of confusion
80(2)
6.7 Lab
82(1)
6.8 Lab answers
82(2)
7 Adding commands 84(10)
7.1 How one shell can do everything
84(1)
7.2 Extensions: Finding and installing modules
84(3)
7.3 Extensions: Finding and adding modules
87(3)
7.4 Command conflicts and removing extensions
90(1)
7.5 Playing with a new module
91(1)
7.6 Common points of confusion
92(1)
7.7 Lab
92(1)
7.8 Lab answers
93(1)
8 Objects: Data by another name 94(12)
8.1 What are objects?
94(1)
8.2 Understanding why PowerShell uses objects
95(2)
8.3 Discovering objects: Get-Member
97(2)
8.4 Using object attributes, or properties
99(1)
8.5 Using object actions, or methods
100(1)
8.6 Sorting objects
100(1)
8.7 Selecting the properties you want
101(1)
8.8 Objects until the end
102(2)
8.9 Common points of confusion
104(1)
8.10 Lab
104(1)
8.11 Lab answers
105(1)
9 A practical interlude 106(8)
9.1 Defining the task
106(1)
9.2 Finding the commands
106(2)
9.3 Learning to use the commands
108(4)
9.4 Tips for teaching yourself
112(1)
9.5 Lab
112(1)
9.6 Lab answer
113(1)
10 The pipeline, deeper 114(18)
10.1 The pipeline: Enabling power with less typing
114(1)
10.2 How PowerShell passes data down the pipeline
114(2)
10.3 Plan A: Pipeline input ByValue
116(3)
10.4 Plan B: Pipeline input ByPropertyName
119(4)
10.5 When things don't line up: Custom properties
123(3)
10.6 Working with Azure PowerShell
126(1)
10.7 Parenthetical commands
126(1)
10.8 Extracting the value from a single property
127(2)
10.9 Lab
129(2)
10.10 Lab answers
131(1)
10.11 Further exploration
131(1)
11 Formatting: And why it's done on the right 132(17)
11.1 Formatting: Making what you see prettier
132(1)
11.2 Working with the default formatting
132(5)
11.3 Formatting tables
137(2)
11.4 Formatting lists
139(1)
11.5 Formatting wide lists
140(1)
11.6 Creating custom columns and list entries
141(2)
11.7 Going out: To a file or to the host
143(1)
11.8 Another out: GridViews
144(1)
11.9 Common points of confusion
144(4)
Always format right
145(1)
One type of object at a time, please
146(2)
11.10 Lab
148(1)
11.11 Lab answers
148(1)
11.12 Further exploration
148(1)
12 Filtering and comparisons 149(8)
12.1 Making the shell give you just what you need
149(1)
12.2 Filtering left
150(1)
12.3 Using comparison operators
150(2)
12.4 Filtering objects out of the pipeline
152(1)
12.5 Using the iterative command-line model
153(2)
12.6 Common points of confusion
155(1)
Filter left, please
155(1)
When $ is allowed
155(1)
12.7 Lab
156(1)
12.8 Lab answers
156(1)
12.9 Further exploration
156(1)
13 Remote control: One-to-one and one-to-many 157(17)
13.1 The idea behind remote PowerShell
157(2)
Remoting on Windows devices
158(1)
Remoting on macOS and Linux devices
158(1)
Cross-platform remoting
158(1)
13.2 Setting up PSRP over SSH
159(2)
macOS and Linux
159(1)
Setting up SSH on Windows
160(1)
13.3 PSRP over SSH overview
161(1)
13.4 WinRM overview
162(2)
13.5 Using Enter-PSSession and Exit-PSSession for one-to-one remoting
164(3)
13.6 Using Invoke-ScriptBlock for one-to-many remoting
167(1)
13.7 Differences between remote and local commands
168(4)
Deserialized objects
168(2)
Local vs. remote processing
170(2)
13.8 But wait, there's more
172(1)
13.9 Common points of confusion
172(1)
13.10 Lab
172(1)
13.11 Lab answers
173(1)
13.12 Further exploration
173(1)
14 Multitasking with background jobs 174(13)
14.1 Making PowerShell do multiple things at the same time
174(1)
14.2 Synchronous vs. asynchronous
175(1)
14.3 Creating a process job
175(1)
14.4 Creating a thread job
176(1)
14.5 Remoting, as a job
177(1)
14.6 Jobs in the wild
177(2)
14.7 Getting job results
179(3)
14.8 Working with child jobs
182(1)
14.9 Commands for managing jobs
183(2)
14.10 Common points of confusion
185(1)
14.11 Lab
186(1)
14.12 Lab answers
186(1)
15 Working with many objects, one at a time 187(15)
15.1 The preferred way: "Batch" cmdlets
187(1)
15.2 The CIM way: Invoking methods
188(4)
15.3 The backup plan: Enumerating objects
192(2)
Making the cmdlets work for you
193(1)
15.4 Let's speed things up
194(3)
15.5 Common points of confusion
197(3)
Which way is the right way?
197(1)
Diminishing returns of Parallel ForEach
198(1)
Method documentation
199(1)
ForEach-Object confusion
200(1)
15.6 Lab
200(1)
15.7 Lab answers
200(2)
16 Variables: A place to store your stuff 202(16)
16.1 Introduction to variables
202(1)
16.2 Storing values in variables
202(3)
16.3 Using variables: Fun tricks with quotes
205(2)
16.4 Storing many objects in a variable
207(4)
Working with single objects in a variable
207(2)
Working with multiple objects in a variable
209(1)
Other ways to work with multiple objects
209(1)
Unrolling properties and methods in PowerShell
210(1)
16.5 More tricks with double quotes
211(1)
16.6 Declaring a variable's type
212(3)
16.7 Commands for working with variables
215(1)
16.8 Variable best practices
215(1)
16.9 Common points of confusion
216(1)
16.10 Lab
216(1)
16.11 Lab answers
216(1)
16.12 Further exploration
217(1)
17 Input and output 218(8)
17.1 Prompting for, and displaying, information
218(1)
17.2 Read-Host
219(1)
17.3 Write-Host
220(2)
17.4 Write-Output
222(1)
17.5 Other ways to write
223(2)
17.6 Lab
225(1)
17.7 Lab answers
225(1)
17.8 Further exploration
225(1)
18 Sessions: Remote control with less work 226(10)
18.1 Creating and using reusable sessions
227(2)
18.2 Enter-PSSession with session objects
229(2)
18.3 Invoke-Command with session objects
231(1)
18.4 Implicit remoting: Importing a session
231(2)
18.5 Using disconnected sessions
233(1)
18.6 Lab
234(1)
18.7 Lab answers
235(1)
18.8 Further exploration
235(1)
19 You call this scripting? 236(13)
19.1 Not programming, more like batch files
236(1)
19.2 Making commands repeatable
237(1)
19.3 Parameterizing commands
238(2)
19.4 Creating a parameterized script
240(1)
19.5 Documenting your script
241(2)
19.6 One script, one pipeline
243(2)
19.7 A quick look at scope
245(2)
19.8 Lab
247(1)
19.9 Lab answer
247(2)
20 Improving your parameterized script 249(10)
20.1 Starting point
249(1)
20.2 Getting PowerShell to do the hard work
250(1)
20.3 Making parameters mandatory
251(2)
20.4 Adding parameter aliases
253(1)
20.5 Validating parameter input
254(1)
20.6 Adding the warm and fuzzies with verbose output
255(2)
20.7 Lab
257(1)
20.8 Lab answer
257(2)
21 Using regular expressions to parse text files 259(7)
21.1 The purpose of regular expressions
259(1)
21.2 A regex syntax primer
260(2)
21.3 Using regex with -Match
262(1)
21.4 Using regex with Select-String
262(2)
21.5 Lab
264(1)
21.6 Lab answers
265(1)
21.7 Further exploration
265(1)
22 Using someone else's script 266(7)
22.1 The script
266(3)
Parameter block
268(1)
Process block
268(1)
22.2 It's a line-by-line examination
269(1)
22.3 Lab
269(2)
22.4 Lab answer
271(2)
23 Adding logic and loops 273(6)
23.1 Foreach and Foreach-Object
273(4)
Foreach
273(1)
Foreach-Object
274(1)
Foreach-Object -Parallel
275(2)
23.2 While
277(1)
23.3 Do While
278(1)
23.4 Lab
278(1)
23.5 Lab answers
278(1)
24 Handling errors 279(8)
24.1 Understanding errors and exceptions
280(1)
24.2 Bad handling
281(1)
24.3 Two reasons for exception handling
282(1)
24.4 Handling exceptions
282(2)
24.5 Handling exceptions for noncommands
284(1)
24.6 Going further with exception handling
284(1)
24.7 Lab
285(1)
24.8 Lab answer
285(2)
25 Debugging techniques 287(9)
25.1 Output everything
287(2)
25.2 One line at a time
289(4)
25.3 Hey, script, stop right there...with breakpoints
293(2)
25.4 Lab
295(1)
26 Tips, tricks, and techniques 296(14)
26.1 Profiles, prompts, and colors: Customizing the shell
296(4)
PowerShell profiles
296(2)
Customizing the prompt
298(1)
Tweaking colors
299(1)
26.2 Operators: -as, -is, -replace, -join, -split, -contains, -in
300(3)
-as and -is
300(1)
-replace
301(1)
-join and -split
301(1)
-contains and -in
302(1)
26.3 String manipulation
303(1)
26.4 Date manipulation
304(2)
26.5 Dealing with WMI dates
306(1)
26.6 Setting default parameter values
307(1)
26.7 Playing with script blocks
308(1)
26.8 More tips, tricks, and techniques
309(1)
27 Never the end 310(3)
27.1 Ideas for further exploration
310(1)
27.2 "Now that I've read the book, where do I start?"
311(1)
27.3 Other resources you'll grow to love
312(1)
Appendix PowerShell cheat sheet 313(8)
Index 321
Travis Plunk has been a Software Engineer on various PowerShell teams since 2013, and at Microsoft since 1999. He was involved in open sourcing PowerShell and has worked on the project full time since shortly after the project was announced.

James Petty is a Microsoft MVP, and the CEO and Executive Director for the DevOps Collective and PowerShell.org.

Tyler Leonhardt has been a Software Engineer on the PowerShell team since 2017, and at Microsoft since 2016. He is a core maintainer of the PowerShell extension for Visual Studio Code.

Learn Windows PowerShell in a Month of Lunches was written by PowerShell community legends Don Jones and Jeffrey Hicks, who have years of experience as successful PowerShell trainers.