Skip to content

Releases: mafredri/zsh-async

1.4.0 bulletproof-badger

12 Jan 17:33
Compare
Choose a tag to compare

New features and improvements

  • Automated test suite!
    • Travis now runs tests for zsh versions: 5.3.1, 5.3, 5.2, 5.1.1, 5.0.8 and 5.0.2
  • Now works with debugging (setopt xtrace or zsh -x) enabled
  • Jobs (via async_job) are now allowed to output NULL-characters ($'\0')
  • Stdout and stderr from jobs are now use a higher lever of quoting instead of relying on typeset -p quoting (which is insufficient)
  • More advanced commands can now be sent to async_job
  • Killing jobs (via async_flush_jobs) should now be more reliable (previously it did not properly terminate jobs on some systems)

Bugfixes

  • The async worker no longer dies if a newer async worker (or zpty instance) is stopped
  • Error output (stderr) in the worker is now discarded to avoid interfering with job output
  • async_process_results could, in edge cases, discard an incomplete message from $ASYNC_PROCESS_BUFFER[$worker], it was rewritten to avoid this

Full changelog: v1.3.1...v1.4.0

1.3.1

18 Nov 15:54
Compare
Choose a tag to compare

Changelog

  • Bugfix: Remove incorrect word split on the items array in async_process_results when invoking the callback. For some reason this has worked on older versions of zsh, but is broken in 5.2-dev.
  • Avoid inheriting zsh hooks inside async worker

Full changelog: v1.3.0...v1.3.1

1.3.0

02 Sep 16:21
Compare
Choose a tag to compare

Changelog

  • Close coproc when async worker is idle (prevent long-running cat process)
  • Improve passing parameters between async_job and async worker to avoid losing whitespace and newlines (df61b12, #8)

Full changelog: v1.2.0...v1.3.0

1.2.0

02 Sep 16:28
Compare
Choose a tag to compare

Changelog

  • Avoid non-zero exit status when called internally (627f8db, #5)
  • Avoid leaking $line and $IFS into callback handler from async_process_results (43e3d4e, c32a5c6, #6)
  • Comments and typo fixes

Full changelog: v1.1.0...v1.2.0

v1.1.0 gotta-kill-'em-(all)!

14 Nov 13:28
Compare
Choose a tag to compare

This release brings proper support for flushing jobs and leverages ZLE watchers for notifying (instead of kill signals) on zsh versions >=5.1.

Changelog

  • Previously async_flush_jobs only killed the immediate child running inside a worker. If something else was executed by that child, it would continue running until completion. This was changed to instead send a TERM-signal to the entire process group thus allowing all task to exit gracefully.
  • ZLE watcher replaces the kill -WINCH method of notifying when a job is complete whenever it is available (done through feature detection). Since zsh 5.1 zpty workers return the fd that was created for them and because of that we can attach a ZLE watcher to the fd that is triggered on output.
  • Fixed an issue where async notify didn't work if setopt localtraps was set.
  • Code cleanup

Full changelog: v1.0.0...v1.1.0

v1.0.0 separation-of-stds

15 Jul 16:30
Compare
Choose a tag to compare

Biggest feature in this release is the separation of stdout and stderr, introducing a new fifth parameter $5 (for stderr).

Other:

  • Null $'\0' characters are now stripped from the output
  • Bugfixes
  • Improvements

Changes: v0.2.3...v1.0.0

v0.2.3 killer-of-async

30 May 15:35
Compare
Choose a tag to compare
  • Make sure the flushed jobs really die with kill -KILL (-9).
  • Small fix for flushing jobs on older zsh versions (4.x)

v0.2.2

29 May 16:29
Compare
Choose a tag to compare
  • Fixed a bug where async_flush_worker failed to detect any workers and did not clear current jobs
  • async_job no longer requires a function for more complicated expressions, you can now use it like so: async_job <worker> 'sleep 1 && echo "very async"
  • Other minor improvements to prevent potential globbing