https://gist.github.com/jaysoffian/a666f6c97ec05edfa4fb36247a428971

Note the 9 second delay here:

2019-07-15 19:47:13.559623-0400 0x11591cb  Default     0x0                  25937  0    TextMate: [com.macromates.TextMate:BringToFront] TextMate: Show file browser for /Users/jsoffian/Work/code/ycm/sentry/.
2019-07-15 19:47:22.561110-0400 0x11591cb  Default     0x0                  25937  0    TextMate: [com.macromates.TextMate:BringToFront] TextMate: Bring to Front requested, NSApp.isActive: NO

Connected to an external display. TextMate was already running and had other windows open on the external display. "mate ." command issued from a bash shell inside iTerm2. That window was also on the external display. The laptop display has only a single Slack window. My "Missing Control" preferences are:

- [X] Automatically rearrange Spaces based on most recent use (enabled)
- [X] When switching to an application, switch to a Space with open windows for the application (enabled)
- [  ] Group windows by application (disabled)
- [X] Displays have separate Spaces (enabled)
- Dashboard: off

j.

On Sat, Jul 13, 2019 at 4:30 AM Allan Odgaard <mailinglist@textmate.org> wrote:

On 12 Jul 2019, at 19:49, Jay Soffian wrote:

I know I'm bumping an old thread. This behavior happens to me all the time
(a few times a day). I haven't been able to figure it out. I don't use fish
shell, but rather bash. I do use a multi-monitor setup but I think I've
seen it when only using my laptop alone. It probably dates back to High
Sierra. My typical use case is "mate ." in a directory, not a specific
file. That directory will have a ".tm_properties" file making it a project.
I use iTerm2.

Please go to Preferences → Software Update and ⌥-click the Check Now.

This should give you TextMate v2.0-rc.28 and mate v2.13.1-beta which does a bit of logging related to mate and TextMate’s “bring to front” code.

This is also in the release notes:


First run mate --version to ensure that TextMate auto-updated it to 2.13.1-beta (if not, go to Preferences → Terminal and uninstall/install it).

When the problem occurs, immediately run date in your terminal to get a timestamp to correlate with the debug log.

Then run this command to obtain the log:

log show --predicate 'subsystem = "com.macromates.TextMate" && category = "BringToFront"'

See man log for options such as --start date/time (to limit the query to e.g. the last 10 minutes).

Follow up in this thread with the log with relevant information, such as whether or not you were using spaces and/or multiple screens at the time.


_______________________________________________
textmate mailing list
textmate@lists.macromates.com
https://lists.macromates.com/listinfo/textmate