Automation

Script it in whatever you like. The explorer plays along.

There is no built-in scripting language to learn. Write your script in PowerShell, Python, a .bat file or AutoHotkey – MagnumOpus runs it over the selection, takes orders from it through mo --cmd and shows the files it found as a result tab.

Result tab with files found by a script: Folder and Note columns, the result chip in the address bar and a file preview
User commands

Your programs and scripts over the selection

Settings > User commands holds your own commands: a program, arguments with tokens such as {file}, {files}, {dir}, {dest} (the folder of the other pane) or {name}, a working folder and a file mask. They run from the command palette, the context menu and the keys User command 1–9.

  • Run once for all files, or for each file separately with at most N at once.
  • Output: nothing, a notification, a live output window, or a list of files that becomes a result tab.
  • {filelist} passes hundreds of paths in a temporary file, {input} asks for a text first – a search term for ripgrep, say.
  • Refresh the folder when done, ask before running.

Everything runs in the background. A command running longer than a second shows in the jobs panel, and its cross stops it including child processes.

Command line

A command line under the panels, like in Total Commander

Type a command and it runs in the current folder with cmd, Windows PowerShell or PowerShell 7. cd <folder>, cd .., cd - or D: navigate the active panel. Ctrl+Enter inserts the name of the item under the cursor, Ctrl+Shift+Enter its full path, and Up / Down browse the last 200 commands.

Enter opens a terminal window that stays open. With Command output set to Capture output, the command runs hidden: a short output arrives as a notification, a longer one in the output window. Shift+Enter always opens a terminal.

The command line under the panels with git log --oneline -5 typed in
Scripts

Drive the running window from a script

--cmd <id> runs any command palette command in the running window. Several commands run in the given order and each one waits until the previous one is done – folder loaded, dialog closed, copying finished. mo.exe, a small console launcher, adds --wait and returns an exit code.

mo C:\Projects\aurora --cmd pane.split-right=D:\Backups\aurora --cmd view.sort=date:desc --wait

The IDs are a stable interface: they are never renamed or removed. User commands run as user:<name>, workspaces as workspace:<name>.

Results

Script output as a result tab

mo --results <file> – or --results - from a pipe – shows a list of paths as a tab "Result: ". It is a flat list like search results with a Folder column, so you can select, copy, move and preview the files.

rg --files-with-matches FIXME C:\Projects | mo --results - --title "FIXME in projects"

One path per line, UTF-8 or UTF-16 (PowerShell Out-File too). path<TAB>note adds a Note column, for example the matching line from ripgrep. Items appear while the list is being read, F5 reads it again.

Measured
42 msmo.exe --wait with three commands, the whole round trip
24 msfirst items of a 10,000-path result tab
33 msall 10,000 paths of a result tab listed and sorted

Speed tests of the beta (cargo xtask perf) on the developer's machine, release build.

Also inside
WorkspacesSave the current windows with their tabs, panels and split under a name and open them later.
Command paletteCtrl+Shift+P finds any command, user command or workspace by a few scattered letters.
Start parameters--select, --split, --view, --sort, --filter, --search – for shortcuts and scripts.
Total Commander switches/L=, /R=, /T, /O, /N and Explorer's /select, work, so existing shortcuts keep working.
Listing commands--list-commands and --list-windows, also as JSON with --json. The app does not even have to run for the first.
Exit codesmo.exe --wait returns 0 when done and a specific code for a failure, timeout, cancel or unknown command.
Scripts know their windowUser commands get MO_DIR, MO_DEST, MO_WINDOW and MO_CLI, so a script can control the window it came from.
Add to PATHThe installer can add mo.exe to PATH for your user.
Local onlyOnly programs of the same user on the same computer can control the app. No network port.
File tools from scriptstools.find-duplicates, file.convert-images, file.compare-images, file.checksums and the other tools have IDs too.
Can be turned offSettings > Command line > Control from the command line (mo --cmd).