rhel7 - 在 Linux 上的 PowerShell 中读取或写入历史文件时出错
问题描述
我刚刚在运行 RHEL 7.x (maipo) 的 2 个机器上安装了 PS 7.0.2。奇怪的是,其中一个显示以下错误
$ pwsh
PS /home/user_name> dir
Error reading or writing history file '/home/user_name/.local/share/powershell/PSReadLine/Console_history.txt': Access to the path '/home/user_name/.local/share/powershell/PSReadLine/Console_history.txt' is denied
PS /home/user_name> exit
Error reading or writing history file '/home/user_name/.local/share/powershell/PSReadLine/Console_history.txt': Access to the path '/home/user_name/.local/share/powershell/PSReadLine/Console_history.txt' is denied
This error will not be reported again in this session. Consider using a different path with:
Set-PSReadLineOption -HistorySavePath <Path>
Or not saving history with:
Set-PSReadLineOption -HistorySaveStyle SaveNothing
我不知道为什么。我所做的只是下载 RPM 并安装它。两个盒子实际上是彼此的副本:(
有什么建议么?
解决方案
错误..刚刚想通了。这是一个错误的 umask 设置,覆盖了我的 ~/.bashrc 中的默认设置。
评论出来解决了这个问题。
推荐阅读
- apache - Apache - set application MIME type based on URL or directory
- html - Strange font size change depending on number of list elements in iPhone browsers
- c++ - How to split a Pounds decimal value correctly in C++ to Pounds and Ounces?
- python - 有没有办法从 Tkinter 中的条目表中逐行获取数据?
- r - Prevent Power BI to remove duplicated rows when exporting to R custom visual
- sql - UNION ALL view With Select from variable
- sql - 如何按列的计数对表进行排序?
- haskell - 线性类型让递归函数的绑定解决方法
- ubuntu-18.04 - OpenVPN linux client - no LAN access from MAC-filtered networks
- python - How to read and convert TSV file into NPZ with base64