-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
6 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,15 @@ | ||
use str | ||
|
||
fn __FUNCTION_ALIAS__ { |@a| | ||
use str | ||
var sep = __CMD_SEPARATOR__ | ||
var bhop_cmd = (echo __HOPPERCMD__ | $@a) | ||
var bhop_cmd = (echo __HOPPERCMD__ $@a) | ||
var out = (__SHELL_CALLABLE__ -c $bhop_cmd) | ||
if (not (str:contains $out $sep)) { | ||
echo $out | ||
} | ||
var arr = [(str:split $out $sep)] | ||
var arr = [(str:split $sep $out)] | ||
cd $arr[0] | ||
__SHELL_CALLABLE__ -c $arr[1] | ||
} | ||
|
||
edit:add-var __FUNCTION_ALIAS__~ $__FUNCTION_ALIAS__~ |