Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Explorer: auto create folder when file path ends with / #173902

Closed
zardoy opened this issue Feb 9, 2023 · 2 comments · Fixed by #173901
Closed

Explorer: auto create folder when file path ends with / #173902

zardoy opened this issue Feb 9, 2023 · 2 comments · Fixed by #173901
Assignees
Labels
feature-request Request for new features or functionality file-explorer Explorer widget issues verification-found Issue verification failed verification-needed Verification of issue is requested verified Verification succeeded
Milestone

Comments

@zardoy
Copy link
Contributor

zardoy commented Feb 9, 2023

For now on explorer.newFile vscode doesn't distinguish wether inputbox has trailing / or not. It would create file instead of folder in that case, which can be handy.

For now if you run explorer.newFile had an idea to create new file within new folder test/integration/etc and then forgot test name to create or decided to do it later you cannot just create folder from typed value. You have either:

  • Create dummy file at end eg: test/integration/etc/a and then remove just created file
  • Select all & copy typed value, run explorer.newFolder and paste value

I want clean and fast way to switch between creating file or folder. Please see my implementation for desired behavior: #173901

@vscodenpa vscodenpa added the unreleased Patch has not yet been released in VS Code Insiders label Mar 20, 2023
@lramos15 lramos15 removed the unreleased Patch has not yet been released in VS Code Insiders label Mar 20, 2023
@vscodenpa vscodenpa added this to the March 2023 milestone Mar 20, 2023
@lramos15 lramos15 added feature-request Request for new features or functionality file-explorer Explorer widget issues verification-needed Verification of issue is requested labels Mar 20, 2023
@lramos15
Copy link
Member

To verify ensure that attempting to create a file in the explorer via the new file button with the name test/ actually produces a folder. Also ensure that the test/foo.txt flow still produces a foo.txt file under a newly created test folder.

@eleanorjboyd
Copy link
Member

it works from the file explorer but I was wondering about the create file command from the command palette. Should the same action be possible? Currently, it was not and when trying to do a nested file in a folder it did not work. Thanks!
image
Screenshot 2023-03-21 at 11 32 03 AM

@eleanorjboyd eleanorjboyd added verification-found Issue verification failed and removed verification-needed Verification of issue is requested labels Mar 21, 2023
@rzhao271 rzhao271 added the verification-needed Verification of issue is requested label Mar 21, 2023
@DonJayamanne DonJayamanne added the verified Verification succeeded label Mar 22, 2023
@github-actions github-actions bot locked and limited conversation to collaborators May 5, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature-request Request for new features or functionality file-explorer Explorer widget issues verification-found Issue verification failed verification-needed Verification of issue is requested verified Verification succeeded
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants