mirror of
https://github.com/bettercap/bettercap
synced 2025-08-14 02:36:57 -07:00
new: session scripts can now include other scripts via require('file')
This commit is contained in:
parent
2b1ff7d59f
commit
8827a2af84
6 changed files with 94 additions and 20 deletions
|
@ -311,7 +311,7 @@ func (s *Session) Start() error {
|
|||
|
||||
// load the script here so the session and its internal objects are ready
|
||||
if *s.Options.Script != "" {
|
||||
if s.script, err = LoadScript(*s.Options.Script, s); err != nil {
|
||||
if s.script, err = LoadScript(*s.Options.Script); err != nil {
|
||||
return fmt.Errorf("error loading %s: %v", *s.Options.Script, err)
|
||||
}
|
||||
log.Debug("session script %s loaded", *s.Options.Script)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue