设定: 添加一个新文件,执行svn添加,然后删除该文件,以便获得svn缺失错误:
c:\path\trunk\svn commit
C:\path\trunk>svn commit svn: E155010: Commit failed (details follow):
svn: E155010: 'C:\path\trunk\New Text Document.txt' is scheduled for
addition, but is missing
但是,如果从powershell运行相同的命令,则会得到以下内容:
PS>&svn commit
svn.exe : svn: E155010: Commit failed (details follow):
At line:1 char:1
+ &svn commit
+ ~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (svn: E155010: C...etails follow)::String) [], RemoteException
+ FullyQualifiedErrorId : NativeCommandError
您会注意到powershell输出从不显示引用的"详细信息如下"。有没有办法显示命令的完整输出?
答案 0 :(得分:2)
按照步骤操作时,我在powershell和cmd提示符下输出相同的输出。两者都产生:
override func viewDidLoad() {
super.viewDidLoad()
NotificationCenter.default.addObserver(self, selector: #selector(keyboardWillChange(notification:)), name: NSNotification.Name.UIKeyboardWillChangeFrame, object: nil)
NotificationCenter.default.addObserver(self, selector: #selector(keyboardWillHide), name: NSNotification.Name.UIKeyboardWillHide, object: nil)
}
@objc func keyboardWillHide() {
self.view.frame.origin.y = 0
}
@objc func keyboardWillChange(notification: NSNotification) {
if let keyboardSize = (notification.userInfo?[UIKeyboardFrameEndUserInfoKey] as? NSValue)?.cgRectValue {
if myTextField.isFirstResponder {
self.view.frame.origin.y = -keyboardSize.height
}
}
}
Powershell没有获得错误记录。这是在Powershell 5.1中使用Tortoise SVN 1.9.7。话虽如此,您可以通过查看$ error [0]并检查Exception属性来获取更多详细信息。
svn: E155010: Commit failed (details follow):
svn: E155010: 'C:\temp\trunk\test.txt' is scheduled for addition, but is missing