As a DRAGON/DONJON user, you want to look inside a LCM
object, such as
LINKED_LIST
, SEQ_ASCII
or XSM_FILE
.
The simplest way to do this is to convert your object into XSM_FILE
or SEQ_ASCII
format
SEQ_ASCII mySeqFile ; mySeqFile := myLCMObject ;
perform calculation and open the resulting output file with asciiviewer.
The initial version of asciiviewer was written by Benjamin Toueg in 2009 and is available here.
Here, the original source code was ported to run on both python 2 and 3 with wxpython 4. Single file executables are generated with pyinstaller using these workflows via github actions.
The easiest way to run asciiviewer is to download the executable from releases as shown in the demo. Otherwise set it up manually.
First step is to install miniconda which requires no admin priviledges.
Open a new terminal and clone or download the project
$ git clone https://github.com/tumregels/asciiviewer
Now cd
into the project folder, create a conda environment and activate it
$ cd asciiviewer
$ conda env create -f environment.yml
$ source activate asciiviewer
At this point execute asciiviewer
command
(asciiviewer) $ asciiviewer
or
(asciiviewer) $ python asciiviewer/main.py
on MacOS you need to use pythonw
(asciiviewer) $ pythonw asciiviewer/main.py
To open a specific DRAGON/DONJON output file from the command line
(asciiviewer) $ asciiviewer ./path/to/file
To generate the single file executable on your computer
(asciiviewer) $ pyinstaller --clean --noconfirm ./asciiviewer.spec
The above step will create an executable under the dist
folder.
$ ./dist/asciiviewer ./path/to/file
Important: single file executables can be called from terminal with or without file path.
For development setup first implement the manual setup followed by
(asciiviewer) $ python -m pip install -r requirements-dev.txt
To get a detailed traceback set PYTHONFAULTHANDLER
. On MacOS and Linux
(asciiviewer) $ export PYTHONFAULTHANDLER=1
To release a new version execute
(asciiviewer) $ bump2version minor
Above command will update the minor release version, create a git tag and a commit. Now push the git tag and the commit with
(asciiviewer) $ git push --follow-tags
On the first run asciiviewer will create an .asciiviewer.cfg
config file inside
HOME
directory with this content.
From this file you can disable sort and splash screen.
Any problems or bugs should be reported here.
-
The asciiviewer executables are not signed and you will get warnings on MacOS and Windows.
-
The program may crash unexpectedly when used with big files.
-
On ubuntu, during manual setup, you may get
missing libgtk-x11-2.0.so.0
error. One solution is to reinstalllibgtk2.0
library$ sudo apt-get install --reinstall libgtk2.0-0