More work on the installer, cleanup, back to MIT because i read unlicensed is illegal in some countries 🤦
This commit is contained in:
parent
ff07777a38
commit
747a834e60
39
NadekoBot.iss
Normal file
39
NadekoBot.iss
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
#define sysfolder "system"
|
||||||
|
#define version "1.41"
|
||||||
|
#define target "win7-x64"
|
||||||
|
|
||||||
|
[Setup]
|
||||||
|
AppName=NadekoBot
|
||||||
|
AppVersion={#version}
|
||||||
|
AppPublisher=Kwoth
|
||||||
|
DefaultDirName={pf}\NadekoBot
|
||||||
|
DefaultGroupName=NadekoBot
|
||||||
|
UninstallDisplayIcon={app}\{#sysfolder}\NadekoBot.exe
|
||||||
|
Compression=lzma2
|
||||||
|
SolidCompression=yes
|
||||||
|
OutputDir=userdocs:projekti/NadekoInstallerOutput
|
||||||
|
OutputBaseFilename=NadekoBot-setup-{#version}
|
||||||
|
AppReadmeFile=http://nadekobot.readthedocs.io/en/latest/Commands%20List/
|
||||||
|
|
||||||
|
[Files]
|
||||||
|
;install
|
||||||
|
Source: "src\NadekoBot\bin\Release\PublishOutput\{#target}\*"; DestDir: "{app}\{#sysfolder}"; Permissions: users-modify; Flags: recursesubdirs onlyifdoesntexist ignoreversion createallsubdirs; Excludes: "*.pdb, *.db"
|
||||||
|
|
||||||
|
;reinstall - i want to copy all files, but i don't want to overwrite any data files because users will lose their customization if they don't have a backup,
|
||||||
|
; and i don't want them to have to backup and then copy-merge into data folder themselves, or lose their currency images due to overwrite.
|
||||||
|
Source: "src\NadekoBot\bin\Release\PublishOutput\{#target}\*"; DestDir: "{app}\{#sysfolder}"; Permissions: users-modify; Flags: recursesubdirs onlyifdestfileexists createallsubdirs; Excludes: "*.pdb, *.db, data\*, credentials.json";
|
||||||
|
Source: "src\NadekoBot\bin\Release\PublishOutput\{#target}\data\*"; DestDir: "{app}\{#sysfolder}\data"; Permissions: users-modify; Flags: recursesubdirs onlyifdoesntexist createallsubdirs;
|
||||||
|
|
||||||
|
;readme
|
||||||
|
;Source: "readme"; DestDir: "{app}"; Flags: isreadme
|
||||||
|
|
||||||
|
[Run]
|
||||||
|
Filename: "http://nadekobot.readthedocs.io/en/latest/Commands%20List/"; Flags: postinstall checked shellexec runasoriginaluser; Description: "Open Command List"
|
||||||
|
|
||||||
|
[Icons]
|
||||||
|
; for pretty install directory
|
||||||
|
Name: "{app}\NadekoBot"; Filename: "{app}\{#sysfolder}\NadekoBot.exe"; IconFilename: "{app}\{#sysfolder}\nadeko_icon.ico"
|
||||||
|
Name: "{app}\credentials"; Filename: "{app}\{#sysfolder}\credentials.json"
|
||||||
|
Name: "{app}\data"; Filename: "{app}\{#sysfolder}\data"
|
||||||
|
; desktop shortcut
|
||||||
|
Name: "{commondesktop}\NadekoBot"; Filename: "{app}\NadekoBot";
|
23
license.md
23
license.md
@ -1,24 +1,9 @@
|
|||||||
This is free and unencumbered software released into the public domain.
|
Copyright 2017 Kwoth
|
||||||
|
|
||||||
Anyone is free to copy, modify, publish, use, compile, sell, or
|
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||||
distribute this software, either in source code form or as a compiled
|
|
||||||
binary, for any purpose, commercial or non-commercial, and by any
|
|
||||||
means.
|
|
||||||
|
|
||||||
In jurisdictions that recognize copyright laws, the author or authors
|
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||||
of this software dedicate any and all copyright interest in the
|
|
||||||
software to the public domain. We make this dedication for the benefit
|
|
||||||
of the public at large and to the detriment of our heirs and
|
|
||||||
successors. We intend this dedication to be an overt act of
|
|
||||||
relinquishment in perpetuity of all present and future rights to this
|
|
||||||
software under copyright law.
|
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
||||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
|
||||||
IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
|
|
||||||
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
|
|
||||||
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
||||||
OTHER DEALINGS IN THE SOFTWARE.
|
|
||||||
|
|
||||||
For more information, please refer to <http://unlicense.org/>
|
For more information, please refer to <http://unlicense.org/>
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
using Discord;
|
using Discord;
|
||||||
using Discord.WebSocket;
|
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace NadekoBot.DataStructures.ModuleBehaviors
|
namespace NadekoBot.DataStructures.ModuleBehaviors
|
||||||
|
@ -1,6 +1,4 @@
|
|||||||
using System;
|
using Microsoft.EntityFrameworkCore.Migrations;
|
||||||
using System.Collections.Generic;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
|
|
||||||
namespace NadekoBot.Migrations
|
namespace NadekoBot.Migrations
|
||||||
{
|
{
|
||||||
|
@ -2,9 +2,7 @@
|
|||||||
using Microsoft.EntityFrameworkCore;
|
using Microsoft.EntityFrameworkCore;
|
||||||
using Microsoft.EntityFrameworkCore.Infrastructure;
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
||||||
using Microsoft.EntityFrameworkCore.Metadata;
|
using Microsoft.EntityFrameworkCore.Metadata;
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using NadekoBot.Services.Database;
|
using NadekoBot.Services.Database;
|
||||||
using NadekoBot.Services.Database.Models;
|
|
||||||
|
|
||||||
namespace NadekoBot.Migrations
|
namespace NadekoBot.Migrations
|
||||||
{
|
{
|
||||||
|
@ -1,8 +1,6 @@
|
|||||||
using Discord;
|
using Discord;
|
||||||
using Discord.Commands;
|
using Discord.Commands;
|
||||||
using NadekoBot.Attributes;
|
using NadekoBot.Attributes;
|
||||||
using NadekoBot.Services;
|
|
||||||
using NadekoBot.Services.Administration;
|
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace NadekoBot.Modules.Administration
|
namespace NadekoBot.Modules.Administration
|
||||||
|
@ -1,16 +1,4 @@
|
|||||||
using System.Collections.Concurrent;
|
namespace NadekoBot.Modules.Gambling
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Collections.Immutable;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using Discord.Commands;
|
|
||||||
using Discord;
|
|
||||||
using NadekoBot.Attributes;
|
|
||||||
using NadekoBot.Extensions;
|
|
||||||
using NadekoBot.Services;
|
|
||||||
|
|
||||||
namespace NadekoBot.Modules.Gambling
|
|
||||||
{
|
{
|
||||||
//public partial class Gambling
|
//public partial class Gambling
|
||||||
//{
|
//{
|
||||||
|
@ -2,7 +2,6 @@
|
|||||||
using Discord.Commands;
|
using Discord.Commands;
|
||||||
using NadekoBot.Extensions;
|
using NadekoBot.Extensions;
|
||||||
using NadekoBot.Services;
|
using NadekoBot.Services;
|
||||||
using NadekoBot.Services.Administration;
|
|
||||||
using NLog;
|
using NLog;
|
||||||
using System.Globalization;
|
using System.Globalization;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
@ -25,7 +25,6 @@ using NadekoBot.Services.Administration;
|
|||||||
using NadekoBot.Services.Permissions;
|
using NadekoBot.Services.Permissions;
|
||||||
using NadekoBot.Services.Utility;
|
using NadekoBot.Services.Utility;
|
||||||
using NadekoBot.Services.Help;
|
using NadekoBot.Services.Help;
|
||||||
using NadekoBot.Extensions;
|
|
||||||
|
|
||||||
namespace NadekoBot
|
namespace NadekoBot
|
||||||
{
|
{
|
||||||
@ -222,6 +221,7 @@ namespace NadekoBot
|
|||||||
|
|
||||||
private async Task LoginAsync(string token)
|
private async Task LoginAsync(string token)
|
||||||
{
|
{
|
||||||
|
_log.Info("Logging in...");
|
||||||
//connect
|
//connect
|
||||||
await Client.LoginAsync(TokenType.Bot, token).ConfigureAwait(false);
|
await Client.LoginAsync(TokenType.Bot, token).ConfigureAwait(false);
|
||||||
await Client.StartAsync().ConfigureAwait(false);
|
await Client.StartAsync().ConfigureAwait(false);
|
||||||
@ -231,6 +231,7 @@ namespace NadekoBot
|
|||||||
foreach (var s in Client.Shards)
|
foreach (var s in Client.Shards)
|
||||||
s.Ready += () => Task.FromResult(Interlocked.Increment(ref readyCount));
|
s.Ready += () => Task.FromResult(Interlocked.Increment(ref readyCount));
|
||||||
|
|
||||||
|
_log.Info("Waiting for all shards to connect...");
|
||||||
while (readyCount < Client.Shards.Count)
|
while (readyCount < Client.Shards.Count)
|
||||||
await Task.Delay(100).ConfigureAwait(false);
|
await Task.Delay(100).ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
@ -243,6 +244,7 @@ namespace NadekoBot
|
|||||||
|
|
||||||
await LoginAsync(Credentials.Token).ConfigureAwait(false);
|
await LoginAsync(Credentials.Token).ConfigureAwait(false);
|
||||||
|
|
||||||
|
_log.Info("Loading serveices...");
|
||||||
AddServices();
|
AddServices();
|
||||||
|
|
||||||
sw.Stop();
|
sw.Stop();
|
||||||
|
@ -19,7 +19,7 @@
|
|||||||
<AssemblyVersion>1.0.0.0</AssemblyVersion>
|
<AssemblyVersion>1.0.0.0</AssemblyVersion>
|
||||||
<FileVersion>1.0.0.0</FileVersion>
|
<FileVersion>1.0.0.0</FileVersion>
|
||||||
<ApplicationIcon>nadeko_icon.ico</ApplicationIcon>
|
<ApplicationIcon>nadeko_icon.ico</ApplicationIcon>
|
||||||
<RuntimeIdentifiers>win7-x64;ubuntu.14.04-x64;osx.10.10-x64</RuntimeIdentifiers>
|
<RuntimeIdentifiers>win7-x64<!--;ubuntu.14.04-x64;osx.10.10-x64 --></RuntimeIdentifiers>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup Condition=" '$(Version)' == '' ">
|
<PropertyGroup Condition=" '$(Version)' == '' ">
|
||||||
@ -28,6 +28,10 @@
|
|||||||
<Version Condition=" '$(Version)' == '' ">$(VersionPrefix)</Version>
|
<Version Condition=" '$(Version)' == '' ">$(VersionPrefix)</Version>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<PropertyGroup>
|
||||||
|
<PostBuildEvent>copy credentials_example.json credentials.json </PostBuildEvent>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Compile Remove="data\**\*;credentials.json" />
|
<Compile Remove="data\**\*;credentials.json" />
|
||||||
<None Update="credentials_example.json">
|
<None Update="credentials_example.json">
|
||||||
|
@ -1,28 +0,0 @@
|
|||||||
; -- Example1.iss --
|
|
||||||
; Demonstrates copying 3 files and creating an icon.
|
|
||||||
|
|
||||||
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING .ISS SCRIPT FILES!
|
|
||||||
#define sysfolder "system"
|
|
||||||
|
|
||||||
|
|
||||||
[Setup]
|
|
||||||
AppName=NadekoBot
|
|
||||||
AppVersion=1.41
|
|
||||||
DefaultDirName={pf}\NadekoBot
|
|
||||||
DefaultGroupName=NadekoBot
|
|
||||||
UninstallDisplayIcon={app}\NadekoBot.exe
|
|
||||||
Compression=lzma2
|
|
||||||
SolidCompression=yes
|
|
||||||
OutputDir=userdocs:Inno Setup Examples Output
|
|
||||||
|
|
||||||
[Files]
|
|
||||||
Source: "bin\Release\PublishOutput\win7-x64\*"; DestDir: "{app}\system"; Flags: recursesubdirs
|
|
||||||
Source: "..\..\docs\Readme.md"; DestDir: "{app}"; Flags: isreadme
|
|
||||||
|
|
||||||
[Icons]
|
|
||||||
; for pretty install directory
|
|
||||||
Name: "{app}\NadekoBot"; Filename: "{app}\{#sysfolder}\NadekoBot.exe"; IconFilename: "{app}\{#sysfolder}\nadeko_icon.ico"
|
|
||||||
Name: "{app}\credentials"; Filename: "{app}\{#sysfolder}\credentials.json"
|
|
||||||
Name: "{app}\data"; Filename: "{app}\{#sysfolder}\data"
|
|
||||||
; desktop shortcut
|
|
||||||
Name: "{commondesktop}\NadekoBot"; Filename: "{app}\NadekoBot";
|
|
@ -13,7 +13,6 @@ using NadekoBot.DataStructures;
|
|||||||
using System.Collections.Immutable;
|
using System.Collections.Immutable;
|
||||||
using NadekoBot.DataStructures.ModuleBehaviors;
|
using NadekoBot.DataStructures.ModuleBehaviors;
|
||||||
using NadekoBot.Services.Database.Models;
|
using NadekoBot.Services.Database.Models;
|
||||||
using NadekoBot.Services;
|
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using Discord.Net;
|
using Discord.Net;
|
||||||
|
|
||||||
|
@ -3,7 +3,6 @@ using NadekoBot.Services.Database.Models;
|
|||||||
using System.Collections.Concurrent;
|
using System.Collections.Concurrent;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using Discord;
|
using Discord;
|
||||||
using Discord.WebSocket;
|
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace NadekoBot.Services.Permissions
|
namespace NadekoBot.Services.Permissions
|
||||||
|
@ -4,7 +4,6 @@ using System.Collections.Concurrent;
|
|||||||
using System.Linq;
|
using System.Linq;
|
||||||
using Discord;
|
using Discord;
|
||||||
using Discord.WebSocket;
|
using Discord.WebSocket;
|
||||||
using System;
|
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace NadekoBot.Services.Permissions
|
namespace NadekoBot.Services.Permissions
|
||||||
|
@ -1,10 +1,8 @@
|
|||||||
using NadekoBot.DataStructures.ModuleBehaviors;
|
using NadekoBot.DataStructures.ModuleBehaviors;
|
||||||
using NadekoBot.Services.Database.Models;
|
using NadekoBot.Services.Database.Models;
|
||||||
using System;
|
|
||||||
using System.Collections.Concurrent;
|
using System.Collections.Concurrent;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using Discord;
|
using Discord;
|
||||||
using NLog;
|
using NLog;
|
||||||
|
@ -1,8 +1,6 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace NadekoBot.Extensions
|
namespace NadekoBot.Extensions
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user