Fixed LibreOffice installations
This commit is contained in:
parent
3bb2100dcd
commit
a9c874d79e
1 changed files with 5 additions and 5 deletions
|
|
@ -235,10 +235,9 @@ def install_libreoffice(
|
|||
use_mso_formats=False, vcredist=False):
|
||||
"""Install LibreOffice using specified settings."""
|
||||
cmd = [
|
||||
r'{}\Installers\Extras\Office\LibreOffice.msi'.format(
|
||||
'msiexec', '/passive', '/norestart',
|
||||
'/i', r'{}\Installers\Extras\Office\LibreOffice.msi'.format(
|
||||
global_vars['BaseDir']),
|
||||
'/qn',
|
||||
'/norestart',
|
||||
'REBOOTYESNO=No',
|
||||
'ISCHECKFORPRODUCTUPDATES=0',
|
||||
'QUICKSTART={}'.format(1 if quickstart else 0),
|
||||
|
|
@ -249,11 +248,12 @@ def install_libreoffice(
|
|||
cmd.append('REGISTER_ALL_MSO_TYPES=1')
|
||||
else:
|
||||
cmd.append('REGISTER_NO_MSO_TYPES=1')
|
||||
xcu_file = r'{APPDATA}LibreOffice\4\user\registrymodifications.xcu'.format(
|
||||
**global_vars)
|
||||
xcu_dir = r'{APPDATA}\LibreOffice\4\user'.format(**global_vars['Env'])
|
||||
xcu_file = r'{}\registrymodifications.xcu'.format(xcu_dir)
|
||||
|
||||
# Set default save format
|
||||
if use_mso_formats and not os.path.exists(xcu_file):
|
||||
os.makedirs(xcu_dir, exist_ok=True)
|
||||
with open(xcu_file, 'w', encoding='utf-8', newline='\n') as f:
|
||||
f.write(LIBREOFFICE_XCU_DATA)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue