Skip to content

Omasheet 0.1.12

Latest

Choose a tag to compare

@librasteve librasteve released this 16 Nov 10:04
· 6 commits to main since this release

Omasheet v0.1.12

Omasheet 0.1.8 to 0.1.12: what changed since 0.1.7

Five releases in a week. Numbers now carry units, Decimal has a scale and Fraction is exact, windowed columns run in Polars, Boolean has formats and logic, every file has built-in constants, and Omasheet installs on macOS and Windows as well as Omarchy and Arch Linux.

Install or update

On macOS (Apple silicon or Intel) and on Omarchy and Arch Linux (x86_64 or aarch64):

curl -fsSL https://raw.githubusercontent.com/librasteve/omasheet/main/install.sh | bash

On Windows (64-bit), in PowerShell:

irm https://raw.githubusercontent.com/librasteve/omasheet/main/install.ps1 | iex

The macOS app and the Windows build are not code-signed. The installers fetch them in a way that avoids the Gatekeeper and SmartScreen warnings; a zip downloaded by hand will show them.

Units

  • SI units in cell text. 5kg, 300cm, 20°C, 9.81m.s^-2, 45°30′30″. A sum or a comparison converts the right side to the unit of the left (5kg + 300g is 5.3kg); a product or quotient combines the units; two dimensions that do not match are an error that says so. 5kg.to('g') converts, and x.unit() and x.value() take a quantity apart: 5kg.unit() is kg, and x.to('g').value() is its number of grams.
  • Prefixes. All the SI prefixes work on every unit, and a prefix and a . alone is a scale: 1k. is 1000. The bit b and the byte B take the binary prefixes too (KiB is 1024 B), and Data, DataRate and DataDensity columns can be shown in any of them.
  • Metric units that are not SI, each an exact multiple of an SI unit: the litre l (also L), the tonne t, the hectare ha, the bar, the electronvolt eV, the calorie cal, the watt-hour Wh and the dalton Da. None of the imperial ones.
  • Angles and time. rad is the base unit, with sr, lm and lx, and °, ′ and ″. sin, cos and tan take an angle in any unit, and arcsin, arccos and arctan give back rad. A quantity of time can be added to a time, date or date-time (17:05:00 + 10s).
  • Columns. A column can have a quantity type, Weight : Mass, and a unit and number format in the brackets, Weight : Mass[g; .1f]. A cell in another unit of the same kind is converted, a bare number is read in the column's unit, and a cell of another dimension is an error. sum, mean, min, max and median keep the unit.
  • Uncertainty. 10.5(3)e-3kg and 5kg ± 100g carry their uncertainty through arithmetic. A Scientific has the same notation without a unit.
  • Parquet. A quantity column is a struct of value, uncertainty and unit, with its kind kept so it opens as the same type. CSV and JSON write the text (5kg); an XLSX export writes text and says the unit is dropped. Importing a CSV, JSON or XLSX never turns text like 12g into a quantity.
  • The units come from siquant, a Rust crate of SI units and prefixes (github.com/librasteve/siquant), which is vendored in the repository.

Exact numbers

  • Fraction is an exact rational of arbitrary-precision integers, always reduced: a googol at one end and 1 over a googol at the other. It is written 1/7 in a cell and <1/7> in an expression, shown as 1/3 or 2 1/3, and it never lowers to Polars. A sequence seeded with whole numbers and fractions steps exactly: 1, 1/3 goes down by 2/3, not by 0.667.
  • Everything else lowers to Polars, including / and mean over a Decimal, so a column of money is computed by the dataframe and not cell by cell. Where a product might overflow Polars' intermediate, the engine falls back to the exact path and gives the true answer.
  • Decimal(n) is a column type, and an undeclared column takes the smallest scale that holds every cell, up to 18 places, and Fraction past that. Mixed scales work exactly: Decimal(a) beside Decimal(b) is Decimal(max(a, b)). A declared column given more places than it keeps is refused, cell by cell, with the type that would hold it.
  • Interchange. Parquet writes a Fraction as a struct of two strings, num and den, with its kind in the file's metadata, and --decimal writes the nearest Decimal or Float64 instead and says what was cut. CSV and JSON write 1/3 as text, and XLSX the rounded double with a note.

Windowed columns

cum_sum, diff, pct_change, rank, forward_fill, backward_fill and the rolling_ family (rolling_sum, rolling_mean, rolling_min, rolling_max, rolling_std) run in Polars, over Decimal as well as Integer and Float, with by to partition: Amount.cum_sum(by Account), Amount.diff(1, Date by Account), Score.rank(min, desc by Region). See docs/expressions.md.

Booleans, complex numbers and built-in constants

  • Boolean columns take display formats, including symbol formats such as ✓✗, and there are logic functions and gate operators. Booleans are set right in the grid. See examples/booleans.omx.
  • Complex has re, im, conj and arg, with abs, sqrt, exp, ln, the logarithms and the inverse trigonometric and hyperbolic functions, and a column of complex results is typed Complex. i is a built-in constant: 3 + 4 * i is 3+4i.
  • Built-in constants every file has: pi, tau, e, i, the speed of light c, standard gravity gn, planck, hbar, kB, NA, R, qe, G and me, as the 2019 SI defines the exact ones and CODATA 2022 the rest. A constant of the same name in the file wins. The app lists them after the file's own, greyed; they cannot be edited or deleted.
  • A format for constants. consts [; .10s] before the first sheet is the number format the constants' values are shown by, set from Set format… on the Constants tab. Without the line they use the default format.

In the app

  • Type and unit pickers. Set type opens a picker grouped by domain, with a live check, and a unit picker for quantity columns. Set format works like the filter box: a legend of examples, checked as you type, and a short reason in red when it is wrong. F4 cycles the Set panels.
  • Whole columns carry their type. Copying or cutting whole columns and pasting them onto whole columns brings the type, unit and format with them. Paste format in the column menu pastes only those, and no values.
  • Copy values, selectable error messages, a draggable filter popup, a Clear filter button, filter undo, a summary that honours filters, and a cell editor that spills past the last column.
  • Windows: the app starts no console window, uses Consolas for the grid, shows its symbols correctly, and carries the Omasheet icon on the executable, the Start menu shortcut, .omx files and the Apps & features entry. Run from PowerShell or cmd, the omasheet command still prints there, though the prompt may return before its output appears.

Installers and packaging

  • macOS and Windows installers (0.1.9). On macOS Omasheet.app goes into /Applications and omasheet is linked into /usr/local/bin; the app carries its own Qt. On Windows it installs to %LOCALAPPDATA%\Programs\Omasheet with no administrator rights, adds a Start menu entry, opens .omx files, puts omasheet on your PATH, and lists itself in Apps & features with an uninstaller.
  • Every release attaches the Arch packages (x86_64 and aarch64), the macOS zips (arm64 and x86_64) and the Windows zip, all checksummed and attested, and the Omarchy package is checked against the tag's source.
  • Fixed since 0.1.9: the macOS installer stopped at "not what SHA256SUMS says it should be" on a Mac whose own sha256sum has no --check; it uses shasum now.
  • The agent skill for Claude Code, skill/omasheet/SKILL.md, is installed to /usr/share/omasheet/agent-skill/omasheet/, and the package prints the command that links it into Claude Code. omasheet-md renders documents from sheets with the same displays as the grid, and docs/ and the README are up to date.

Known issues

  • Double-clicking an .omx in Finder may not open it; omasheet file.omx does.
  • The dateformats example differs on a machine whose locale writes AM and PM where the example expects a.m. and p.m..

By release

0.1.8 SI units, data, angles and time, uncertainty, complex functions, three-place display, type and unit pickers, whole-column paste
0.1.9 macOS and Windows installers, Boolean formats and logic, paste format fix
0.1.10 Decimal(s) with a column scale, exact Fraction, windowed columns in Polars, quantity formats, unit() and value(), metric non-SI units, constants format; code formatting for CI
0.1.11 macOS installer checksum fix, Windows font, exact powers and fraction sequences, built-in constants in the app
0.1.12 Windows symbols and no console window, Windows icon, i, a unit after a constant