Opening File In Text Editor From Mac Terminal

Bash

27/09/2021


You can open any file from your Mac's terminal with the following command.

BASH
open -a TextEdit filename.extension

There are a 2 things you should keep in mind:

  • The -a flag allows you to specify which application to use, and
  • This command is run in the same directory as the file. If not, prepend the path to the filename.

WRITTEN BY

Code and stuff