3 Commits

4 changed files with 17 additions and 28 deletions

View File

@@ -1,13 +0,0 @@
kind: pipeline
name: default
steps:
- name: Publish
image: plugins/pypi
settings:
username:
from_secret: pypi_username
password:
from_secret: pypi_password
when:
event: tag

View File

@@ -1,7 +1,5 @@
# Bopytex
[![Build Status](https://drone.opytex.org/api/badges/lafrite/Bopytex/status.svg)](https://drone.opytex.org/lafrite/Bopytex)
Bopytex is a command line tool for producing random math exercises with their correction. It embeds [mapytex](https://git.opytex.org/lafrite/Mapytex) and [python](python.org) into [latex](latex-project.org) through [jinja](jinja.pocoo.org).
## Installing

View File

@@ -11,8 +11,8 @@ import logging
from pathlib import Path
import pytex
#from mapytex import Expression, Integer, Decimal, random_list
import mapytex
from mapytex import Expression, Integer, Decimal, Polynomial, render
import sympy
import bopytex.filters as filters
formatter = logging.Formatter("%(name)s :: %(levelname)s :: %(message)s")
@@ -25,16 +25,20 @@ logger.addHandler(steam_handler)
def setup():
mapytex.Expression.set_render("tex")
logger.debug(f"Render for Expression is {mapytex.Expression.RENDER}")
render.set_render("tex")
logger.debug(f"Render for Expression is {render.render}")
mapytex_tools = {
"Expression": mapytex.Expression,
"Integer": mapytex.Integer,
"Decimal": mapytex.Decimal,
"random_list": mapytex.random_list,
"random_pythagore": mapytex.random_pythagore,
"Dataset": mapytex.Dataset,
"WeightedDataset": mapytex.WeightedDataset,
"Expression": Expression,
"Integer": Integer,
"Decimal": Decimal,
"Polynom": Polynomial,
"sympy": sympy,
# "Fraction": mapytex.Fraction,
# "Equation": mapytex.Equation,
# "random_str": mapytex.random_str,
# "random_pythagore": mapytex.random_pythagore,
# "Dataset": mapytex.Dataset,
# "WeightedDataset": mapytex.WeightedDataset,
}
pytex.update_export_dict(mapytex_tools)
@@ -155,7 +159,7 @@ def crazy_feed(*args, **kwrds):
def clean(directory):
pytex.clean(directory)
pytex.clean(directory, ["*.aux", "*.log", "*.out", "*.xsim", "*.tkzfonct.*"])
def texcompile(filename):

View File

@@ -5,7 +5,7 @@ from setuptools import setup
setup(
name='Bopytex',
version='0.2',
version='0.1.2',
description='Command line tool for compiling latex with python command embedded',
author='Benjamin Bertrand',
author_email='programming@opytex.org',