|
@@ -173,6 +173,19 @@ shellfu() {
|
173
|
173
|
shellfu __die "cannot import module: $mname"
|
174
|
174
|
fi
|
175
|
175
|
;;
|
|
176
|
+ reload)
|
|
177
|
+ #
|
|
178
|
+ # Reload module named $1 (unsafe!)
|
|
179
|
+ #
|
|
180
|
+ local mname=$1
|
|
181
|
+ shellfu _is_imported "$mname" || {
|
|
182
|
+ shellfu __warn "cannot reload; not imported yet: $mname"
|
|
183
|
+ return 2
|
|
184
|
+ }
|
|
185
|
+ if ! shellfu _do_import "$mname"; then
|
|
186
|
+ shellfu __die "cannot reload module: $mname"
|
|
187
|
+ fi
|
|
188
|
+ ;;
|
176
|
189
|
try_import)
|
177
|
190
|
#
|
178
|
191
|
# Try if module $1 could be imported
|