ffmpeg won't log anymore
This commit is contained in:
parent
c08498af54
commit
aa86359ea0
@ -172,12 +172,9 @@ namespace NadekoBot.Classes.Music {
|
||||
//start feeding the buffer
|
||||
var p = Process.Start(new ProcessStartInfo {
|
||||
FileName = "ffmpeg",
|
||||
Arguments = $"-i {Url} -f s16le -ar 48000 -ac 2 pipe:1",
|
||||
Arguments = $"-i {Url} -f s16le -ar 48000 -ac 2 pipe:1 -loglevel quiet", //+ (NadekoBot.IsLinux ? "2> /dev/null" : "2>NUL"),
|
||||
UseShellExecute = false,
|
||||
RedirectStandardOutput = true,
|
||||
RedirectStandardError = false,
|
||||
CreateNoWindow = true,
|
||||
WindowStyle = ProcessWindowStyle.Hidden,
|
||||
});
|
||||
int attempt = 0;
|
||||
while (true) {
|
||||
|
@ -30,13 +30,15 @@ namespace NadekoBot {
|
||||
botMention = creds.BotMention;
|
||||
if (string.IsNullOrWhiteSpace(creds.GoogleAPIKey)) {
|
||||
Console.WriteLine("No google api key found. You will not be able to use music and links won't be shortened.");
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
Console.WriteLine("Google API key provided.");
|
||||
GoogleAPIKey = creds.GoogleAPIKey;
|
||||
}
|
||||
if (string.IsNullOrWhiteSpace(creds.TrelloAppKey)) {
|
||||
Console.WriteLine("No trello appkey found. You will not be able to use trello commands.");
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
Console.WriteLine("Trello app key provided.");
|
||||
TrelloAppKey = creds.TrelloAppKey;
|
||||
loadTrello = true;
|
||||
@ -54,7 +56,8 @@ namespace NadekoBot {
|
||||
|
||||
OwnerID = creds.OwnerID;
|
||||
password = creds.Password;
|
||||
} catch (Exception ex) {
|
||||
}
|
||||
catch (Exception ex) {
|
||||
Console.WriteLine($"Failed to load stuff from credentials.json, RTFM\n{ex.Message}");
|
||||
Console.ReadKey();
|
||||
return;
|
||||
@ -70,7 +73,7 @@ namespace NadekoBot {
|
||||
var commandService = new CommandService(new CommandServiceConfigBuilder {
|
||||
AllowMentionPrefix = false,
|
||||
CustomPrefixHandler = m => 0,
|
||||
HelpMode = HelpMode.Disabled
|
||||
HelpMode = HelpMode.Disabled,
|
||||
});
|
||||
|
||||
//reply to personal messages and forward if enabled.
|
||||
@ -121,14 +124,14 @@ namespace NadekoBot {
|
||||
|
||||
try {
|
||||
OwnerPrivateChannel = await client.CreatePrivateChannel(OwnerID);
|
||||
} catch {
|
||||
}
|
||||
catch {
|
||||
Console.WriteLine("Failed creating private channel with the owner");
|
||||
}
|
||||
|
||||
Classes.Permissions.PermissionsHandler.Initialize();
|
||||
|
||||
client.ClientAPI.SendingRequest += (s, e) =>
|
||||
{
|
||||
client.ClientAPI.SendingRequest += (s, e) => {
|
||||
var request = e.Request as Discord.API.Client.Rest.SendMessageRequest;
|
||||
if (request != null) {
|
||||
if (string.IsNullOrWhiteSpace(request.Content))
|
||||
@ -157,7 +160,8 @@ namespace NadekoBot {
|
||||
await (await client.GetInvite(e.Message.Text)).Accept();
|
||||
await e.Send("I got in!");
|
||||
return;
|
||||
} catch {
|
||||
}
|
||||
catch {
|
||||
if (e.User.Id == 109338686889476096) { //carbonitex invite
|
||||
await e.Send("Failed to join the server.");
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user