From 559ef71d2fb2669a45758431cdc95c2e85973b1a Mon Sep 17 00:00:00 2001 From: Alexey Golub Date: Wed, 17 Apr 2019 00:59:22 +0300 Subject: [PATCH] Get rid of Chocolatey --- Deploy/Choco/discordchatexporter.nuspec | 25 ------------------------ Deploy/Choco/tools/chocolateyinstall.ps1 | 24 ----------------------- Deploy/Prepare.ps1 | 18 ++++++----------- Readme.md | 1 - UpdateVersion.ps1 | 4 +--- appveyor.yml | 15 ++------------ 6 files changed, 9 insertions(+), 78 deletions(-) delete mode 100644 Deploy/Choco/discordchatexporter.nuspec delete mode 100644 Deploy/Choco/tools/chocolateyinstall.ps1 diff --git a/Deploy/Choco/discordchatexporter.nuspec b/Deploy/Choco/discordchatexporter.nuspec deleted file mode 100644 index ec9deb5f..00000000 --- a/Deploy/Choco/discordchatexporter.nuspec +++ /dev/null @@ -1,25 +0,0 @@ - - - - discordchatexporter - DiscordChatExporter - 2.12.1 - Tyrrrz - Tyrrrz - Copyright (C) Alexey Golub - Exports Discord chat logs to a file - DiscordChatExporter can be used to export message history from a Discord channel to a file. It works for both direct message chats and guild chats, supports markdown, message grouping, and attachments. The tool also lets you select from/to dates to limit the exported messages. There are options to configure the output, such as date format, color theme, message grouping limit, etc. - discordchatexporter discord export chat logs archive gui - https://github.com/Tyrrrz/DiscordChatExporter - https://github.com/Tyrrrz/DiscordChatExporter - http://tyrrrz.me/Projects/DiscordChatExporter - https://github.com/Tyrrrz/DiscordChatExporter/blob/master/Changelog.md - https://raw.githubusercontent.com/Tyrrrz/DiscordChatExporter/master/favicon.png - https://raw.githubusercontent.com/Tyrrrz/DiscordChatExporter/master/License.txt - true - https://github.com/Tyrrrz/DiscordChatExporter/issues - - - - - \ No newline at end of file diff --git a/Deploy/Choco/tools/chocolateyinstall.ps1 b/Deploy/Choco/tools/chocolateyinstall.ps1 deleted file mode 100644 index aa17f02b..00000000 --- a/Deploy/Choco/tools/chocolateyinstall.ps1 +++ /dev/null @@ -1,24 +0,0 @@ -$ErrorActionPreference = 'Stop' -$packageName = $env:ChocolateyPackageName -$installDirPath = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)" - -# Install package (GUI) - -$packageArgs = @{ - packageName = $packageName - unzipLocation = $installDirPath - url = 'https://github.com/Tyrrrz/DiscordChatExporter/releases/download/2.12.1/DiscordChatExporter.zip' -} -Install-ChocolateyZipPackage @packageArgs - -# Mark the executable as GUI -New-Item (Join-Path $installDirPath "DiscordChatExporter.exe.gui") -ItemType File -Force - -# Install package (CLI) - -$packageArgs = @{ - packageName = $packageName - unzipLocation = $installDirPath - url = 'https://github.com/Tyrrrz/DiscordChatExporter/releases/download/2.12.1/DiscordChatExporter.CLI.zip' -} -Install-ChocolateyZipPackage @packageArgs \ No newline at end of file diff --git a/Deploy/Prepare.ps1 b/Deploy/Prepare.ps1 index 313a2cdb..4f694bf3 100644 --- a/Deploy/Prepare.ps1 +++ b/Deploy/Prepare.ps1 @@ -1,4 +1,6 @@ -# --- PORTABLE / GUI --- +New-Item "$PSScriptRoot\Portable\bin" -ItemType Directory -Force + +# --- GUI --- # Get files $files = @() @@ -6,10 +8,9 @@ $files += Get-Item -Path "$PSScriptRoot\..\License.txt" $files += Get-ChildItem -Path "$PSScriptRoot\..\DiscordChatExporter.Gui\bin\Release\*" -Include "*.exe", "*.dll", "*.config" # Pack into archive -New-Item "$PSScriptRoot\Portable\GUI\bin" -ItemType Directory -Force -$files | Compress-Archive -DestinationPath "$PSScriptRoot\Portable\GUI\bin\DiscordChatExporter.zip" -Force +$files | Compress-Archive -DestinationPath "$PSScriptRoot\Portable\bin\DiscordChatExporter.zip" -Force -# --- PORTABLE / CLI --- +# --- CLI --- # Get files $files = @() @@ -17,11 +18,4 @@ $files += Get-Item -Path "$PSScriptRoot\..\License.txt" $files += Get-ChildItem -Path "$PSScriptRoot\..\DiscordChatExporter.Cli\bin\Release\net46\*" -Include "*.exe", "*.dll", "*.config" # Pack into archive -New-Item "$PSScriptRoot\Portable\CLI\bin" -ItemType Directory -Force -$files | Compress-Archive -DestinationPath "$PSScriptRoot\Portable\CLI\bin\DiscordChatExporter.CLI.zip" -Force - -# --- CHOCOLATEY --- - -# Create package -New-Item "$PSScriptRoot\Choco\bin\" -ItemType Directory -Force -choco pack $PSScriptRoot\Choco\discordchatexporter.nuspec --out $PSScriptRoot\Choco\bin\ \ No newline at end of file +$files | Compress-Archive -DestinationPath "$PSScriptRoot\Portable\bin\DiscordChatExporter.CLI.zip" -Force \ No newline at end of file diff --git a/Readme.md b/Readme.md index 63b84222..ddb86528 100644 --- a/Readme.md +++ b/Readme.md @@ -11,7 +11,6 @@ DiscordChatExporter can be used to export message history from a [Discord](https ## Download - [Stable releases](https://github.com/Tyrrrz/DiscordChatExporter/releases) -- [Chocolatey](https://chocolatey.org/packages/DiscordChatExporter): `choco install discordchatexporter` - [Docker](https://hub.docker.com/r/tyrrrz/discordchatexporter): `docker pull tyrrrz/discordchatexporter` - [Continuous integration](https://ci.appveyor.com/project/Tyrrrz/DiscordChatExporter) diff --git a/UpdateVersion.ps1 b/UpdateVersion.ps1 index 1b545ff0..7f755442 100644 --- a/UpdateVersion.ps1 +++ b/UpdateVersion.ps1 @@ -9,6 +9,4 @@ function Replace-TextInFile { } Replace-TextInFile "$PSScriptRoot\DiscordChatExporter.Cli\DiscordChatExporter.Cli.csproj" '(?<=)(.*?)(?=)' $newVersion -Replace-TextInFile "$PSScriptRoot\DiscordChatExporter.Gui\Properties\AssemblyInfo.cs" '(?<=Assembly.*?Version\(")(.*?)(?="\)\])' $newVersion -Replace-TextInFile "$PSScriptRoot\Deploy\Choco\discordchatexporter.nuspec" '(?<=)(.*?)(?=)' $newVersion -Replace-TextInFile "$PSScriptRoot\Deploy\Choco\tools\chocolateyinstall.ps1" '(?<=download/)(.*?)(?=/)' $newVersion \ No newline at end of file +Replace-TextInFile "$PSScriptRoot\DiscordChatExporter.Gui\Properties\AssemblyInfo.cs" '(?<=Assembly.*?Version\(")(.*?)(?="\)\])' $newVersion \ No newline at end of file diff --git a/appveyor.yml b/appveyor.yml index d58bcee4..a9caedf2 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -13,12 +13,10 @@ after_build: - ps: Deploy\Prepare.ps1 artifacts: -- path: Deploy\Portable\GUI\bin\DiscordChatExporter.zip +- path: Deploy\Portable\bin\DiscordChatExporter.zip name: DiscordChatExporter.zip -- path: Deploy\Portable\CLI\bin\DiscordChatExporter.CLI.zip +- path: Deploy\Portable\bin\DiscordChatExporter.CLI.zip name: DiscordChatExporter.CLI.zip -- path: Deploy\Choco\bin\DiscordChatExporter*.nupkg - name: DiscordChatExporter-Choco.nupkg deploy: - provider: GitHub @@ -26,15 +24,6 @@ deploy: secure: sjQHWRw29AMiVMn3MtidtWnAzAf1mJ+mkJ/7h1B9TIAHhkFrqwMK7LtXV+uNJ9AO artifact: DiscordChatExporter.zip,DiscordChatExporter.CLI.zip description: '[Changelog](https://github.com/Tyrrrz/DiscordChatExporter/blob/master/Changelog.md)' - on: - branch: master - appveyor_repo_tag: true -- provider: NuGet - server: https://push.chocolatey.org/ - api_key: - secure: aQVQ50i8GcwxMXTHf2ck5PijnOeVZY8Z9MEROQTvT49/7/az9w8ru8NCyEsV6H5I - artifact: DiscordChatExporter-Choco.nupkg - skip_symbols: true on: branch: master appveyor_repo_tag: true \ No newline at end of file