Discussion
Loading...

Post

  • About
  • Code of conduct
  • Privacy
  • Users
  • Instances
  • About Bonfire
Giovanni Crisalfi
@gicrisf@fosstodon.org  ·  activity timestamp 2 weeks ago

After several months, I'm finally sharing the first pre-release of Emacs Indigo, a native #Emacs module that brings the #Indigo #cheminformatics library to Emacs #Lisp.

It's now at a point where the core functionality is solid enough to share. (1/7)

  • Copy link
  • Flag this post
  • Block
Giovanni Crisalfi
@gicrisf@fosstodon.org replied  ·  activity timestamp 2 weeks ago

The package provides Emacs Lisp bindings through a native C module.

You can work with molecules directly in Emacs: load structures, convert formats (SMILES, MOL, CML), calculate properties, perform substructure matching, and render visualizations (both in PNG and SVG, yes). (2/7)

  • Copy link
  • Flag this comment
  • Block
Giovanni Crisalfi
@gicrisf@fosstodon.org replied  ·  activity timestamp 2 weeks ago

Memory management is handled automatically through `indigo-let*`, a resource management macro that takes care of cleanup when working with persistent molecule handles

(3/7)

```elisp
(indigo-let* ((:molecule mol "CCO")
                      (:atoms atoms mol))
  (indigo-map #'indigo-symbol atoms))
;; => ("C" "C" "O")
```
```elisp (indigo-let* ((:molecule mol "CCO") (:atoms atoms mol)) (indigo-map #'indigo-symbol atoms)) ;; => ("C" "C" "O") ```
```elisp (indigo-let* ((:molecule mol "CCO") (:atoms atoms mol)) (indigo-map #'indigo-symbol atoms)) ;; => ("C" "C" "O") ```
  • Copy link
  • Flag this comment
  • Block
Giovanni Crisalfi
@gicrisf@fosstodon.org replied  ·  activity timestamp 2 weeks ago

Current implementation of Emacs Indigo provides:

- Core molecular operations (properties, calculations, format conversions)

- Iterator system for structure traversal (atoms, bonds, rings, stereocenters)

- Rendering and visualization (SVG, PNG output)

- Reaction handling and atom mapping

- Format support: SMILES, MOL, CML, reaction SMILES

(4/7)

  • Copy link
  • Flag this comment
  • Block
Giovanni Crisalfi
@gicrisf@fosstodon.org replied  ·  activity timestamp 2 weeks ago

The installation aspect of Emacs Indigo was a key focus: finally, I reduced it to a simple one-liner that only requires GCC/Make and an Emacs installation with module support.

The build system handles Indigo dependencies automatically (on Linux, at least). (5/7)

  • Copy link
  • Flag this comment
  • Block
Giovanni Crisalfi
@gicrisf@fosstodon.org replied  ·  activity timestamp 2 weeks ago

I'm currently working on a lazy stream abstraction for idiomatic iterator handling, avoiding the need to eagerly copy results into temporary Emacs lists.

I can't wait to show the results, to be honest. (6/7)

A picture of my whiteboard right now. In the image, a handwritten draft of my lazy stream for Emacs Indigo.
A picture of my whiteboard right now. In the image, a handwritten draft of my lazy stream for Emacs Indigo.
A picture of my whiteboard right now. In the image, a handwritten draft of my lazy stream for Emacs Indigo.
  • Copy link
  • Flag this comment
  • Block
Log in

bonfire.cafe

A space for Bonfire maintainers and contributors to communicate

bonfire.cafe: About · Code of conduct · Privacy · Users · Instances
Bonfire social · 1.0.0 no JS en
Automatic federation enabled
  • Explore
  • About
  • Members
  • Code of Conduct
Home
Login