Bash 5.3-ի հրատարակումը

Almost three years of development have resulted in the release of a new version of the GNU Bash command interpreter 5.3, which is used by default in most Linux distributions. At the same time, the release of the readline library 8.3, used in bash for command line editing, has been announced.

Key improvements include:

  • New command substitution forms «${ command; }» and «${|command;}» have been implemented, allowing the interception of command output without forking a separate child process and without using unnamed pipes. The results of command execution are returned as a substitution result or written to the REPLY variable.
  • A new variable GLOBSORT has been added, determining the sorting method during file path completion. For example, sorting by name (GLOBSORT=name), size (GLOBSORT=size), or modification time (GLOBSORT=mtime) can be chosen, as well as whether to sort in ascending (from smaller to larger) or descending (from larger to smaller) order (e.g., with «GLOBSORT=-size», the largest files will be shown first).
  • An option «-V varname» has been added to the built-in command «compgen», which allows saving generated completions to a variable instead of outputting them to the standard stream.
  • An option «-E» has been added to the built-in command «read», which utilizes the readline library with rules for bash autocompletion when inputting data.
  • An option «-p PATH» has been added to the built-in command «source», allowing the redefinition of the search path in file paths (the specified value is used instead of the $PATH variable).
  • The source code has been updated to use the C23 standard. The ability to compile with compilers in «K&R C» mode (the style corresponding to the C language description in Kernighan and Ritchie’s book «The C Programming Language») has been discontinued.
  • The built-in command «umask» has been fully aligned with POSIX specifications.
  • A new loadable command «kv» has been added, which creates an associative array based on a key value data set.
  • A new loadable command «strptime» has been added, which converts a textual representation of date and time into epoch time (the number of seconds since January 1, 1970).
  • A new loadable command «fltexpr» has been added, allowing floating-point arithmetic operations similar to the let command.
  • A dynamically set variable BASH_MONOSECONDS has been added, which contains the current value of the system's monotonic clocks, which continuously increase even when the time is adjusted backwards.
  • In POSIX mode, string comparison in the «test» command using the operators «» is now performed considering the current locale.
  • In the command «bind -x», it is now allowed to separate the key and the called command with a space, if the sequence is enclosed in double quotes.
  • Նոր Readline տարբերակում ավելացվել է «search-ignore-case» տարբերակը, որը թույլ է տալիս որոնել պատմության մեջ, հաշվի չառնելով ձառայությունների գրությունը: Ավելացվել է «export-completions» հրաման, որը հնարավորություն է տալիս արտահանել բառի լրացման տարբերակները այլ գործընթացների մշակման համար: Ավելացվել է «execute-named-command» հրաման, որը կատարում է հրաման, որի անունը ստացվել է ստանդարտ մուտքային հոսքից:

Ընտանիք: opennet.ru

Գնել հուսալի հյուրընկալում DDoS պաշտպանությամբ, VPS VDS սերվերներով 🔥 Գնել հուսալի հյուրընկալում DDoS պաշտպանությամբ, VPS VDS սերվերներով | ProHoster