Conference Presentation, Tutorial, Keynote
Don Jones: 13 Years in a Shell: Lessons, Practices, and Achievements in PowerShell
Event Context & Attendee Engagement
- Hosts: Arnold (Jane Street Windows team member) and Doug Fake (New York PowerShell user group organizer).
- Community Scale: The New York meetup occurs monthly; past events have included attendees traveling to the West Coast summit and an upcoming summit in Singapore.
- Future Events:
- A DevOps Automation Summit is scheduled for Nashville in Fall 2020.
- CodeCamps are planned for New York in September and October.
- Jane Street continues to host community meetups to foster Windows infrastructure automation expertise.
Speaker Profile: Don Jones
- Experience: Working with PowerShell for over 13 years; began before the tool's November 2006 launch at TechEd Europe in Barcelona.
- Early Career:
- Ran Star Trek conventions at age 15–18, learning business budgeting and logistics without formal education.
- Attended Botech for electronics repair, learning soldering and systems engineering.
- Served as a civilian Aircraft Engineering Mechanic for the Navy, performing depot-level maintenance on F-14s and A-6s; this instilled a "critical path" mindset focused on rapid repair ("getting the plane back in the air") rather than perfect aesthetics.
- Worked at Electronics Boutique (pre-GameStop) as a sales associate and later as an AS/400 operator, transitioning from VBScript to PowerShell on the job.
- Current Role: Staff writer at Pluralsight; author of numerous PowerShell books; transitioning from technical roles to business management and strategy.
Technical Best Practices & Anti-Patterns
- Function Design (The "Single Responsibility" Principle):
- Functions should perform one specific task; mixing data ingestion sources (e.g., accepting both direct input and file paths) creates unnecessary complexity and prevents reuse.
- Use the pipeline for data flow (e.g.,
Get-ComputerNamepiped to a function) rather than building multiple parameters for data sources. - Adopt the SOLID principles, specifically the Single Responsibility Principle (SRP), to make tools easier to unit test and maintain.
- Output Handling:
- Avoid
Format-*cmdlets (likeFormat-Table) within scripts; they convert objects into text/garbage, breaking the pipeline. Output raw objects to allow downstream processing. - Avoid
Write-Host: It is hard-coded to the screen and breaks pipeline functionality; useWrite-Information,Write-Verbose,Write-Warning, orWrite-Debuginstead. - Avoid Global Variables: They cause reliability issues in different hosting engines (e.g., VS Code, GUI scripts); use script-scoped or module-level variables instead.
- Return Keyword: Do not use
returnin functions (except in classes) as it is syntactic sugar that confuses readers accustomed to other languages; useWrite-Outputand standard control flow (break,continue) for exits.
- Avoid
- Coding Style & Tools:
- Format Code: Indent all code; use VS Code for editing and debugging; do not use the legacy PowerShell ISE (which is no longer supported and has scope maintenance issues).
- Naming Conventions: Strictly use approved verbs from
Get-Verb; do not invent new verbs. - Classes: Avoid PowerShell classes for general scripting; they are poorly supported and sketchy. Use functions for 99% of tasks. Use classes only for predefined data structures where C# would be a better fit.
- Documentation: Use comment-based help and markdown (via tools like Platypus); treat documentation as a professional requirement.
- Source Control: Adopt Git or Azure DevOps; abandon legacy tools like Visual SourceSafe, CDS, or Subversion.
- Testing: Implement Test-Driven Development (TDD) using Pester; write tests before code to define functional specifications.
Professional Development & Mindset
- Career vs. Job:
- Your "job" is owned by your employer; your "career" is owned by you.
- Employees must proactively invest in skills (buying books, paying for Azure experiments) to ensure market value, as companies may not always provide training for emerging technologies.
- Job titles do not define identity; flexibility allows individuals to pivot between roles (e.g., becoming a "generalist" or "polyglot" in multiple languages/tools).
- Learning Techniques:
- Cognitive Science: Deep learning requires engaging multiple senses; passive consumption (videos during the day) is less effective than active, deliberate practice (writing by hand, creating a specific learning environment).
- Imposter Syndrome: Acknowledge that expertise is not required to teach or lead; the goal is to help others progress.
- Leadership Philosophy:
- The "First Follower": Reference to the "shirtless dancer" video illustrates that movements grow when a leader is supported by a "first follower" who normalizes the behavior, making it safer for others to join.
- Failure as Learning: Encourage calculated risk-taking; failing quickly and documenting the "why" allows others to learn without repeating the mistake.
DevOps Strategy & Organizational Structure
- Definition: DevOps is a management methodology, not a specific technology or box to buy; its goal is rapid, continuous deployment.
- Organizational Alignment:
- Traditional "throw-over-the-wall" models (Dev -> IT Ops) cause friction and slow deployment.
- DevOps Model: Teams are organized around specific products/outcomes, mixing developers, UX, and ops on a single cross-functional team.
- Guilds: Professional "guilds" (e.g., Developer Guild) float between teams to ensure consistency in standards, naming, and practices without being in a separate silo.
- Market Reality:
- All companies are now "tech companies"; speed to market is measured in days, not years.
- Legacy systems (COBOL, monolithic architectures) are insufficient for competing with agile startups; agility and multi-platform proficiency (Windows/Linux, PowerShell/Python) are critical for survival.
- Companies that cannot adapt technologically risk obsolescence.
Industry Commentary & Q&A
- Tool Selection:
- Cross-Platform PowerShell: Acknowledged as immature for Linux automation compared to Python's mature libraries; recommend using the right tool for the specific OS and task.
- Legacy Oddities:
Filterconstruct in PowerShell: A remnant of a beta version that was never removed; it has no logical purpose in modern scripting.Returnkeyword: Regretted by the PowerShell team for introducing confusion; its removal is not imminent but should be avoided by new code.
- Future Outlook:
- Don Jones is stepping away from PowerShell.org and the DevOps Collective to focus on business strategy and writing business/management books.
- Resource Sharing: Don Jones promotes his books on LeanPub (agile publishing, pay-what-you-want model); a bundle URL was shared for a limited time to access his collection including Learn PowerShell in a Month of Lunches and Scripting and Tool Making.