Skip to content
This repository was archived by the owner on Mar 3, 2023. It is now read-only.
This repository was archived by the owner on Mar 3, 2023. It is now read-only.

Open file in current window #1722

Closed

Description

@kevinsawicki

Seems reasonable

cmd-o AND file -> open is always opening a new window, there is a separate command for that. It's quite the nuisance. <3


This is perhaps a BIG one that undermines the foundation of Atom...but I find it quite irritating after coming from Sublime: I would like to be able to drag random files into a project/Atom instance so I can reference code side–by–side. Currently if I drag a random file from the finder into an Atom instance it automatically opens a new instance with the folder containing that file as the project root. Since I like to code in fullscreen, this means switching between a number of fullscreen Atom instances to look at or copy snippets of code. This isn't a particularly desirable workflow.

(from #1721)

...

Suppose that I open atom in my home directory. The working directory shown on the left is my home directory.
Now if I want to open a file that is not in the working directory then Atom opens a new window with that file and its directory. Same thing happens if I want to open a third file that is outside of those two working directories.

...

I'm coming from Sublime Text 2 and the default behavior there is every file in a new window. There is a configuration file that can be tweaked to make all files open in the same window.

...

I, too, would love to have files open in a new tab. It is absolutely crucial to my workflow. In the meantime I will continue using Sublime Text for this reason alone.

...

This is probably my single biggest annoyance and the reason why I can't use Atom full time.

(from #2005)

Also related issues:

Activity

  1. nathansobo commented on Mar 7, 2014

    @nathansobo
    Contributor

    👍

  2. julihermes commented on May 12, 2014

    @julihermes

    👍

  3. adrianocr commented on May 16, 2014

    @adrianocr

    👍

  4. izuzak commented on May 22, 2014

    @izuzak
    Contributor

    I updated this issue with some feedback from other issues which request the ability to open non-project files in the same window.

    Also, it seems that this depends on support for multiple root folders (projects) in the same window, which is discussed in #770 and atom/tree-view#63

  5. paulholzdev commented on May 29, 2014

    @paulholzdev

    👍

  6. chrismadrigal commented on May 30, 2014

    @chrismadrigal

    👍

  7. neiled commented on Jun 3, 2014

    @neiled

    👍

  8. cryptix commented on Jun 4, 2014

    @cryptix

    👍

  9. LaurensWind commented on Jun 5, 2014

    @LaurensWind

    👍

  10. arpitjalan commented on Jun 5, 2014

    @arpitjalan

    👍

  11. joshiji commented on Jun 6, 2014

    @joshiji

    👍

  12. radum commented on Jun 6, 2014

    @radum
    Contributor

    👍

  13. 122 remaining items

  14. alexrussell commented on Nov 17, 2015

    @alexrussell

    Ahh I've just noticed something. This behaviour may only happen on windows opened with the remember open windows feature. If I open a new window in a running instance of atom, and drag files onto it, they open as new tabs in that window. But if I drag something into a window that opened my previously-worked-on project, that's when a new window opens even if the file is int he same project.

    Hopefully that makes sense, and also helps the devs create some tests or at least reproduce the behaviour (as it may be that people "can't reproduce" the bug if they try to do so by creating a new project window in an existing project).

  15. alexrussell commented on Nov 17, 2015

    @alexrussell

    It maaaay be related to the cause behind a recently fixed bug in the 1.13 beta: #9408 (as that has a differentiation between windows that opened with Atom versus newly-opened windows).

    In the 'fix' (#9501) @kevinsawicki says that the cause was a recent Electron upgrade (though the fix here was to mess with the roles of the menus, so wouldn't affect or fix this specific issue).

  16. giacecco commented on Nov 24, 2015

    @giacecco

    Moreover, a new window is opened even if I drag on the old window a file that is already open!

    Something's being going wrong with window management for a few days now, at least on the Mac version - including #9584 . I can't find an open issue describing the window problem of the last few posts above, should we open one?

  17. alexrussell commented on Nov 24, 2015

    @alexrussell

    Good idea - I forgot this one was actually closed.

  18. winstliu commented on Nov 24, 2015

    @winstliu
    Contributor

    @giacecco Have you tried the 1.3.0 betas to see if that fixes your issue?

  19. alexrussell commented on Nov 24, 2015

    @alexrussell

    @50Wliu @giacecco Interestingly today (after updating to 1.3.0 beta6) I dragged some files (not even from the same project) into my window and they opened where I dragged them to, without opening up a new window. So it maaaay be fixed yet again (on 1.3.0 beta 6)?

    Though it may not be desirable behaviour for everyone - right now I can drag any file from anywhere into my Atom window and it opens in that window. Fine by me (in fact I like it that way) but I think some people would prefer it to only open in that window if it's somewhere within the project. If outside of the project, they'd prefer it to open a new window.

  20. davydden commented on Nov 24, 2015

    @davydden

    i would prefer to use the same window even when files are outside of the project folder.

  21. smaili commented on Nov 24, 2015

    @smaili

    Though it may not be desirable behaviour for everyone - right now I can drag any file from anywhere into my Atom window and it opens in that window. Fine by me (in fact I like it that way) but I think some people would prefer it to only open in that window if it's somewhere within the project. If outside of the project, they'd prefer it to open a new window.

    i would prefer to use the same window even when files are outside of the project folder.

    I vote to make it a setting and let the user decide 👍

  22. TechFounder commented on Nov 24, 2015

    @TechFounder

    I don't understand why everyone is making this more difficult than it has to be. Since Atom is a blatant attempt at copying Sublime and everyone seems to love it, why not just copy the same behavior as Sublime? This is not rocket science folks.

  23. lvancrayelynghe commented on Nov 25, 2015

    @lvancrayelynghe

    i would prefer to use the same window even when files are outside of the project folder.

    I vote to make it a setting and let the user decide 👍

    Same here 👍

  24. mawkler commented on Nov 25, 2015

    @mawkler

    👍

  25. smaili commented on Nov 25, 2015

    @smaili

    I don't understand why everyone is making this more difficult than it has to be. Since Atom is a blatant attempt at copying Sublime and everyone seems to love it, why not just copy the same behavior as Sublime? This is not rocket science folks.

    Issues is a place for talking about issues and proposing solutions in the hopes of improving functionality and user experience. If you want to post generalizations and attack the project, there are plenty of other forums that welcome it.

  26. TechFounder commented on Nov 25, 2015

    @TechFounder

    Sorry but I think I'm not the only one who's frustrated by this issue. After all, it's still ongoing after 19 months. As I stated before, just make the default behavior like Sublime and put in the option for people to change it for those who want something different.

  27. winstliu commented on Nov 25, 2015

    @winstliu
    Contributor

    This issue was closed more than a year ago with the requested functionality implemented.

    If you have further suggestions or bugs to report, please open different issues for them. I'm locking this issue for now since the original report has been solved.

  28. locked and limited conversation to collaborators on Nov 25, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions