Prompt Computer


posted by Richard Giles
02-17-2009

Downloads: 305
File size: 625 B
Views: 1,003

Embed
Prompt Computer
  1. <?xml version="1.0"?> 
  2. <CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet"
  3.     <CodeSnippet Format="1.0.0"
  4.         <Header> 
  5.             <Title>Prompt with computername</Title> 
  6.             <Shortcut /
  7.             <Description>Simple prompt function that displays your computername</Description> 
  8.             <Author>Dr. Tobias Weltner http://www.powershell.de</Author> 
  9.             <SnippetTypes> 
  10.                 <SnippetType>Expansion</SnippetType> 
  11.             </SnippetTypes> 
  12.         </Header> 
  13.         <Snippet> 
  14.             <Code Language="PowerShell" Kind="2"><![CDATA[function Prompt { 
  15.   "PS [$env:computername] >" 
  16. }]]></Code> 
  17.         </Snippet> 
  18.     </CodeSnippet> 
  19. </CodeSnippets> 
Filed under: ,

Simple prompt function that displays your computername

Copyright 2012 PowerShell.com. All rights reserved.