Skip to content

Releases: abs-lang/abs

v1.1.0

02 Feb 14:01
Compare
Choose a tag to compare

Plenty of new features in this new release of ABS!

We wanted to deliver a few more things with 1.1.0 (such as parallel commands) but considering we already have a whole bunch of new features lined up we decided to release now rather than waiting for a couple additional features that might take a few more weeks. As a result of this, we created the 1.2.x milestone and moved all pending issues there.

Let's go through the most notable changes in this release!

New features

  • added a sleep(ms) function which halts the scripts for a duration, specified in milliseconds (#158)
  • in, the membership test operator, now supports searching keys in hashes (#154)
  • in, the membership test operator, now supports searching for a substring in a string (#148)
  • ~, the similarity operator, now supports numbers: a number is similar to another one if their integer representation is the same (1.23 ~ 1 # true) (#140)
  • you can now loop through hashes uses for k, v in hash { ... } (#139)
  • destructuring now supports hashes: some, key = {"some": 1, key: 1} (#151)
  • you can now trigger system commands both with $(command) and `command`. This allows less verbose code such as `ls -la`.ok which is not possible with $(ls -la) as the command needs to be on its own line (#41)
  • added a few builtin functions on hashes: keys(), values(), items() and pop(key) (#147)

Bugfixes

  • null == null # false (#152)
  • assignments to array / hash indexes (x[0] = 1 and x.key = 1) are now supported (#141)

Documentation

  • added a whole bunch of swag in the README of the project (#137)
  • added contributing guidelines to help those who want to hack on ABS (#159)

v1.0.2

02 Feb 13:35
Compare
Choose a tag to compare

This is a bugfix release that addresses a regression causing null values to return false when compared:

null == null # false

#160 fixes the issue:

null == null # true

v1.0.1

27 Jan 20:00
Compare
Choose a tag to compare

This is a bugfix release that addresses regression #135, introduced by #133: under particular circumnstances, parsing of if...else blocks would skip a token in the parser, leading to parsing errors.

v1.0.0

26 Jan 15:43
Compare
Choose a tag to compare

ABS 1.0.0 is here!

After loads of sweat and tears, we finally decided it was time to release our first major release to be considered stable. We now exit the preview-n versioning scheme and finally enter semantic versioning, where every ABS release will be versioned according to whether we break backwards compatibility (major, X.y.z), add new features (minor, x.Y.z) or fix bugs (patch, x.y.Z).

Enough with the chatter, let's have a look at what's in ABS 1.0.0!

New features

  • the in operator, used to check whether an element is in an array: 1 in 1..10 # true (#128)
  • else if is now available: we were previously limited to if .. else blocks, while ABS now fully supports if...else if...else if...else (#27)

Bug fixes

  • .json() can now be called on all strings that represent a JSON type, such as "null" or "[1, 2, 3]" (#54)
  • just like in a lot of other major programming languages, ABS strings now support special characters such as \n. If you use double quotes these characters will be converted to their ASCII control codes, whereas if you use single quotes the literal \n will appear. This is implemented for \n, \r and \t. Try it out with [1,2,3].join("\n") (#130)

Deprecations

  • [].contains(x) is now deprecated in favor of the in operator (very similar to Python's in). [].contains will continue to work until the next major release

Thanks

A big thank you to @ntwrick who managed to implement #130 which was pending for quite some time. Without his help, it would have taken a while longer to get 1.0.0 out of the way :)

Preview 4

22 Jan 17:55
Compare
Choose a tag to compare
Preview 4 Pre-release
Pre-release

Loads of changes over the past 2/3 weeks so we decided to release an additional version before 1.0!
Note that we have dropped the netbsd and freebsd builds for now, but are happy to re-instate them if requested to do so.

New features

  • the biggest news is that now ABS returns debug information when errors happen, helping you locate a line that
    caused an error (#121). Many thanks to @ntwrick for his amazing work!
⧐  [1, 2, 3].not_found()
ERROR: ARRAY does not have method 'not_found()'
	[1:10]	[1, 2, 3].not_found()
  • you can now access CLI flags (eg. abs script.abs --foo=bar) with flag("foo") (#79)
  • both single and double quotes are now supported in strings (#110)
  • ABS will output its version when called with abs --version (#97)
  • added the "string".is_number() function (#103)

Bigfixes

  • shell commands wouldn't receive the stdin from the abs process (#113)
  • fixed a bug in for ... in loops that wouln't allow to iterate more than once on an array (#112)

Preview 3

29 Dec 12:06
Compare
Choose a tag to compare
Preview 3 Pre-release
Pre-release

Loads of interesting fixes made it to this release, with the addition of a few features as well.

Backwards-incompatible changes

Array destructuring has now abandoned the JS form ([x, y] = [1, 2]) and follows a leaner syntax (x, y = [1, 2]).

New features

  • bitwise operators &, |, ^, >>, <<, ~ (#84)

Fixes

  • null is now an "assignable" value. Earlier on, you couldn't x = null, which resulted in funny behaviors such as #85
  • numbers are not following scientific notation: for very large numbers, the formatter used to convert them to something like 1e+06. This has been now fixed.
  • fixed a panic when using .map(...) without return values (#62)
  • fixed a panic when calling functions without enough arguments (#61)
  • beautified a panic when trying to execute a script that does not exist (#77)
  • beautified a panic when trying to execute .sum() on an array with elements other than numbers (#75)
  • fixed error handling in .map() and .filter() (#80)
  • fixed script halting when there was an error in a while block (#82)
  • added \r and \f as a separator for .lines()
  • strengthened the command parser (#78)
  • fixed shell command escaping (#81)
  • destructuring statements do not need a ; on the preceding line anymore (#83)

Other changes

  • setup travis-ci tests on win, osx, linux (#88)

Preview 2

26 Dec 14:21
Compare
Choose a tag to compare
Preview 2 Pre-release
Pre-release

Loads of bugfixes and new features in this release, which beefs up the language getting ready for a stable release (next release will be all about bugfixes in order to release a stable version).

Highlights

  • floats: now fully supported, so you can 1.1 + 1 as well as "{x: 1.12}".json() and so on!
  • ability to read stdin: you can read a line with stdin() or loop through it with for input in stdin {}
  • compound assignments: +=, -=, etc
  • modulo operator
  • ability to format strings without printing them with str.fmt(x, y, z)
  • array destructuring: [x, y] = [1, 2]
  • errors now terminate ABS scripts with exit code 99 -- got problems?

Happy hacking!

Preview 1

25 Dec 00:09
Compare
Choose a tag to compare
Preview 1 Pre-release
Pre-release

Lot's of things made it into this release -- the amount of issues worked on is exceptional and allows us to deliver .

Notable features that made it in this release:

...and many other things. This release, for example, adds support for <= and >= as well, though basic language features won't be highlighted on these release notes; the best place is the documentation which won't take more than 10 minutes of your time.

Try ABS out with a simple:

sh <(curl https://www.abs-lang.org/installer.sh)

Cheers!

Preview 0

23 Dec 10:11
Compare
Choose a tag to compare
Preview 0 Pre-release
Pre-release
preview-0

renamed file