Skip to content

Commit

Permalink
Fixed default working directory path parameter for RishkaVM::initiali…
Browse files Browse the repository at this point in the history
…ze()
  • Loading branch information
nthnn committed Apr 14, 2024
1 parent 7f2a8dc commit e41535c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/shell_example/shell_example.ino
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ void setup() {

// Initialize the Rishka VM instance.
vm = new RishkaVM();
vm->initialize(&Terminal, "/");
vm->initialize(&Terminal);

// Print prompt
Terminal.print("\e[32m[\e[97m" + vm->getWorkingDirectory() + "\e[97m\e[32m]~\e[97m ");
Expand Down
2 changes: 1 addition & 1 deletion src/rishka_vm.h
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ class RishkaVM final {
* @param stream A pointer to the Terminal object for input/output operations.
* @param directory The path to the new working directory.
*/
void initialize(fabgl::Terminal* terminal, String workingDirectory);
void initialize(fabgl::Terminal* terminal, String workingDirectory = "/");

/**
* @brief Resets the Rishka virtual machine instance to its initial state.
Expand Down

0 comments on commit e41535c

Please sign in to comment.