Skip to content

Commit 59acfa4

Browse files
committed
Little changes
1 parent b8d2521 commit 59acfa4

19 files changed

+79
-27
lines changed
Binary file not shown.
Binary file not shown.

FalconOS/.vs/FalconOS/FileContentIndex/read.lock

Whitespace-only changes.

FalconOS/.vs/FalconOS/v17/.suo

16 KB
Binary file not shown.

FalconOS/FalconOS/Shell.cs

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,10 @@ public void exec(string cmd)
107107
}
108108
else if (cmd.StartsWith("cd"))
109109
{
110+
if (cmd.StartsWith("cd ..."))
111+
{
112+
data.currentDir = "0:\\";
113+
}
110114
if (Directory.Exists(cmd.Replace("cd ", data.currentDir + "\\")))
111115
{
112116
data.currentDir += cmd.Replace("cd ", "") + "\\";
@@ -191,6 +195,39 @@ public void exec(string cmd)
191195
Console.WriteLine("ERROR: Invalid File. [Use: cat <file>]");
192196
}
193197
}
198+
} else if (cmd.StartsWith("ver"))
199+
{
200+
Console.ForegroundColor = ConsoleColor.DarkCyan;
201+
Console.Write(this.os + " ");
202+
Console.ResetColor();
203+
Console.WriteLine(this.ver);
204+
} else if (cmd.StartsWith("falcp"))
205+
{
206+
if (cmd.StartsWith("falcp "))
207+
{
208+
if (cmd.StartsWith("falcp --help") || cmd.StartsWith("falcp -h"))
209+
{
210+
Console.WriteLine("FalCompile [falcp] v0.5");
211+
Console.WriteLine("FalCompile is a FalVM compiler to compile .fal files to .fex [Falcon Executable]");
212+
Console.WriteLine("Uses:\n falcp <file> (to get a <file>.fex file that is compiled)\n falcp --help/-h (to get this prompt)");
213+
} else if (cmd.EndsWith(".fa"))
214+
{
215+
string[] program;
216+
if (File.Exists(cmd.Replace("falcp ", "")))
217+
{
218+
program = File.ReadAllLines(cmd.Replace("falcp ", data.currentDir));
219+
} else
220+
{
221+
log.programPrint("falcp", "ERROR: File doesn't exist.");
222+
}
223+
}
224+
}
225+
else
226+
{
227+
Console.WriteLine("FalCompile [falcp] v0.5");
228+
Console.WriteLine("FalCompile is a FalVM compiler to compile .fal files to .fex [Falcon Executable]");
229+
Console.WriteLine("Uses:\n falcp <file>.fa (to get a <file>.fex file that is compiled)\n falcp --help/-h (to get this prompt)");
230+
}
194231
}
195232
else
196233
{

FalconOS/FalconOS/log.cs

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,20 @@ public static void print(string topic, string message)
1313
{
1414
Console.ForegroundColor = ConsoleColor.Cyan;
1515
Console.Write("[ " + topic + " ] ");
16-
Console.ForegroundColor = ConsoleColor.White;
16+
Console.ResetColor();
1717
Console.WriteLine(message);
1818
return;
1919
}
2020

21+
public static void programPrint(string program, string message)
22+
{
23+
Console.ForegroundColor = ConsoleColor.Cyan;
24+
Console.Write(program);
25+
Console.ResetColor();
26+
Console.WriteLine(": " + message);
27+
return;
28+
}
29+
2130
public static void drawTitleBar(string title, ConsoleColor back = ConsoleColor.DarkCyan, ConsoleColor fore = ConsoleColor.Black)
2231
{
2332
Console.BackgroundColor = back; Console.ForegroundColor = fore;
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
// <autogenerated />
2+
using System;
3+
using System.Reflection;
4+
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v6.0", FrameworkDisplayName = ".NET 6.0")]

FalconOS/FalconOS/obj/Debug/net6.0/FalconOS.GeneratedMSBuildEditorConfig.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ build_property.PlatformNeutralAssembly =
88
build_property.EnforceExtendedAnalyzerRules =
99
build_property._SupportedPlatformList = Linux,macOS,Windows
1010
build_property.RootNamespace = FalconOS
11-
build_property.ProjectDir = C:\Users\praty\Downloads\FalconOS-main\FalconOS\FalconOS\
11+
build_property.ProjectDir = E:\Git Repos\FalconOS\FalconOS\FalconOS\
Binary file not shown.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
c68c09791d50eedf2c086f5ef4bca002e52c29e6
1+
8a8c32934682b6fcfa56928777e8d54e020ca670

0 commit comments

Comments
 (0)