I’ve got a week old install of Windows 10 which is showing issues with Powershell. Most noteably, the prompt does not show the current working directory.
Where I used to get PS C:\Windows\System32> when launching an admin prompt now I just get PS>
When I reinstalled I set up chocolatey and installed a pile of packages.
Set-WindowsExplorerOptions -showHidenFilesFoldersDrives -showProtectedOSFiles -showFileExtensions
Enable-RemoteDesktop
Set-ExecutionPolicy Unrestricted
iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))
choco feature enable -n allowGlobalConfirmation
choco install chocolateygui
choco install 7zip
choco install autohotkey
choco install keepass
choco install f.lux
choco install teracopy
choco install slack
choco install firefox
choco install googlechrome
choco install opera
choco install javaruntime
choco install flashplayerplugin
choco install git
choco install poshgit
choco install sourcetree
choco install nodejs
choco install sysinternals
choco install fiddler4
choco install baretail
choco install filezilla
choco install notepadplusplus
choco install dropbox
choco install evernote
choco install XnView
choco install picasa
choco install ffmpeg
choco install paint.net
choco install calibre
choco install telegram.install
choco install dotnet4.5
choco install aspnetmvc
choco install aspnetmvc4
choco install mssqlservermanagementstudio2014express
choco install wix35
choco install linqpad
choco install winmerge
choco install mysql
choco install mysql.workbench
choco install sumatrapdf
choco install greenshot
choco install qbittorrent
choco install youtube-dl
choco install vlc
choco install ffmpeg
choco install foobar2000
choco install mp3tag
choco install audacity
choco install virtualclonedrive
choco install python
choco install python2
choco install sublimetext3
choco install pandoc
choco install markdownpad2
Then I ran a script to enable a bunch of windows features.
Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName MicrosoftWindowsPowerShellV2Root; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName MicrosoftWindowsPowerShellV2; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Internet-Explorer-Optional-amd64; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName NetFx3; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-WebServerRole; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-WebServer; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-CommonHttpFeatures; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-HttpErrors; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-HttpRedirect; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-ApplicationDevelopment; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-NetFxExtensibility; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-NetFxExtensibility45; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-HealthAndDiagnostics; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-HttpLogging; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-LoggingLibraries; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-RequestMonitor; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-HttpTracing; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-Security; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-URLAuthorization; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-RequestFiltering; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-IPSecurity; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-Performance; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-WebServerManagementTools; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-HostableWebCore; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName WCF-Services45; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName WCF-TCP-PortSharing45; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-CertProvider; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-WindowsAuthentication; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-DigestAuthentication; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-ClientCertificateMappingAuthentication; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-IISCertificateMappingAuthentication; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-ODBCLogging; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-StaticContent; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-DefaultDocument; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-DirectoryBrowsing; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-ASPNET; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-ASPNET45; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-ASP; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-ISAPIExtensions; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-ISAPIFilter; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-CustomLogging; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-BasicAuthentication; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-HttpCompressionStatic; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName IIS-ManagementConsole; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName NetFx4-AdvSrvs; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName NetFx4Extended-ASPNET45; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName MediaPlayback; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName WindowsMediaPlayer; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Printing-PrintToPDFServices-Features; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Printing-XPSServices-Features; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName MSRDC-Infrastructure; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName SearchEngine-Client-Package; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName TelnetClient; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Xps-Foundation-Xps-Viewer; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName WorkFolders-Client; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName SMB1Protocol; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Microsoft-Hyper-V-All; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Microsoft-Hyper-V-Tools-All; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Microsoft-Hyper-V-Management-Clients; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Microsoft-Hyper-V-Management-PowerShell; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Microsoft-Hyper-V; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Microsoft-Hyper-V-Hypervisor; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Microsoft-Hyper-V-Services; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Printing-Foundation-Features; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName Printing-Foundation-InternetPrinting-Client; Enable-WindowsOptionalFeature -Online -NoRestart -FeatureName FaxServicesClientPackage;
I’ve run sfc /scannow and fixed an error with .NET using DISM. I’ve also tried uninstalling chocolatey, powershell 2.0 from the features menu and force installing powershell 4.0 again, no joy.
How do I fix this?