Artificial intelligent assistant

Unable to get multicharacter field in fzf preview _select () { apt-cache search '' | fzf \ --prompt='search: '\ --marker="M" \ --ansi \ --layout=reverse \ --cycle \ --multi \ --inline-info \ --preview "(apt show $(echo {} | awk ' - ' '{print $1}' 2>/dev/null) 2>/dev/null)" \ --preview-window="down:wrap:${PREVIEW_BORDER:-border-sharp}" \ -e } the following line gives me the first field _select | awk -F ' - ' '{print $1}' I want to preview the info of the package but I need the string of characters up to ' - ', in other words, the name of the package, not de description

Solved!


--preview "apt show {1} 2>/dev/null"

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy bdf99f13918b995dd0fb1d82fe535c3a