asciidoctor / asciidoctor-extensions-lab

A lab for testing and demonstrating Asciidoctor extensions. Please do not use this code in production. If you want to use one of these extensions in your application, create a new project, import the code, and distribute it as a RubyGem. You can then request to make it a top-level project under the Asciidoctor organization.
Other
104 stars 101 forks source link

mathoid-treeprocessor and new versions of mathoid #105

Closed michaelpj closed 8 months ago

michaelpj commented 5 years ago

I was trying out the mathoid-treeprocessor with a new version of mathoid. Two things:

I can submit a PR for the former issue, but I'm not sure whether you're happy to say that people should use a newer version of mathoid than the one listed in setup.sh.

I know no Ruby, so I can't easily tackle the second one, but maybe someone else is interested.

mojavelinux commented 5 years ago

This extension hasn't worked in quite some time, and there's certainly no reason to stick with the version that's there. But what I want to see happen is for this extension to graduate from the extensions lab. I don't think it's a good idea to be developing it in here since it's really beyond the scope of an experiment.

What I'd like to see happen is for it get set up as a RubyGem like asciidoctor-mathematical. Then, we'll move that into the Asciidoctor organization and deprecate / remove the code that's here. In order for that to happen, though, tests are a hard requirement.

Use whatever you need to use to get it working. Right now, it's not usable, so there's really nothing to preserve.

I'm happy to assist, but it's not something I can take on myself right now. What I can say for sure is that there is a strong need for it because mathematical has proven too difficult to install for most.

michaelpj commented 5 years ago

Okay, thanks. Having never written any Ruby I'm not up to setting up a proper gem anytime soon, but I'll try and hack something together for my uses and let you know how it goes.

FWIW I didn't find mathematical hard to install, but its rendering was terrible. It misrendered many symbols, and had pretty limited support. I'm much more excited about using MathJax, which I've historically found to be very good.

cavity-dump commented 8 months ago

This extension has worked flawlessly for me for many years ... and still does ! I now see that mojavelinux has removed it from the repo. :-( Maybe someone is willing to reinstate it, but if not you can still run it. :-) This worked for me on a new Ubuntu 23.10: sudo apt install asciidoctor sudo apt install librsvg2-dev wget -O- https://raw.githubusercontent.com/creationix/nvm/master/install.sh | bash nvm install 10 wget -O archive https://github.com/asciidoctor/asciidoctor-extensions-lab/archive/0646a20906d27bc9f92c7050e8127cee85d816c7.zip unzip archive rm archive mv asciidoctor-extensions-lab-0646a20906d27bc9f92c7050e8127cee85d816c7 asciidoctor-extensions-lab wget https://gitlab.wikimedia.org/repos/mediawiki/services/mathoid/-/archive/main/mathoid-main.zip unzip mathoid-main rm mathoid-main.zip cd mathoid-main npm install export MATHOID_HOME=$(pwd) echo "export MATHOID_HOME="\"$MATHOID_HOME\">>~/.profile cd ../asciidoctor-extensions-lab/lib/mathoid-treeprocessor mv mathoid-config.yaml mathoid-config.yaml_bak cp $MATHOID_HOME/config.yaml ./mathoid-config.yaml ruby mathoid.rb test > test.svg

if you can see the test.svg you succeded !

mojavelinux commented 8 months ago

If you want to continue using this extension, I encourage you to pull it out and put it into a new repository. I removed it from here because it is untested and unmaintained and I have no plans to update it. However, it's open source and you can do with it whatever you like, whether it be to fork it or just copy it locally.