1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-24 17:35:35 +02:00

output interpretation fixes for local shell

This commit is contained in:
David McKnight 2006-04-26 14:11:56 +00:00
parent 7eefb61774
commit a3d78eb154
4 changed files with 31 additions and 11 deletions

View file

@ -96,10 +96,11 @@ command: .*bat\s.*
error file line pattern=file:([\w,.,/,\\,:]*):(\d*):.*
command: dir.*
directory file pattern=\d{2}/\d{2}/\d*\s\d{2}:\d{2}[a,p,AM,PM,\s].*\s*<DIR>\s*([\w,.,/,\\,\s,\-,\+\+,\d]*).*
file file pattern=\d{2}/\d{2}/\d*\s\d{2}:\d{2}[a,p,AM,PM,\s].*\s*[\d,,]* ([\w,.,/,\\,\s,\-,\+\+,\d]*).*
directory file pattern=[\d,/,\\,.,-]+.\s*\d{2}[:,.]\d{2}.\s*<DIR>\s*([\w,.,/,\\,\s,\-,\+\+,\d]*)
file file pattern=[\d,/,\\,.,-]+.\s*\d{2}[:,.]\d{2}.\s*[\d,,,.]*\s*([\w,.,/,\\,\s,\-,\+\+,\d]*)
directory file pattern=\d{2}/\d{2}/\d*\s*\d{2}:\d{2}\s[a,p,AM,PM]+\s*<DIR>\s*([\w,.,/,\\,\s,\-,\+,\d]*).*
directory file pattern=.*<DIR>\s*([\w,.,/,\\,\s,\-,\+,\d]*).*
file file pattern=\d{2}/\d{2}/\d*\s*\d{2}:\d{2}\s[a,p,AM,PM]+\s*[\d,,]*\s*([\w,.,/,\\,\s,\-,\+,\d]*).*
directory file pattern=[\d,/,\\,.,-]+.\s*\d{2}[:,.]\d{2}.\s*<DIR>\s*([\w,.,/,\\,\s,\-,\+,\d]*)
file file pattern=[\d,/,\\,.,-]+.\s*\d{2}[:,.]\d{2}.\s*[\d,,,.]*\s*([\w,.,/,\\,\s,\-,\+,\d]*)
command: ls -l.*
file file pattern=-[-,r,w,x]+\s.*\s[\d{4},\d{2}:\d{2}]+,\s([\w,.,/,(,),\\,\-,\+\s,\d]*)

View file

@ -96,10 +96,11 @@ command: .*bat\s.*
error file line pattern=file:([\w,.,/,\\,:]*):(\d*):.*
command: dir.*
directory file pattern=\d{2}/\d{2}/\d*\s\d{2}:\d{2}[a,p,AM,PM,\s].*\s*<DIR>\s*([\w,.,/,\\,\s,\-,\+\+,\d]*).*
file file pattern=\d{2}/\d{2}/\d*\s\d{2}:\d{2}[a,p,AM,PM,\s].*\s*[\d,,]* ([\w,.,/,\\,\s,\-,\+\+,\d]*).*
directory file pattern=[\d,/,\\,.,-]+.\s*\d{2}[:,.]\d{2}.\s*<DIR>\s*([\w,.,/,\\,\s,\-,\+\+,\d]*)
file file pattern=[\d,/,\\,.,-]+.\s*\d{2}[:,.]\d{2}.\s*[\d,,,.]*\s*([\w,.,/,\\,\s,\-,\+\+,\d]*)
directory file pattern=\d{2}/\d{2}/\d*\s*\d{2}:\d{2}\s[a,p,AM,PM]+\s*<DIR>\s*([\w,.,/,\\,\s,\-,\+,\d]*).*
directory file pattern=.*<DIR>\s*([\w,.,/,\\,\s,\-,\+,\d]*).*
file file pattern=\d{2}/\d{2}/\d*\s*\d{2}:\d{2}\s[a,p,AM,PM]+\s*[\d,,]*\s*([\w,.,/,\\,\s,\-,\+,\d]*).*
directory file pattern=[\d,/,\\,.,-]+.\s*\d{2}[:,.]\d{2}.\s*<DIR>\s*([\w,.,/,\\,\s,\-,\+,\d]*)
file file pattern=[\d,/,\\,.,-]+.\s*\d{2}[:,.]\d{2}.\s*[\d,,,.]*\s*([\w,.,/,\\,\s,\-,\+,\d]*)
command: ls -l.*
file file pattern=-[-,r,w,x]+\s.*\s[\d{4},\d{2}:\d{2}]+,\s([\w,.,/,(,),\\,\-,\+\s,\d]*)

View file

@ -129,7 +129,8 @@ implements ISystemViewElementAdapter, ISystemRemoteElementAdapter, ISystemOutpu
if (firstSelection instanceof IRemoteLineReference)
{
IRemoteOutput result = (IRemoteOutput) firstSelection;
if (result.getType().equals("prompt"))
String type = result.getType();
if (type.equals("prompt"))
{
if (_pasteToPromptAction == null)
{
@ -138,6 +139,15 @@ implements ISystemViewElementAdapter, ISystemRemoteElementAdapter, ISystemOutpu
menu.add(menuGroup, _pasteToPromptAction);
}
else if (type.equals("directory"))
{
IRemoteOutput output = (IRemoteOutput)firstSelection;
if (output.getAbsolutePath() != null)
{
// TODO
// add directory actions here
}
}
else
{
IRemoteOutput output = (IRemoteOutput)firstSelection;

View file

@ -1,6 +1,8 @@
package org.eclipse.rse.subsystems.shells.local.model;
import java.io.File;
import org.eclipse.rse.core.subsystems.ISubSystem;
import org.eclipse.rse.internal.services.local.shells.ParsedOutput;
import org.eclipse.rse.internal.services.local.shells.Patterns;
@ -83,7 +85,7 @@ public class LocalServiceCommandShell extends ServiceCommandShell
if (event.isError())
{
output = new RemoteError(this, type);
}
}
else
{
output = new RemoteOutput(this, type);
@ -98,9 +100,15 @@ public class LocalServiceCommandShell extends ServiceCommandShell
_workingDir = file;
output.setAbsolutePath(_workingDir);
}
/*
else if (type.equals("file") || type.equals("directory"))
{
output.setAbsolutePath(parsedMsg.file);
}
*/
else
{
output.setAbsolutePath(_workingDir + "\\" + file);
output.setAbsolutePath(_workingDir + File.separatorChar + file);
}
}