mirror of
https://github.com/Hilbis/Hilbish
synced 2025-07-06 11:02:03 +00:00
Compare commits
No commits in common. "e676c095c2f97b8c0f13709857d9b2dfce178b95" and "80d72a29bb1601561e93e6be02bdf85c259cfde8" have entirely different histories.
e676c095c2
...
80d72a29bb
@ -66,8 +66,6 @@ func (s *Snail) Run(cmd string, strms *util.Streams) (bool, io.Writer, io.Writer
|
||||
buf := new(bytes.Buffer)
|
||||
//printer := syntax.NewPrinter()
|
||||
|
||||
replacer := strings.NewReplacer("[", "\\[", "]", "\\]")
|
||||
|
||||
var bg bool
|
||||
for _, stmt := range file.Stmts {
|
||||
bg = false
|
||||
@ -97,7 +95,7 @@ func (s *Snail) Run(cmd string, strms *util.Streams) (bool, io.Writer, io.Writer
|
||||
_, argstring = splitInput(strings.Join(args, " "))
|
||||
|
||||
// If alias was found, use command alias
|
||||
argstring = util.MustDoString(s.runtime, fmt.Sprintf(`return hilbish.aliases.resolve [[%s]]`, replacer.Replace(argstring))).AsString()
|
||||
argstring = util.MustDoString(s.runtime, fmt.Sprintf(`return hilbish.aliases.resolve("%s")`, argstring)).AsString()
|
||||
|
||||
var err error
|
||||
args, err = shell.Fields(argstring, nil)
|
||||
|
@ -240,7 +240,7 @@ func NewInstance() *Instance {
|
||||
var err error
|
||||
rl.regexSearch, err = regexp.Compile("(?i)" + string(rl.tfLine))
|
||||
if err != nil {
|
||||
//rl.RefreshPromptLog(err.Error())
|
||||
rl.RefreshPromptLog(err.Error())
|
||||
rl.infoText = []rune(Red("Failed to match search regexp"))
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user