mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-02-08 22:10:14 +01:00
1.5 KiB
1.5 KiB
The install-mini-dlna.ps1 Script
This PowerShell script installs the MiniDLNA server.
Parameters
/Repos/PowerShell/scripts/install-mini-dlna.ps1 [<CommonParameters>]
[<CommonParameters>]
This script supports the common parameters: Verbose, Debug, ErrorAction, ErrorVariable, WarningAction,
WarningVariable, OutBuffer, PipelineVariable, and OutVariable.
Example
PS> ./install-mini-dlna.ps1
Notes
Author: Markus Fleschutz | License: CC0
Related Links
https://github.com/fleschutz/PowerShell
Script Content
<#
.SYNOPSIS
Installs MiniDLNA
.DESCRIPTION
This PowerShell script installs the MiniDLNA server.
.EXAMPLE
PS> ./install-mini-dlna.ps1
.LINK
https://github.com/fleschutz/PowerShell
.NOTES
Author: Markus Fleschutz | License: CC0
#>
try {
$stopWatch = [system.diagnostics.stopwatch]::startNew()
if (-not($IsLinux)) { throw "Sorry, only Linux installation currently supported" }
"⏳ (1/4) Installing MiniDLNA from Snap Store..."
& sudo snap install minidlna-jdstrand
[int]$elapsed = $stopWatch.Elapsed.TotalSeconds
"✅ MiniDLNA installed in $($elapsed)s."
" Configuration: /var/snap/minidlna-jdstrand/current/minidlna.conf"
" Log file: /var/snap/minidlna-jdstrand/current/home/minidlna.log"
exit 0 # success
} catch {
"Sorry: $($Error[0])"
exit 1
}
(page generated by convert-ps2md.ps1 as of 01/23/2025 12:15:21)