Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Bug: Delete Environment.CurrentDirectory: OperationStopped: Unable to find the specified file. #18121

Copy link
Copy link
@hannasm

Description

@hannasm
Issue body actions

Prerequisites

Steps to reproduce

mkdir tmp
cd tmp
pwsh
rm -rf ../tmp

write-host 'hello world';

Expected behavior

hello world


### Actual behavior

```console
OperationStopped: Unable to find the specified file.


### Error details

```console
After deleting the directory that powershell was opened with the entire environment becomes catatonic. From experience i know there are some wierd issues with folder paths, sometimes you need to manually change 


[Environment]::CurrentDirectory = (pwd).Path

to make things work correctly and this problem is solved by this command



### Environment data

```powershell
this is run from an up-to-date snap installation on debian linux

Visuals

No response

Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs-TriageThe issue is new and needs to be triaged by a work group.The issue is new and needs to be triaged by a work group.Resolution-FixedThe issue is fixed.The issue is fixed.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.