Skip to content

Latest commit

 

History

History
178 lines (145 loc) · 2.92 KB

Commands.md

File metadata and controls

178 lines (145 loc) · 2.92 KB

List of Termi's commands and their explanation and arguments sorted in alphabetical order

All arguments are std::string type, Termi will convert it later if needed;

List of arguments in "C++ style":

  • vect[i] = argument, i represents order

When typing arguments, don't use brackets and commas!

string encode = "-e";
string decode = "-d";
base64((do_encode == 1) ? encode : decode, text);
/* 
    Encodes plain text or decoding base64 text and printing result to 
    console
*/
calc(operator, num1, num2);
/* 
    Based on operator (+, -, *, /) Termi will perform an math operation and print result to console.
*/
cd(directory)
/*
    Enters directory by passed argument
*/
dencalc(mass, volume, density);
/*
    mass - grams
    volume - cm3
    density - g/cm3

    Use x if that value requires calculation
*/
echo(text, text2);
/*
    Prints to console all passed arguments
*/
find(path, file);
/*
    Searches file or directory in folder/directory.
*/
geocalc(std::vector<std::string>& vect);
/*
    Perform geo calculations and Termi 
    will print output to console

    SUR = surface
    EXT = extent

    REC = rectangle
    SQU = square
    TRI = triangle

    OPTIONS:
        1. vect[1] == "SUR"
            1. vect[2] == "REC"
                1. x = vect[3]
                2. y = vect[4]

            2. vect[2] == "SQU"
                1. x = vect[3]

            3. vect[2] == "TRA"
                1. x = vect[3]
                2. Vx = vect[4]

        2. vect[1] == "EXT"
            1. vect[2] == "TRA"
                1. x = vect[3]
                2. y = vect[4]
                3. z = vect[5]

            2. vect[2] == "REC"
                1. x = vect[3]
                2. y = vect[4]

            3. vect[2] == "SQU"
                1. x = vect[3]
*/
list(folder)
/* 
    List all files and directories in folder/directory.
*/
loadtp(path, function_name, value)
/* 
    Calls third party command or application.
    path - path of .dll or .so file
    function_name - name of function to be called
    value - argument, more arguments can be passed but they will be combined in one string
*/
mkdir(name)
/* 
    Creates new folder/directory which given name.
*/
openfile(file)
/* 
    Displays all content from file line by line.
*/
rm(file)
/* 
    Removes file which given name.
*/
sysfetch()
/* 
    Displays computer informations, all passed arguments will be ignored.
*/
time()
/* 
    Displays time, all passed arguments will be ignored.
*/
whoami()
/* 
    Displays current logged user, all passed arguments will be ignored.
*/
writefile(file, content)
/* 
    Writes given content to given file.
*/
yes()
/* 
    Displays word `yes` 100000, all passed arguments will be ignored.
    This function can slow down Termi
*/

Thank you for choosing Termi.

© 2022 ringwormGO