Skip to content

Process and System Controls

egyptron edited this page Sep 24, 2026 · 1 revision

Process & System Controls

Awake Simple S1 provides native Windows system controls to check active processes, manage tasks, launch shell prompts, and run background routines.


1. Checking If a Process Is Running

Queries the active Windows process table and assigns true or false to the target variable:

check if process "<executable_name.exe>" is running into variable <target_variable>

Example:

check if process "discord.exe" is running into variable discord_active

statement(start)
if variable discord_active == true then
   display_success("Discord is running.")
else
   display_warn("Discord is closed.")
statement(end)

2. Terminating a Process

Finds all running instances of a specified executable name and terminates them:

stop process "<executable_name.exe>"

Example:

display_warn("Closing unnecessary background applications...")
stop process "notepad.exe"

3. Running Silent Background Commands

Executes shell commands silently without opening a terminal window (CREATE_NO_WINDOW and SW_HIDE):

run command "<shell_command>" in background

Example:

run command "mkdir S1_Saves" in background
run command "del /q old_cache.tmp" in background

4. Spawning an Interactive Command Prompt Window

Opens a new visible cmd.exe window, runs your command, and leaves the prompt open for user interaction:

run in terminal "<command>"

Example:

run in terminal "echo Welcome to Awake S1 Terminal Session! && dir /w"

5. Starting Processes & Executables

Launch external programs asynchronously without blocking the execution of your script:

note: Starts in a new visible window
start process "<path_or_exe>"

note: Starts completely hidden
start process "<path_or_exe>" in background

Example:

start process "notepad.exe"
start process "cmd.exe /c ping 127.0.0.1" in background

6. Opening Files with Default System Handlers

Opens any document, image, audio file, or URL using the user's default associated application:

open file "<path_or_url>"

Example:

open file "manual.pdf"
open file "screenshot.png"
open file "https://github.com/Awake-Platforms/awss1"

Clone this wiki locally