mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-02-16 17:51:28 +01:00
Changed to lowercase
This commit is contained in:
parent
9618b25d80
commit
ea1b2554c0
Can't render this file because it is too large.
|
Can't render this file because it has a wrong number of fields in line 2.
|
@ -1,15 +1,15 @@
|
|||||||
#!/snap/bin/powershell
|
#!/snap/bin/powershell
|
||||||
<#
|
<#
|
||||||
.SYNTAX ./list-logbook.ps1
|
.SYNTAX ./list-logbook.ps1
|
||||||
.DESCRIPTION lists the content of the logbook (../Data/Logbook.csv)
|
.DESCRIPTION lists the content of the logbook (in ../Data/logbook.csv)
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.LINK https://github.com/fleschutz/PowerShell
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
.NOTES Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
write-progress "Reading Data/logbook.csv..."
|
||||||
$PathToRepo=(get-item $MyInvocation.MyCommand.Path).directory.parent
|
$PathToRepo=(get-item $MyInvocation.MyCommand.Path).directory.parent
|
||||||
|
$Table = import-csv "$PathToRepo/Data/logbook.csv"
|
||||||
$Table = import-csv "$PathToRepo/Data/Logbook.csv"
|
|
||||||
|
|
||||||
write-output ""
|
write-output ""
|
||||||
write-output "Time User Text"
|
write-output "Time User Text"
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
write-progress "Reading scripts.csv..."
|
write-progress "Reading Data/scripts.csv..."
|
||||||
$PathToRepo = (get-item $MyInvocation.MyCommand.Path).directory.parent
|
$PathToRepo = (get-item $MyInvocation.MyCommand.Path).directory.parent
|
||||||
$Table = import-csv "$PathToRepo/Data/scripts.csv"
|
$Table = import-csv "$PathToRepo/Data/scripts.csv"
|
||||||
|
|
||||||
|
@ -7,9 +7,9 @@
|
|||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
write-progress "Reading Matrix.csv..."
|
write-progress "Reading Data/matrix.csv..."
|
||||||
$PathToRepo=(get-item $MyInvocation.MyCommand.Path).directory.parent
|
$PathToRepo=(get-item $MyInvocation.MyCommand.Path).directory.parent
|
||||||
$Table = import-csv "$PathToRepo/Data/Matrix.csv"
|
$Table = import-csv "$PathToRepo/Data/matrix.csv"
|
||||||
|
|
||||||
clear-host
|
clear-host
|
||||||
foreach($Row in $Table) {
|
foreach($Row in $Table) {
|
||||||
|
@ -11,8 +11,9 @@ Set-StrictMode -Version Latest
|
|||||||
try {
|
try {
|
||||||
$StartTime = Get-Date
|
$StartTime = Get-Date
|
||||||
|
|
||||||
|
write-progress "Reading Data/domain-names.csv..."
|
||||||
$PathToRepo=(get-item $MyInvocation.MyCommand.Path).directory.parent
|
$PathToRepo=(get-item $MyInvocation.MyCommand.Path).directory.parent
|
||||||
$Table = import-csv "$PathToRepo/Data/domain_table.csv"
|
$Table = import-csv "$PathToRepo/Data/domain-names.csv"
|
||||||
|
|
||||||
foreach($Row in $Table) {
|
foreach($Row in $Table) {
|
||||||
$Domain = $Row.Domain
|
$Domain = $Row.Domain
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#!/snap/bin/powershell
|
#!/snap/bin/powershell
|
||||||
<#
|
<#
|
||||||
.SYNTAX ./write-logbook.ps1 [<text>]
|
.SYNTAX ./write-logbook.ps1 [<text>]
|
||||||
.DESCRIPTION writes the given text to the logbook (../Data/Logbook.csv)
|
.DESCRIPTION writes the given text to the logbook (in ../Data/logbook.csv)
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.LINK https://github.com/fleschutz/PowerShell
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
.NOTES Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
@ -17,7 +17,7 @@ try {
|
|||||||
$Line = "$Time,$User,$Text"
|
$Line = "$Time,$User,$Text"
|
||||||
|
|
||||||
$PathToRepo=(get-item $MyInvocation.MyCommand.Path).directory.parent
|
$PathToRepo=(get-item $MyInvocation.MyCommand.Path).directory.parent
|
||||||
write-output $Line >> "$PathToRepo/Data/Logbook.csv"
|
write-output $Line >> "$PathToRepo/Data/logbook.csv"
|
||||||
exit 0
|
exit 0
|
||||||
} catch {
|
} catch {
|
||||||
write-error "ERROR in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
write-error "ERROR in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||||
|
Loading…
Reference in New Issue
Block a user