add adists with rubar3 + rubar3 in release

This commit is contained in:
Theophile Terraz committed 2026-02-23 10:46:05 +01:00
1 parent 118a39bd5c
commit 18a3d51d75
6 files changed
+408 -16

No files matched your search

+46 -7
View File
@@ -37,7 +37,7 @@ logger = logging.getLogger()
class Config(SQL):
def __init__(self):
self._version = '0.0.6'
self._version = '0.0.7'
self.filename = Config.filename()
self.set_default_value()
@@ -101,6 +101,7 @@ class Config(SQL):
# Add default solver
posix = os.name == 'posix'
ext = "" if posix else ".exe"
path = os.path.join("@install_dir", "mage8", f"mage{ext}")
self.execute(f"""
INSERT INTO solver VALUES (
@@ -111,7 +112,7 @@ class Config(SQL):
'', '', '',
'',
'@install_dir/mage/mage{ext} @args @input',
'{path} @args @input',
''
)
""")
@@ -135,16 +136,19 @@ class Config(SQL):
if int(release) < 5:
posix = os.name == 'posix'
ext = "" if posix else ".exe"
path = os.path.join("@install_dir", "mage8", f"mage{ext}")
self.execute(
"UPDATE solver SET cmd_solver=" +
f"'@install_dir/mage8/mage{ext} @args @input' "
f"'{path} @args @input' "
"WHERE name='default-mage'"
)
if int(release) < 6:
posix = os.name == 'posix'
ext = "" if posix else ".exe"
path = os.path.join("@install_dir",
"adists", f"adists{ext}")
self.execute(f"""
INSERT INTO solver VALUES (
@@ -155,16 +159,41 @@ class Config(SQL):
'', '', '',
'',
'@install_dir/adists/adists{ext} @args @input',
'{path} @args @input',
''
)
""")
self.execute(
"UPDATE solver SET cmd_solver=" +
f"'@install_dir/adists/adists{ext} @args @input' "
f"'{path} @args @input' "
"WHERE name='default-AdisTS'"
)
if int(release) < 7:
posix = os.name == 'posix'
ext = "" if posix else ".exe"
path = os.path.join("@install_dir",
"rubar", f"rubar3{ext}")
self.execute(f"""
INSERT INTO solver VALUES (
'rubar3',
'default-Rubar3',
'Default Pamhyr2 Rubar 3 version',
'', '', '',
'',
'{path} @args @input',
''
)
""")
self.execute(
"UPDATE solver SET cmd_solver=" +
f"'{path} @args @input' "
"WHERE name='default-Rubar3'"
)
self.execute(
f"UPDATE info SET value='{self._version}' " +
"WHERE key='version'"
@@ -327,14 +356,24 @@ class Config(SQL):
ctor = solver_type_list["mage8"]
new = ctor("default-mage")
new._description = "Default Pamhyr2 mage 8 version"
new._cmd_solver = f""""@install_dir/mage8/mage{ext}" @args @input"""
path = os.path.join("@install_dir", "mage8", "mage")
new._cmd_solver = f""""{path}{ext}" @args @input"""
self._solvers.append(new)
# AdisTS
ctor = solver_type_list["adistswc"]
new = ctor("default-AdisTS")
new._description = "Default Pamhyr2 AdisTS version"
new._cmd_solver = f""""@install_dir/adists/adists{ext}" @args @input"""
path = os.path.join("@install_dir", "adists", "adists")
new._cmd_solver = f""""{path}{ext}" @args @input"""
self._solvers.append(new)
# Rubar3
ctor = solver_type_list["rubar3"]
new = ctor("default-Rubar3")
new._description = "Default Pamhyr2 Rubar 3 version"
path = os.path.join("@install_dir", "rubar", f"rubar3{ext}")
new._cmd_solver = f""""{path}" @args @input"""
self._solvers.append(new)
# Mage fake 7