Skip to content

Commit ce22e0c

Browse files
authored
Fixed the No Spaces Rule for the Converter
1 parent cc366e9 commit ce22e0c

File tree

3 files changed

+79
-11
lines changed

3 files changed

+79
-11
lines changed

SoundBlox/Backend.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ public static class vars
1515
public static string RobloxSoundDir;
1616
public static string MOTD_DIR = CurrentPath + @"\.motd";
1717
public static string MOTD;
18-
public static int CurrentVersion = 3;
18+
public static int CurrentVersion = 4;
1919

2020
}
2121
public static class OINT

SoundBlox/MainForm.cs

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -52,23 +52,24 @@ private void MainForm_Load(object sender, EventArgs e)
5252
RobloxSoundDir = wc.DownloadString(@"https://raw.githubusercontent.com/Awire9966/SoundBlox/main/roblox").Replace("{APPDATA}", Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData)).Replace("{LOCALAPPDATA}", Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData));
5353
int LatestVers = int.Parse(wc.DownloadString("https://raw.githubusercontent.com/Awire9966/SoundBlox/main/version"));
5454
vars.MOTD = wc.DownloadString("https://raw.githubusercontent.com/Awire9966/SoundBlox/main/message");
55-
if(LatestVers > vars.CurrentVersion)
56-
{
57-
var res = MessageBox.Show("New Update! Download?","Update!", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
58-
if(res == DialogResult.Yes)
59-
{
60-
Process.Start("https://github.com/Awire9966/SoundBlox");
61-
}
62-
}
63-
if(!File.Exists(vars.MOTD_DIR))
55+
if (!File.Exists(vars.MOTD_DIR))
6456
{
6557
File.WriteAllText(vars.MOTD_DIR, "");
6658
}
67-
if(!(vars.MOTD == File.ReadAllText(vars.MOTD_DIR)))
59+
if (!(vars.MOTD == File.ReadAllText(vars.MOTD_DIR)))
6860
{
6961
MessageBox.Show(vars.MOTD, "Message");
7062
File.WriteAllText(vars.MOTD_DIR, vars.MOTD);
7163
}
64+
if (LatestVers > vars.CurrentVersion)
65+
{
66+
var res = MessageBox.Show("New Update! Download?","Update!", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
67+
if(res == DialogResult.Yes)
68+
{
69+
Process.Start("https://github.com/Awire9966/SoundBlox");
70+
}
71+
}
72+
7273
vars.RobloxSoundDir = RobloxSoundDir;
7374
BUILTINSOUNDS.Url = new Uri(vars.SoundBloxDir_Sounds);
7475
FEXSOUNDS.Url = new Uri(RobloxSoundDir);

SoundBlox/README.md

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,68 @@
1+
# Instances
2+
A .NET Standard `Process` wrapper with an elegant API, for both asyncronous and syncronous use, providing both Events and support for Tasks with cancellation support
3+
4+
![.NET Core](https://github.com/rosenbjerg/Instances/workflows/CI/badge.svg)
5+
[![codecov.io](https://codecov.io/github/rosenbjerg/agentdeploy/coverage.svg?branch=main)](https://app.codecov.io/gh/rosenbjerg/Instances)
6+
[![GitHub](https://img.shields.io/github/license/rosenbjerg/Instances)](https://github.com/rosenbjerg/Instances/blob/master/LICENSE)
7+
[![Nuget](https://img.shields.io/nuget/v/instances)](https://www.nuget.org/packages/instances/)
8+
[![Nuget](https://img.shields.io/nuget/dt/instances)](https://www.nuget.org/packages/instances/)
9+
![Dependent repos (via libraries.io)](https://img.shields.io/librariesio/dependent-repos/nuget/instances)
110

11+
12+
# Usage
13+
There are three ways to use this library, requiring at least 1, 2, or 3 lines of code to use.
14+
15+
### Shortest form, supporting only few options
16+
```c#
17+
var result = await Instance.FinishAsync("dotnet", "build -c Release", cancellationToken);
18+
Console.WriteLine(result.ExitCode);
19+
// or
20+
var result = Instance.Finish("dotnet", "build -c Release");
21+
```
22+
23+
### Short form, supporting more options
24+
```c#
25+
using var instance = Instance.Start("dotnet", "build -c Release");
26+
var result = await instance.WaitForExitAsync(cancellationToken);
27+
// or
28+
using var instance = Instance.Start("dotnet", "build -c Release");
29+
var result = instance.WaitForExit();
30+
```
31+
32+
### Full form, supporting all options
33+
```c#
34+
var processArgument = new ProcessArguments("dotnet", "build -c Release");
35+
processArgument.Exited += (_, exitResult) => Console.WriteLine(exitResult.ExitCode);
36+
processArgument.OutputDataReceived += (_, data) => Console.WriteLine(data);
37+
processArgument.ErrorDataReceived += (_, data) => Console.WriteLine(data);
38+
39+
using var instance = processArgument.Start();
40+
41+
var result = await instance.WaitForExitAsync(cancellationToken);
42+
// or
43+
var result = instance.WaitForExit();
44+
```
45+
46+
47+
## Features
48+
```c#
49+
using var instance = Instance.Start("dotnet", "build -c Release");
50+
51+
// send input to process' standard input
52+
instance.SendInput("Hello World");
53+
54+
// stop the process
55+
instance.Kill();
56+
57+
// access process output
58+
foreach (var line in instance.OutputData)
59+
Console.WriteLine(line);
60+
// and error data easily while the process is running
61+
foreach (var line in instance.ErrorData)
62+
Console.WriteLine(line);
63+
64+
// or wait for the process to exit (with support for cancellation token)
65+
var result = await instance.WaitForExitAsync(cancellationToken);
66+
Console.WriteLine(result.ExitCode);
67+
Console.WriteLine(result.OutputData.Count);
68+
```

0 commit comments

Comments
 (0)