# shellcheck shell=dash
___x_cmd_scotty_mod_branch(){
    :
}

___x_cmd_scotty_mod_branch_feature(){
    local issue="${1:?issue-number}"
    # feature-issue12341-20220815-lijunhao-dosomething-for-it
}

___x_cmd_scotty_mod_branch_fix(){
    local issue="${1:?issue-number}"
    # bugfix-issue12341-20220815-lijunhao-dosomething-for-it

}

# using pr to merge the branch ...

___x_cmd_scotty_mod_name(){
    local name; name=$(___x_cmd git meta path)
    name="${name#*/}"
    name="${name%.git}"
    printf "%s\n" "$name"
}

___x_cmd_scotty_mod_venv()(
    local buildpath; buildpath="$(___x_cmd wsroot)/.build"
    [ ! -d "$buildpath" ] || return 0
    ___x_cmd mkdirp "$buildpath"
    ___x_cmd_inner_cd "$buildpath" || return 1
    local modname; modname="$(___x_cmd_scotty_mod_name)"
    ___x_cmd_cmds_ls "$___X_CMD_ROOT_MOD" | while read -r p; do
    echo "$p"
        command ln -s "$___X_CMD_ROOT_MOD/$p" "$p"
    done

    [ ! -f "$modname" ] || ___x_cmd_cmds_rm "$modname"
    command ln -s ".." "$modname"
)

