RosettaCodeData/Task/Take-notes-on-the-command-line/PowerShell/take-notes-on-the-command-line.psh
Ingy döt Net 68f8f3e56b all tasks
2013-04-11 01:07:29 -07:00

9 lines
202 B
Text

$notes = "notes.txt"
if (($args).length -eq 0) {
if(Test-Path $notes) {
Get-Content $notes
}
} else {
Get-Date | Add-Content $notes
"`t" + $args -join " " | Add-Content $notes
}