From dca991d1a3092cd266e4501a6462d792b9bbdeae Mon Sep 17 00:00:00 2001
From: Niko Ehrenfeuchter <nikolaus.ehrenfeuchter@unibas.ch>
Date: Mon, 4 Dec 2017 16:06:24 +0100
Subject: [PATCH] Introduce global variable $Me, referring to script name.

Providing the file name without suffix.

Refers to #13
---
 AutoTx/Resources/Update-AutoTxService.ps1 | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/AutoTx/Resources/Update-AutoTxService.ps1 b/AutoTx/Resources/Update-AutoTxService.ps1
index 933cd80..a4a00a3 100644
--- a/AutoTx/Resources/Update-AutoTxService.ps1
+++ b/AutoTx/Resources/Update-AutoTxService.ps1
@@ -16,6 +16,8 @@ catch {
     Exit
 }
 
+$Me = $MyInvocation.MyCommand -replace '.ps1'
+
 
 
 function Check-ServiceState([string]$ServiceName) {
-- 
GitLab