# HG changeset patch
# User Matt Harbison <
matt_h...@yahoo.com>
# Date 1701454319 18000
# Fri Dec 01 13:11:59 2023 -0500
# Branch stable
# Node ID ce8444c6988b7d3a18e1615253a3532df2620cb3
# Parent 90118cfe679e7f2cb2dfb9f97f55d183f9a3b8ec
packaging: bundle configitems.toml from Mercurial on Windows
This is the new form of `mercurial/configitems.py` that is usable with Rust, and
needs to live next to the executable. I'm assuming the macOS packaging is also
broken, but haven't tested it yet.
diff --git a/contrib/packaging/thgpackaging/py2exe.py b/contrib/packaging/thgpackaging/py2exe.py
--- a/contrib/packaging/thgpackaging/py2exe.py
+++ b/contrib/packaging/thgpackaging/py2exe.py
@@ -46,6 +46,7 @@
('{hg_dir}/doc/*.html', 'doc/'),
('{hg_dir}/doc/style.css', 'doc/'),
('{hg_dir}/mercurial/helptext/**/*.txt', 'helptext/'),
+ ('{hg_dir}/mercurial/configitems.toml', './'),
# *.rc files come from TortoiseHg only
#('{hg_dir}/mercurial/defaultrc/*.rc', 'defaultrc/'),
('{hg_dir}/mercurial/locale/**/*', 'locale/'),
diff --git a/win32/wix/dist-py3.wxs b/win32/wix/dist-py3.wxs
--- a/win32/wix/dist-py3.wxs
+++ b/win32/wix/dist-py3.wxs
@@ -23,6 +23,10 @@
<File Name="libssl-1_1.dll" />
<?endif?>
</Component>
+ <Component Id='configitems.toml' Guid='*' Win64='$(var.IsX64)'>
+ <File Id='configitems.toml' Name='configitems.toml' KeyPath='yes'
+ Source='$(var.SourceDir)/configitems.toml'/>
+ </Component>
<Directory Id="libdir" Name="lib" FileSource="$(var.SourceDir)/lib">
<Component Id="libOutput" Guid="$(var.lib.guid)" Win64='$(var.IsX64)'>
<File Name="library.zip" KeyPath="yes" />
diff --git a/win32/wix/tortoisehg-py3.wxs b/win32/wix/tortoisehg-py3.wxs
--- a/win32/wix/tortoisehg-py3.wxs
+++ b/win32/wix/tortoisehg-py3.wxs
@@ -224,6 +224,7 @@
<ComponentRef Id='MainExecutable' />
<ComponentRef Id='ProgramMenuDir' />
<ComponentRef Id='COPYING' />
+ <ComponentRef Id='configitems.toml' />
<ComponentRef Id='mercurial.rc' />
<ComponentRef Id='mergetools.rc' />
<ComponentRef Id='editortools.rc' />