From 634ddb4622dccf96d649d3adc887cb7ef3aa87c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=95=D0=B2=D0=B3=D0=B5=D0=BD=D0=B8=D0=B9=20=D0=9C=D0=BE?= =?UTF-8?q?=D0=B6=D0=B5=D0=B2=D0=B8=D1=82=D0=B8=D0=BD?= Date: Wed, 8 Feb 2023 17:32:24 +0300 Subject: [PATCH] install tools --- install.cmd | 1 + tools/add_odbc_connection.ps1 | 3 +++ tools/remove_odbc_connection.ps1 | 1 + uninstall.cmd | 1 + 4 files changed, 6 insertions(+) create mode 100644 install.cmd create mode 100644 tools/add_odbc_connection.ps1 create mode 100644 tools/remove_odbc_connection.ps1 create mode 100644 uninstall.cmd diff --git a/install.cmd b/install.cmd new file mode 100644 index 0000000..a964d53 --- /dev/null +++ b/install.cmd @@ -0,0 +1 @@ +powershell .\tools\add_odbc_connection.ps1 \ No newline at end of file diff --git a/tools/add_odbc_connection.ps1 b/tools/add_odbc_connection.ps1 new file mode 100644 index 0000000..29095b3 --- /dev/null +++ b/tools/add_odbc_connection.ps1 @@ -0,0 +1,3 @@ +$targetdir="DefaultDir="+(Split-Path (Get-Location))+"\components" +Write-Host 'Installing GhOST Library to' $targetdir +Add-OdbcDsn -Name "GhOST Library" -DriverName "Microsoft Access Text Driver (*.txt, *.csv)" -DsnType "User" -Platform "64-bit" -SetPropertyValue $targetdir \ No newline at end of file diff --git a/tools/remove_odbc_connection.ps1 b/tools/remove_odbc_connection.ps1 new file mode 100644 index 0000000..f61ffc8 --- /dev/null +++ b/tools/remove_odbc_connection.ps1 @@ -0,0 +1 @@ +Remove-OdbcDsn -Name "GhOST Library" -DsnType "User" -Platform "64-bit" -ErrorAction 'SilentlyContinue' \ No newline at end of file diff --git a/uninstall.cmd b/uninstall.cmd new file mode 100644 index 0000000..776d4f6 --- /dev/null +++ b/uninstall.cmd @@ -0,0 +1 @@ +powershell ./tools/remove_odbc_connection.ps1 \ No newline at end of file