How to open a file through terminal

any command I can run in the Theia terminal to open a file?

saw this theia-open https://github.com/perrinjerome/theia-open/tree/master/theia-open but could not figure out the THEIA_OPEN_EDITOR_TOKEN

any information is appreciate. thanks!

@huanxu4 thank you for the discussion, at the moment there is no command contributed by the framework to open a file, so there are two approaches you can take (https://github.com/eclipse-theia/theia/issues/3724):

  • find an existing extension that contributes the feature (perhaps like you’ve mentioned https://github.com/perrinjerome/theia-open) - if you have trouble with the extension, you might want to open an issue in the corresponding repository to ask the author.
  • implement the feature yourself perhaps as a custom @theia extension