Patch 0.2.7
ble-0.2.7 (2023-04-03)
Usage
Prerequisites
Bash 3.0+ and basic POSIX utilities are required.
Download ble-0.2.7.tar.xz
https://github.com/akinomyoga/ble.sh/releases/download/v0.2.7/ble-0.2.7.tar.xz
# DOWNLOAD with wget
wget https://github.com/akinomyoga/ble.sh/releases/download/v0.2.7/ble-0.2.7.tar.xz
# DOWNLOAD with curl
curl -LO https://github.com/akinomyoga/ble.sh/releases/download/v0.2.7/ble-0.2.7.tar.xzTrial & Install
# TRIAL
tar xJf ble-0.2.7.tar.xz
source ble-0.2.7/ble.sh
# INSTALL
tar xJf ble-0.2.7.tar.xz -C ~/.local/share/blesh
# Add the following line near the top of ~/.bashrc
[[ $- == *i* ]] && source ~/.local/share/blesh/ble.sh --noattach
# Add the following line at the end of ~/.bashrc
((_ble_bash)) && ble-attachblesh-0.2 fixes
- global: fix
ble/{is- => util/is}function5e82ca7 - global: pick fixes and changes from ble-0.1 backports 013eb1c
- complete: fix up 4df15e1 f02bd2a
- bump 0.2.7 1118c80
Fixes
- edit: work around the wrong job information of Bash in trap handlers (reported by 3ximus)
#D1435#D1436795a647 (master: bc4735e) - edit (sword): fix definition of
sword(shell words)#D14415e73cf6 (master: f923388) - edit (
kill-forward-logical-line): fix a bug not deleting newline at the end of the line#D144303787a2 (master: 09cf7f1) - global: work around bash-4.2 bug of
declare -gA(reported by 0xC0ncord)#D1470a2ace44 (master: 8856a04) - global: fix declaration of associative arrays for
ble-reload(reported by 0xC0ncord)#D1471533eba7 (master: 3cae6e4) - util (
ble/util/msleep): fix hang in Cygwin by swithing from/dev/udp/0.0.0.0/80to/dev/zero#D145246992e7 (master: d4d718a) - syntax: fix broken AST with
[[keyword#D14540482bf6 (master: 69658ef) - util (
ble/util/msleep): work around the bash-4.3 bug ofread -t(reported by 3ximus)#D1468#D1469fad78ea (master: 4ca9b2e) - bind: work around broken
cmd_xmapafter switching the editing mode#D147897ca117 (master: 8d354c1) - edit: clear graphic rendition on newlines and external commands
#D1479759b96d (master: 18bb2d5) - canvas: fix a glitch that SGR at the end of command line is applied to new lines
#D1498a6ac121 (master: 4bdfdbf) - syntax: fix a bug that
eval() { :; },declare() { :; }are not treated as function definition#D1529a4cda9c (master: b429095) - decode: fix a hang on attach failure by cache corruption
#D1531a4c13ab (master: 24ea379) - benchmark (
ble-measure): fix a bug that the result is always 0 in Bash 3 and 4 (fixup 8eb493a (master: bbc2a90))#D1615a034c91 - main: work around
. ble.sh --{test,update,clear-cache}in intereactive sessions#D15558eb493a (master: bbc2a90) - main: fix reloading after ble-update (fixup 8eb493a (master: bbc2a90)) (fixed by oc1024)
#D15589372670 - main: fix exit status for
bash ble.sh --test(fixup 8eb493a (master: bbc2a90))#D1558641238a - main: work around sourcing
ble.shinside subshells#D15548eb493a (master: bbc2a90) - global: use a better workaround of bash-4.2
declare -gAby separating assignment#D15670b7de99 (master: 2408a20) - edit (brackated-paste): fix incomplete
CR => LFconversion (reported by alborotogarcia)#D1587ac738bb (master: 8d6da16) - highlight (
layer:region): fix blocked lower-layer changes without selection changes#D1596650140f (master: 5ede3c6) - util: work around the Bash 3 bug of array assignments with
^Aand^?in Bash 3.2#D16140ed7f6d (master: b9f7611) - benchmark (
ble-measure): fix a bug that the result is always 0 in Bash 3 and 4 (fixup bbc2a90)#D161528e8dfe (master: a034c91) - decode, canvas, etc.: explicitly treat CSI arguments as decimal numbers (reported by GorrillaRibs)
#D1625c9e4198 (master: c6473b7) 2ea48d7 - edit: fix a bug that
command-helpdoesn't work#D1635b992bb5 (master: 0f6a083) - canvas: update prompt trace on
char_width_modechange (reported by Barbarossa93)#D164256b77a8 (master: 68ee111) - util (
ble/util/readfile): fix a bug of always exiting with 1 inbash <= 3.2(reported by laoshaw)#D16785b843bb (master: 61705bf) - complete: do not generate keywords for quoted command names
#D16917211b1e (master: 60d244f) - complete: fix empty completions with
FIGNORE(reported by seanfarley)#D171190f388a (master: 144ea5d) - main: fix the message of owner errors of cache directories (reported by zim0369)
#D1712d2bf86c (master: b547a41) - syntax: fix uninitialized syntax-highlighting in bash-3.2
#D17316aa12c8 (master: e3f5bf7) - progcomp: retry completions on
$? == 124also for non-default completions (reported by SuperSandro2000)#D1759c641fb1 (master: 82b9c01) - util (
ble/util/import): work around filenames with bash special characters#D17637da5f04 (master: b27f758) - edit: fix the restore failure of
PS1andPROMPT_COMMANDonble-detach#D178447dfdd9 (master: b9fdaab) - history: work around possible dirty prefix
*in the history output#D1808cc14f59 (master: 64a740d) - decode: fix the workaround for
set -ewith--prompt=attach#D1832958aae6 (master: 5111323) - main. util: fix problems of readlink etc. found by test in macOS (reported by aiotter)
#D18498f0acf3 (master: fa955c1)#D1855a22e145 - global: quote
return $?#D18849e10b54 (master: 801d14a) - bind: fix M-C-@, C-x C-@, and M-C-x (
bash-4.2 -o emacs)#D1920342826f (master: a410b03) - keymap/vi (
operator:filter): do not append newline at the end of line#D19942a8e746 (master: bce2033) - keymap/vi (
expand-range-for-linewise-operator): fix the end point being not extended#D19942a8e746 (master: bce2033) - syntax: fix unrecognized asignment
echo arr[i]+=rhs[sabbrev: apply sabbrev to right-hand sides of variable assignments]#D20064ed4fd4 (master: 41faa49) - syntax: fix unrecognized variable assignment of the form
echo arr[i]+=rhs#D20074ed4fd4 (master: 41faa49)
Changes
- syntax: exclude
\ + LFat the word beginning from words (motivated by cmplstofB)#D14316044a48 (master: 67e62d6) - edit: change default behavior of C-w and M-w to operate on backward words
#D1448787ff57 (master: 47a3301) - edit: the widgets
{kill,copy,delete}-region-ornow receives widgets as arguments#D10218f48aff (master: bbbd155) - edit (
ble/builtin/read): cancel by C-d on an empty line#D1473551bde3 (master: ecb8888) - syntax: change syntax context after
time ;and! ;for Bash 4.4#D14770b66cf4 (master: 4628370) - prompt: invalidate prompt and textarea on prompt setting changes
#D149254d310d (master: 1f55913) - prompt: adjust behavior of
LINENOand prompt sequence\#(reported by tycho-kirchner)#D15424b63b16 (master: 8b0257e) - main: show notifications against debug versions of Bash
#D1612608ac2a (master: 8f974aa) - prompt: do not evaluate
PROMPT_COMMANDfor subprompts#D16545c0cfde (master: 08e903e) - main: suppress non-interactive warnings from manually sourced startup files (reported by andreclerigo)
#D16762587bb0 (master: 0525528) 88e2df5 - main: suppress non-interactive warnings from manually sourced startup files (reported by andreclerigo)
#D16760525528 5f63856 (master: 88e2df5) - util (
ble/util/buffer): hide cursor in rendering#D17584ecbbdc (master: e332dc5) - edit (
ble-detach): prepend a space tostty saneforHISTIGNORE=' *'#D1796bd90371 (master: 26b532e) - history: disable the history file when
HISTFILEis empty#D1836d97ca10 (master: 9549e83) - keymap/vi (
decompose-meta): translate S-a to A#D1988eaf66c7 (master: 600e845) - term (
_ble_term_TERM): detect konsole#D1988eaf66c7 (master: 600e845) ed53858 - complete (
source:argument): fallback to rhs completion also forname+=rhs#D20064ed4fd4 (master: 41faa49)
Compatibility
- highlight: fix a problem that the attribute of the last character is applied till EOL
#D139336f9d80 (master: 2ddb1ba)#D1395ef09932 - highlight: fix a problem that the attribute of the last character is applied till EOL
#D13932ddb1ba#D13956bcb405 (master: ef09932) - global: work around empty
vi_imapcache bytmux-resurrect#D1562d7130d5 (master: 560160b) - main: work around
set -Bandset -k#D16283c97ae8 (master: a860769) - cmap: add
st-specific escape sequences for cursor keys#D1633bf46e34 (master: acfb879) - cmap: distinguish find/select from home/end for openSUSE
inputrc.keys(reported by cornfeedhobo)#D1648ad67555 (master: c4d28f4) - cmap: freeze the internal codes of find/select and kitty special keys
#D1674f41b800 (master: fdfe62a) - decode: work around the overwritten builtin
set(reported by eadmaster)#D168093ae08d (master: a6b4e2c) - complete: work around the variable leaks by
virshcompletion fromlibvirt(reported by telometto)#D1682ee2ac07 (master: f985b9a) - stty: do not remove keydefs for C-u, C-v, C-w, and C-? (reported by laoshaw)
#D1683c01487b (master: 82f74f0) - main: work around
XDG_RUNTIME_DIRof a different user bysu(reported by zim0369)#D1712e5501a3 (master: 8d37048) - main (
ble/util/readlink): work around non-standard or missingreadlink(motivated by peterzky)#D1720d785f5d (master: a41279e) - global: work around the arithmetic syntax error of
10#in Bash-5.1#D17342b55aa1 (master: 7545ea3) - global: adjust implementations for Bash 5.2
patsub_replacement#D1738359a389 (master: 4590997) - main: check
/dev/ttyon startup (reported by andychu)#D174919fa092 (master: 711c69f) - global: work around
shopt -s compat42#D1754e7adfb3 (master: a75bb25) - global: identify bash-4.2 bug that internal quoting of
${v/%$empty/"$rep"}remains#D1753e7adfb3 (master: a75bb25) - prompt: fix a bug of
ble/prompt/printredundantly quoting$#D1752e7adfb3 (master: a75bb25) - global: work around
compat42quoting of"${v/pat/"$rep"}"#D1751e7adfb3 (master: a75bb25) - util: add identification of Windows Terminal
wt#D17584ecbbdc (master: e332dc5) - global: work around bash-3.0 bug that single quotes remains for
"${v-$''}"#D1774fb607ad (master: 9b96578) - main: resolve empty
HOSTNAME[addhistdb]#D19255812f2e (master: 44d9e10) - main: warn empty
LANG[main: support an option--inputrc={diff,all,user,none}]#D19263f29bee (master: 92f2006) - main: never load
/etc/inputrcin openSUSE (motivated by Ultra980)#D19263f29bee (master: 92f2006) 0ceb0cb - main: show warning for empty locale (movivated by Ultra980)
#D19273f29bee (master: 92f2006) - term (
terminology): work around terminal glitches#D19462d4caa6 (master: 9a1b4f9) - edit: always adjust the terminal states with
bind -x(reported by linwaytin)#D1983cdda7c4 (master: 5d14cf1) - syntax: suppress brace expansions in designated array initialization in Bash 5.3
#D198978dd47e (master: 1e7b884) - edit: restore
PS1while processingbind -x(reported by adoyle-h)#D2024c46f423 (master: 2eadcd5)
Optimization
- util (
ble/util/assign): work around subshell conflicts#D157859d6355 (master: 6e4bb12) - prompt: fix not properly set
$?in${PS1@P}evaluation (reported by nihilismus)#D164466fd10b (master: 521aff9) - util (
ble/string#split): optimize#D18265b3fc89 (master: 7bb10a7) - debug: add
ble/debug/profiler(motivated by SuperSandro2000)#D1824f629698 11aa4ab 5b3fc89 (master: 7bb10a7) - global: avoid passing arbitrary strings through
awk -v var=value#D18274571695 (master: 82232de)
Internal changes and fixes
- main: include hostname in local runtime directory
#D1444d19ab29 (master: 6494836) - global: fix status check for read timeout
#D14670bcc12c (master: e886883) - util, etc: ensure each function to work with arbitrary
IFS#D1490#D14912fe60b6 (master: 5f9adfe) - util: fix
ble/util/dense-array#fill-rangeb708ee2 (master: a46fdaf) - util: fix leak variables
buff,trap,{x,y}{1,2}#D157236d151e (master: 5967d6c) - make: add fallback Makefile for BSD make
#D18056498a5d (master: e5d8d00) - util, decode, vi: fix leak variables
#D1933002dda7 (master: 8d5cab8) - syntax: fix code formatting [histdb: support auto-complete source
histdb-word]#D1938edd48d1 (master: 00cae74) - main: use builtin for
:[histdb: support timeout of background processes]#D19718640dc4 (master: e0566bd) - global: normalize bracket expressions to
_a-zA-Z/_a-zA-Z0-9#D20064ed4fd4 (master: 41faa49) - util (restore-vars): work around
set -u[util.bgproc: separateble/util/bgprocfromhistdb]#D2017d60758a (master: 7803305)
Test
- util (ble/util/s2bytes): clear locale cache
#D188199e217d (master: 2e1a7c1) - util (ble/util/s2c): work around intermediate mbstate of bash <= 5.2
#D188199e217d (master: 2e1a7c1) - util (ble/encoding:UTF-8/b2c): fix interpretation of leading byte
#D188199e217d (master: 2e1a7c1)