Code Camp tutorial on Powershell.
- To have a basic understanding of Powershell and be able to sit down at a console and write your own script.
- Who has used powershell?
- What is it?
- Who hasn't used it?
- Who has used UNIX?
- Windows Automation engine
- Foundation of new Server Technologies
- Easy automation of repetitive task
- Full fledge shell and language
- Should be able to do everything in normal command prompt
- dir, cd, ipconfig, notepad
- ls, cd, ps, cat!!
- A lot!
- Cmdlet's and Pipeline
- CORE of Powershell
- First cmdlet get-command
- Consistent name scheme (Verb-Noun)
- Standard format for parameters
- -Verb? oops, try get-help
- get-help get-command
- Verb takes string[]
- get-command -verb get
- get-command -verb get,start
- Standard output
- Is it just string output?
- It is output to a pipeline...
- ls | out-default
- ls | format-table
- ls | format-list
- get-command -verb start
- get-command -verb start | format-list
- get-command -verb start | gm
- Variables
- get-date
- get-date | gm
- $date = get-date
- $date | gm
- $date.adddays(5)
- $date.second
- $second = $date.second
- $second | gm
- $second = "asdf"
- LOOSLY TYPED
- CASE INSENSITIVE
- if/else
- for
- foreach
- where
- foreach
- Math Problem
- get-tweets
- update-status