aboutsummaryrefslogtreecommitdiff
path: root/ShiftOS-TheRevival/MainForms/TerminalInternalApps.vb
diff options
context:
space:
mode:
authorEverythingWindows <[email protected]>2022-11-14 12:11:31 +0700
committerEverythingWindows <[email protected]>2022-11-14 12:11:31 +0700
commitb37a6e60c9ffa266fc1fc9afc13cada7704100b0 (patch)
treed84b68938f5b983bf9f0e3d0557ec307a636b961 /ShiftOS-TheRevival/MainForms/TerminalInternalApps.vb
parent5fe61b8fe47c536ab6f1bf35200a9c253e7d9f2f (diff)
downloadshiftos-therevival-old-b37a6e60c9ffa266fc1fc9afc13cada7704100b0.tar.gz
shiftos-therevival-old-b37a6e60c9ffa266fc1fc9afc13cada7704100b0.tar.bz2
shiftos-therevival-old-b37a6e60c9ffa266fc1fc9afc13cada7704100b0.zip
moving more from Console to Terminal Internal/External Apps
Diffstat (limited to 'ShiftOS-TheRevival/MainForms/TerminalInternalApps.vb')
-rw-r--r--ShiftOS-TheRevival/MainForms/TerminalInternalApps.vb65
1 files changed, 64 insertions, 1 deletions
diff --git a/ShiftOS-TheRevival/MainForms/TerminalInternalApps.vb b/ShiftOS-TheRevival/MainForms/TerminalInternalApps.vb
index 944954b..8b544a0 100644
--- a/ShiftOS-TheRevival/MainForms/TerminalInternalApps.vb
+++ b/ShiftOS-TheRevival/MainForms/TerminalInternalApps.vb
@@ -83,6 +83,45 @@
End Select
End Sub
+ Public Sub DateTerm()
+ If Strings.AvailableFeature(24) = 1 Then
+ NewLine("The date is " & Date.Now.DayOfYear & " days since the first day of the year")
+ AdvancedCommand = False
+ Console.BadCommand = False
+ ElseIf Strings.AvailableFeature(24) = 3 Then
+ If Strings.AvailableFeature(25) = 1 Then
+ Dim TheWeek As String = Date.Now.DayOfYear / 7
+ NewLine("The date is " & TheWeek.Substring(0, 2) & " weeks since the first week of the year")
+ AdvancedCommand = False
+ Console.BadCommand = False
+ ElseIf Strings.AvailableFeature(25) = 3 Then
+ If Strings.AvailableFeature(26) = 1 Then
+ NewLine("The date is " & Date.Now.Month & " months since the first month of the year")
+ AdvancedCommand = False
+ Console.BadCommand = False
+ ElseIf Strings.AvailableFeature(26) = 3 Then
+ If Strings.AvailableFeature(27) = 1 Then
+ NewLine("The year is " & Date.Now.Year)
+ AdvancedCommand = False
+ Console.BadCommand = False
+ ElseIf Strings.AvailableFeature(27) = 3 Then
+ If Strings.AvailableFeature(28) = 1 Then
+ NewLine("The date is " & Date.Now.Day & "/" & Date.Now.Month)
+ AdvancedCommand = False
+ Console.BadCommand = False
+ ElseIf Strings.AvailableFeature(28) = 3 Then
+ If Strings.AvailableFeature(29) = 1 Then
+ NewLine("The date is " & Date.Now.Day & "/" & Date.Now.Month & "/" & Date.Now.Year)
+ AdvancedCommand = False
+ Console.BadCommand = False
+ End If
+ End If
+ End If
+ End If
+ End If
+ End If
+ End Sub
+
Public Sub Help()
NewLine("ShiftOS Help Manual")
NewLine(Nothing)
@@ -207,7 +246,7 @@
Dim mancommand As String = Command.Replace("man ", "")
Dim TempUsage As String = "'" & mancommand & "' Usage: "
Select Case mancommand
- 'In process to convert every command from printing from code to printing from text file
+ 'In process to convert every command from printing from code to printing from text file
Case "bc"
If Strings.AvailableFeature(9) = "1" Then
TempUsage = TempUsage & "bc"
@@ -381,4 +420,28 @@
NewLine(" .~?55Y?!^:... ")
NewLine(" .:~~^~^^::. ")
End Sub
+
+ Public Sub TimeTerm()
+ If Strings.AvailableFeature(5) = 1 Then
+ NewLine(Math.Floor(Date.Now.Subtract(Date.Today).TotalSeconds) & " seconds passed since midnight")
+ ElseIf Strings.AvailableFeature(5) = 3 Then
+ If Strings.AvailableFeature(6) = 1 Then
+ NewLine(Math.Floor(Date.Now.Subtract(Date.Today).TotalMinutes) & " minutes passed since midnight")
+ ElseIf Strings.AvailableFeature(6) = 3 Then
+ If Strings.AvailableFeature(7) = 1 Then
+ NewLine(Math.Floor(Date.Now.Subtract(Date.Today).TotalHours) & " hours passed since midnight")
+ ElseIf Strings.AvailableFeature(7) = 3 Then
+ If Strings.AvailableFeature(12) = 1 Then
+ If Date.Now.Hour < 12 Then
+ NewLine("The time is " & TimeOfDay.Hour & " AM")
+ Else
+ NewLine("The time is " & TimeOfDay.Hour - 12 & " PM")
+ End If
+ ElseIf Strings.AvailableFeature(23) = 1 Then
+ NewLine("The time is " & TimeOfDay.Hour & ":" & TimeOfDay.Minute)
+ End If
+ End If
+ End If
+ End If
+ End Sub
End Module