murex

A smarter shell and scripting environment with advanced features designed for usability, safety and productivity (eg smarter DevOps tooling)

GPL-2.0 License

Stars
1.4K
Committers
12

Bot releases are visible (Hide)

murex - v6.0.1000 Latest Release

Published by lmorg 8 months ago

Despite this being a new major version release, it is a vary minor update.
Aside from a handful of bugfixes, the most significant change is notice of
deprecation for =, let, and ?.

Breaking Changes

None

Deprecation Warnings

Please read out compatibility commitment to understand how features are deprecated.

  • the ? pipe will be deprecated to make way for a the ternary operator. You can achieve the same result with <err> <!out>, eg command <err> <!out> parameters... | next-command ...

  • the = and let builtins are now officially deprecated. They've been marked as deprecated in the documentation for a couple of years but you'll now receive a deprecation warning when using them. This warning will not impact any functions that call them (they bypass the STDOUT and STDERR pipes and write directly to your TTY) but it is still recommended that you update any existing code not to use it. The change is very simple, Murex supported expressions as first class primitives, so you can simply drop the = and let command names from your expressions

Features

Features marked as EXPERIMENTAL are provided without assurances of future breaking changes. All other features are considered stable as part of Murex's compatibility commitment.

  • new integrations for the experimental mxtty terminal emulator (Github repo)

Bug Fixes

  • which and whereis autocompletions were Linux specific. Now they're enabled for all platforms

  • grep and egrep aliases were Linux specific. Now they're enabled for all POSIX platforms

  • zero length environment variables are no longer being reported as null by is-null (issue #786)

  • fixed edge case where a zero length string could generate a panic when normalising paths (issue #789)

  • suppress sqlite3 cache error message. The error doesn't impact the operation of Murex, it just spooks users (issue #788)

Special Thanks

Special thank yous for this release goes to everyone in the discussions group for raising bug reports and their design discussions.

You rock!

murex - v5.3.7000

Published by lmorg 10 months ago

v5.3.7000

Features

  • None

Bug Fixes

  • object builder %{} was parsing bareword null as "null" (string with null) instead of a null value (issue #781)

  • variables were being tokenised in is-null parameters instead of being passed by reference (issue #781)

murex - v5.3.6000

Published by lmorg 10 months ago

v5.3.6000

Features

  • Copyright messages update for 2024

Bug Fixes

  • ANSI escape code for string terminations was updated to incorrect values in preview release. This has been fixed here
murex - v5.3.5000

Published by lmorg 10 months ago

v5.3.5000

bugfix release

Features

  • new runtime flag for managing cache: --flush-cache

Bug Fixes

  • Windows, Linux and Darwin (macOS) now default to GCO-less builds of sqlite3

  • ANSI escape code for window title changes changed from xterm-specific standard (BELL terminated) to ANSI standard (ST terminated)

  • integrations and default profile scripts have all be rewritten to follow latest Murex code style best practices

murex - v5.3.4000

Published by lmorg 10 months ago

Bugfix release:

v5.3.4000

Features

  • new runtime flags for managing cache: --cache and --trim-cache

Bug Fixes

  • cache: sqlite3 would lock cache.db, breaking caching when multiple murex sessions were open at a time

  • cache: cache.db wasn't getting set in config correctly (should have been enabled by default but was disabled by default instead)

murex - v5.3.3000

Published by lmorg 11 months ago

Caching has been vastly improved in this release due to a new sqlite3-backed persistent cache.db. There have also been some improvements to [f1] help pages.

Breaking Changes

None

Deprecation Warnings

Please read out compatibility commitment to understand how features are deprecated.

  • the ? pipe will be deprecated to make way for a the ternary operator. You can achieve the same result with <err> <!out>, eg command <err> <!out> parameters... | next-command ...

Features

  • persistent cache added using sqlite3 backend. This cache is optional however it is enabled by default. You can disable it by placing the following into your .murex_profile:

    config set shell cache.db-enabled false
    
  • new autocomplete directive for [f1] previews: DynamicPreview

  • dynamic previews added for git and aws

Bug Fixes

  • export now supports whitespace like an expression (issue #679)

  • bugfix: structures in variables would sometimes output base64 encoded values when converting those structures to arrays (issue #768)

  • some ReadArrayWithType() calls weren't handling the returned error (if there were an error). They're now all surfacing errors correctly

  • whats new message moved to shell Start()

Special Thanks

Special thank you to everyone in the community for raising bug reports and design discussions.

You rock!

murex - v5.2.7610

Published by lmorg 11 months ago

The v5.2 release introduces significant new features and improvements for those
using Murex as their interactive shell. Many of these features are unique to
Murex.

Breaking Changes

  • Change to experimental feature: all lambda variables now follow the $.k and $.v convention (read more)

  • Murex now requires Go compiler version 1.20 or above, however a C compiler is no longer required (though still supported)

  • expressions that return a boolean will no longer write true nor false to stdout if it is followed by a boolean operator (&& or ||). This is marked as a breaking change because some of Murex's tests had to be updated to reflect this update, however this change actually fixes a number of bugs around expectations for how boolean expressions should work

Deprecation Warnings

Please read out compatibility commitment to understand how features are deprecated.

  • the ? pipe will be deprecated to make way for a the ternary operator. You can achieve the same result with <err> <!out>, eg command <err> <!out> parameters... | next-command ...

  • experimental TTY buffer was removed. This was disabled by default, would create a slight slow down to rendering when enabled, created a few rendering glitches when enabled, added to the overall code complexity, and the primary use case for this no longer requires buffering anyway

Features

Features marked as EXPERIMENTAL are provided without assurances of future breaking changes. All other features are considered stable as part of Murex's compatibility commitment.

  • debug builtin now supports { ... } blocks (read more)

  • new flags for count: --sum / -s and --sum-strict

  • Lambda support for arrays and objects re-written and now considered stable (read more)

  • f9 command line preview added -- this feature allows you to quickly build and test pipelines that might otherwise require iterating on trial and error to get right

  • f1 autocomplete preview is no longer considered experimental. Several bug fixes included

  • new pipe: pty. This behaves similarly to a regular pipe except it creates a pseudo-TTY

  • f1 preview now includes cheat sheets from https://cheat.sh/

  • job control: builtins can now be stopped via ^z (issue #716)

  • docgen has seen several new features added to improve the ease of writing documentation for Murex

Bug Fixes

  • readline: fixed regression bug introduced in preview release where vim keys wouldn't write their updated state to the terminal

  • f1 preview now resets the cursor position correctly when closed

  • f1 preview has had autocomplete parameters rewritten to jump to the right man page flag more precisely

  • f1 preview scrolling had an off-by-one error resulting in the last line sometimes getting cropped

  • shebang (#!/path/to/murex) scripts should be loaded into a module namespace. This fixes module scoped config (read more)

  • command lines passed via -c flag (eg murex -c "out hello world") are also loaded into a module namespace

  • readline: trim whitespace before walking history

  • recommended optional builtins are now opt-out -- this is to make it easier to work with 3rd party package maintainers

  • job control: bug fixes around when to show and hide the interactive prompt (issue #716)

  • job control: processes invoked via bg {...} now support being brought to the foreground via fg (this could be argued as a new feature) (issue #716)

  • error handling added to get-type (read more)

  • boolean expressions, eg 2+3==5 now work with boolean operators (&&, ||). eg $USER == "bob" && out "Hello Bob".

Special Thanks

Special thank yous for this release goes to tiymat for their bug fixes and everyone in the discussions group for raising bug reports and design discussions.

You rock!

murex - v5.1.2210

Published by lmorg about 1 year ago

Breaking Changes

None.

Deprecation Warnings

Please read out compatibility commitment to understand how features are deprecated.

  • the ? pipe will be deprecated to make way for a the ternary operator. You can achieve the same result with <err> <!out>, eg command <err> <!out> parameters... | next-command ...

Features

Features marked as EXPERIMENTAL are provided without assurances of future breaking changes.

  • new operator: null-coalescing, returns the left-most non-null value (read more)

  • new operator: elvis returns the left-most non-falsy value (read more)

  • new builtin: is-null checks if a variable is undefined or null (read more)

  • new autocomplete: signal

  • error message for $1 variables, for when insufficient parameters passed, has been improved

  • website: minor stylesheet updates, plus some new images added

Bug Fixes

  • readline: buffered screen writes to reduce rendering glitches and improve overall responsiveness (issue #744)

  • autocomplete: gping autocomplete updated to support --color flag

Special Thanks

Special thank yous for this release goes to the following contributors:

  • tsmish for helping to debug some of readline's rendering glitches

You rock!

murex - v5.0.9310

Published by lmorg about 1 year ago

  • Minor bug fixes around JSON and YAML parsing (new feature for v5.0 table conversions)
  • bug fixes for automated tests and AUR builds
  • Downloads will now default to pure Go sqlite3 library (ie no CGO)
murex - v5.0.9200

Published by lmorg about 1 year ago

Breaking Changes

  • unquoted parameters that are formatted like [alpha, numeric, underscore]\(...\) will be parsed as a function rather than a string. eg command foo(bar baz) where foo will be treated as a subshell function with bar baz as its parameters
  • brace quotes without a leading % will be first parsed as an expression. eg %(valid string) vs (valid expression)

Deprecation Warnings

These are changes to Murex defaults, however you shouldn't expect any breaking changes to Murex's behaviour:

  • $ARGV now preferred instead of $ARGS ($ARGS will remain supported for now)
  • command: parameters ... style syntax has been deprecated in favour of the more traditional command parameters ... (without a colon) syntax.

Features

  • new website!!

  • commands can now be inlined in expressions, eg foobar = uptime() (issue 676)

  • commands can also be inlined into statements too, eg echo uptime() (issue 676)

  • new event onSignalReceived for catching OS signals

  • new builtin signal for sending OS signals

  • new builtins which (issue 609)

  • new builtin type (issue 609)

  • cd defaults to ~ if now parameters are passed (issue 672)

  • cd - changes to previous directory (issue 672)

  • $SELF.Interactive value to detect if scope is running in an interactive shell (issue 685)

  • $COLUMNS reserved variable to output width of terminal

  • $MUREX_ARGV reserved variable to output command line parameters of Murex shell (not to be confused with the parameters of the running function, eg $ARGV)

  • csv data type and select builtin now support converting maps (eg JSON objects) into tables (issue 689)

  • murex-doc / help can now display a greater number of documents when offline

  • improved man page parsing

  • improved man page displays in preview

  • alias now stores FileRef metadata (issue 124)

  • packages can now be removed via murex-package remove (issue 687)

  • a package creation wizard has been added via murex-package new

  • another new flag for murex-package: git. Which allows you to run git commands on a package even when you're not in that package's working directory

  • version constraints added to Murex packages (docs to follow)

  • readline: up and down arrows on a partial command line will cycle through history of only lines that contain your partial command line

  • readline: new hotkey, ctrl+z while readline is open will undo the previous key strokes

  • EXPERIMENTAL: logical operators added to expressions: || and && (issue 708)

  • EXPERIMENTAL: new command modifier <pid:VARNAME> sets $VARNAME with a commands process ID, if an external process (currently doesn't support local variables)

  • EXPERIMENTAL: new command modifier <fid:VARNAME> sets $VARNAME with the Murex function ID of the command (currently doesn't support local variables)

  • EXPERIMENTAL: new assignment operator :=, assigns a value but retains the former data type, thus converting the value when required (ideally I'd have preferred this as default option but it ran the risk of some serious and unexpected breaking changes to the behaviour of some existing shell scripts)

  • EXPERIMENTAL: Various builtins that require variable names now support $ sigils, eg foreach $var { ... } works as well as foreach var { ... }

  • EXPERIMENTAL: new variable group $MOD, like $GLOBAL but scoped to the module level

  • EXPERIMENTAL: official support added for a pure Go library for sqlite3 -- thus saving individuals from having to install gcc as well as go compilers. The reduced cgo footprint has already reduced file sizes by a 3rd

Bug Fixes

  • homebrew environment set on Intel macOS systems (previous only worked on ARM)
  • config functions (eg hint-text-func) now execute with the FileRef of the setter. Meaning they can call privates correctly
  • scalars fail expression pre-parser (issue 674)
  • readline: prompt can now span multiple lines (issue 612)
  • floating point numbers were not loosely compared correctly in expressions
  • readline: delay timer hint text should disappear when completed
  • $PWDHIST was corrupting upon first update
  • fixed bug with git-commit man page parsing, which caused the parser to hang and ramp up CPU usage on git autocompletions
  • fixed parsing of nested quotes inside curly braces (issue 697)
  • don't carry non-zero exit numbers forward if unit test successful
  • fixed instances where FileRef either wasn't being set, wasn't being set correctly, or was missing a timestamp (issue 696)
  • printf dependency removed from aliases function -- this means aliases now works on Windows too
  • || and && now parse correctly in expressions

Special Thanks

Special thank yous for this release goes to the following contributors:

  • orefalo for building the new website (which is now small task!), documentation fixes, and general support
  • tiymat for the high quality bug reports and beta testing
  • All the downstream package maintainers, who publish Murex to their preferred operating systems/package managers thus making it easier for a wider audience to install and update Murex

You rock!

murex - v4.4.9500

Published by lmorg about 1 year ago

v4.4.9500

Breaking Changes

None

Features

  • autocompletion: su integration for Linux

  • $GOPATH is no longer required to run unit tests

Bug Fixes

  • readline: paths wouldn't autocomplete on scalars (eg cd $GOPATH/...)

  • readline: previews wouldn't work against variables (eg vi ~/file.txt)

murex - v4.4.9100

Published by lmorg about 1 year ago

Resolves a regression bug: CTRL+A CTRL+E cursor position is off https://github.com/lmorg/murex/issues/664

murex - v4.4.9000

Published by lmorg about 1 year ago

v4.4.9000

Breaking Changes

None

Features

  • readline: f1 should work even outside of autocomplete

  • readline: wider preview pane

Bug Fixes

  • readline: fix preview wrapping on long lines

  • readline: image previews should scale to preview height

  • readline: better handling of terminal resizing

murex - v4.4.8000

Published by lmorg over 1 year ago

v4.4.8000

Breaking Changes

  • alt+1..9 hotkeys replaced with shift+f1..f12. Changed because alt+numeric rarely worked (read more)

Features

None

Bug Fixes

  • @IncManPages autocomplete value for Dynamic directive renamed to @IncManPage, like the IncManPage directive

  • readline: render glitch fixed with delayed completions racing against hint text updates

  • readline: render glitches fixed when buffers are not being reset correctly after preview box has, or should have, closed

  • readline: man page preview now removes backspace characters correctly from UNIX docs

  • readline: man page preview now more reliably scrolls to the right line when a flag is highlighted in autocompletion

  • readline: preview now works for list views as well as grid views

murex - v4.4.7000

Published by lmorg over 1 year ago

Breaking Changes

  • preview-enabled config option removed. This actually doesn't break anything, just produces a warning. The config option was also undocumented and experimental

Features

  • Preview is now considered stable. Press f1 while autocomplete is open to use (read more)

Bug Fixes

  • readline: render glitch fixed with delayed completions (most noticeable with path completions)

  • readline: excess white spaces removed from man page descriptions

murex - v4.4

Published by lmorg over 1 year ago

v4.4 features two new builtins, improvements in testing, and automatic generation of autocompletion suggestions backed by man page parsing. Plus there has been a lot of focus on improving readline responsiveness

Breaking Changes

  • 'Name' field dropped from onCommandCompletion interrupt (this field was never documented)

Features

  • New builtin, round, which can perform rounding operations on numerical inputs (#630, read more)

  • Vastly improved automatic man page parsing. Now descriptions are pulled alongside the flags and results are cached

  • man-get-flags now includes a -d / --description flag to expose the improved man page parser

  • New builtin, return, which exits a given function scope (eg function, private, Dynamic block in autocomplete, etc)

  • Improved git autocompletions

  • find autocompletions added

  • builtin profiles are now imported as separate modules. This makes debugging easier

  • /integrations directory added to Murex source, the aim of which is to make it easier for people to contribute autocompletions and other integrations with common command line tools (Github)

  • readline: new word jump hotkeys ctrl+left / ctrl+right (PC)

  • readline: new word jump hotkeys option+left / option+right (Mac)

Bug Fixes:

  • test would always run first in any block, regardless of the preferred order of execution. This was because test (unit|state|config) required altering the execution state of the shell. The drawback was that test (run|define|report) would also run unexpectedly. This lead to hacks like try { test run * } to force the correct order of operations. Now the parameters of test are checked to determine when to execute the builtin.

  • int types couldn't be compared against num types with >, >=, <, <= operators

  • readline: ^d will not send EOF if line is not empty. The original behaviour was by design however after pressing ^d a few too many times when I intended to press ^f or ^r, I decided the original design was wrong

  • FileRef wasn't being set in test. This caused some tests to fail if they called private functions

  • Check ~/.ssh/config exists before trying to parse it in getHostsFile private (used for SSH and similar tools autocompletions)

  • readline: lots of work done on speeding up redraws and overall responsiveness. eg buffered autocompletion menus

  • readline: hint text should never be displayed if disabled via config

  • readline: soft timeout halved (this can be overridden via config)

  • readline: cropped autocompletion suggestions in gridded layout were one character too short (off by one error)

murex - v4.3.3200

Published by lmorg over 1 year ago

Breaking Changes

  • pre-prompt-func and post-prompt-func have been replaced with onPrompt events: event onKeyPress example=before { ... }

  • The onFileSystemChange event payload now lowercases the filesystem event operation string. However until this release, that payload was undocumented (read more)

Features

  • New events, onPrompt, triggered when the interactive prompt is at various stages

  • Dynamic and DynamicDesc autocompletions can have their partial term prefix filter disabled (read more, previous discussion)

  • New autocompletions: gping

Bug Fixes:

  • Improved Windows support. Arrow keys and other special keys are now handled correctly (#630)

  • Fix ctrl+a offset by 1 error (#628)

murex - v4.2.5110

Published by lmorg over 1 year ago

A minor patch to re-enable tab completion on commands

murex - v4.2.5000

Published by lmorg over 1 year ago

Murex usage has raised considerably in recent weeks. This release addresses a number of feature requests and bugs raised on Github.

Breaking Changes

none

Features

  • new flag in foreach: --step <int>. This allows the foreach to jump indexes at a time. When used, all the lines jumped are merged into a JSON array and that is passed to the foreach nested code block

  • new alias builtin => fexec builtin. This was added to bring more familiarity to those coming from Bash et al (#608)

  • on Darwin, Homebrew defaults are imported, just like you'd expect them to be from any other shell

  • aa few new hotkeys (#611) (#613):

    1. ctrl+a: jump to beginning of line

    2. ctrl+e: jump to end of line

    3. alt+f: jump forwards a word at a time

    4. alt+b: jump backwards a word at a time

    5. ctrl+k: clear line after cursor position

    6. ctrl+l: clear entire screen

    7. ctrl+g: same as esc

  • `open`` builtin should fallback to system default if type unknown (#620)

  • pre-prompt-func added to config. Block runs before the interactive prompt is displayed

  • post-prompt-func added to config. Block runs after the interactive prompt has been exited but before any command lines have been executed

  • auto-cd option added to config: config: set shell auto-cd true. This allows you to traverse directories without having to prefix cd. By default it is disabled

  • Meta values added to foreach, formap, and while. Meta values are a $. variable that holds meta-information about the running block, such as the number of iterations in a loop

  • command alias for exec (for familiarity with Bash)

  • builtin alias for fexec builtin (for familiarity with Bash)

Bug Fixes:

  • brace encapsulated variables, eg $(foobar), now autocomplete as expected

  • improvements to inlining images in iTerm2 when shell running on top of tmux. It still doesn't work reliably but this is an issue with tmux rather than Murex

  • method forwards exceptions rather than errors. This behaviour has been changed to surface issues as errors

  • profile_preload.mx added to profile defaults. This will be loaded before any of the OS-specific profiles

  • missing rune length check causing the shell to panic (#617)

  • fixed deadlock in flag parsing

  • zero length string title bars should be ignored (#614)

  • minor improvements to documentation

murex - v4.1.7300

Published by lmorg over 1 year ago

The previous releases have brought significant advancements to Murex's syntax but at the cost of longer gaps between releases. So the 4.1.x versions will be shorter releases but focusing on bug fixes. The 4.1.x release notes will be appended to murex.rocks changelog and available on Github releases too

v4.1.7300

Breaking Changes

None

Features

  • generic * data type marshaller can now marshal maps (#593)

  • range can count from end when supplied with a negative index (read more)

Bug Fixes

  • fexec private should inherit module string from the owners module (#600)

  • source-ed files should be loaded into a module of a similar name to the parent module

  • new code blocks, {, should force a new parameter when following a closing block, } (#603)

  • fixed problem with encapsulated variables, eg $(PWD), not getting parsed correctly by syntax highlighter