<p>This should fix the issue in <a href="https://github.com/geany/geany/issues/1076" class="issue-link js-issue-link" data-url="https://github.com/geany/geany/issues/1076" data-id="160793266" data-error-text="Failed to load issue title" data-permission-text="Issue title is private">#1076</a>: builds command for files with non-ASCII characters in the path cannot be executed.</p>

<p>I'm not sure why we didn't notice this earlier, either nobody tested this (unlikely I think) or something has changed in the meantime.<br>
Anyway, these both commits should fix it:<br>
<a href="https://github.com/geany/geany/commit/bac9b3aef53621c7948a9258fe894b0b22f68bab" class="commit-link"><tt>bac9b3a</tt></a> converts the working directory in Geany itself in order to be able to execute any command (Compile, Build, Run, ...) at all</p>

<p><a href="https://github.com/geany/geany/commit/3830347944092b3dccbc1924600ba44228ff950e" class="commit-link"><tt>3830347</tt></a> add codepage mangling in the generated batch script for Build->Run. This is not nice but the best I could get. Ideas like converting the whole script into locale encoding and such didn't work at all :(.</p>

<p>N.B. as usual I missed the string freeze, this time really close :). Hence the commented code in <a href="https://github.com/geany/geany/commit/bac9b3aef53621c7948a9258fe894b0b22f68bab" class="commit-link"><tt>bac9b3a</tt></a> which would introduce a new string otherwise. For now, we just "throw" the pure error message from <code>g_locale_from_utf8</code> instead of some context description around. I'll change this post-1.28.</p>

<hr>

<h4>You can view, comment on, or merge this pull request online at:</h4>
<p>  <a href='https://github.com/geany/geany/pull/1095'>https://github.com/geany/geany/pull/1095</a></p>

<h4>Commit Summary</h4>
<ul>
  <li>Windows: Convert working directory into locale encoding before spawning commands</li>
  <li>Windows: Change codepage for directory change in created batch run script</li>
</ul>

<h4>File Changes</h4>
<ul>
  <li>
    <strong>M</strong>
    <a href="https://github.com/geany/geany/pull/1095/files#diff-0">src/build.c</a>
    (9)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/geany/geany/pull/1095/files#diff-1">src/spawn.c</a>
    (22)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/geany/geany/pull/1095/files#diff-2">src/win32.c</a>
    (12)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/geany/geany/pull/1095/files#diff-3">src/win32.h</a>
    (2)
  </li>
</ul>

<h4>Patch Links:</h4>
<ul>
  <li><a href='https://github.com/geany/geany/pull/1095.patch'>https://github.com/geany/geany/pull/1095.patch</a></li>
  <li><a href='https://github.com/geany/geany/pull/1095.diff'>https://github.com/geany/geany/pull/1095.diff</a></li>
</ul>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/geany/geany/pull/1095">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe/ABDrJ9iCj_3zHS0QakH0A5_Oizi1HQPnks5qQFN6gaJpZM4I_lTo">mute the thread</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/ABDrJ7DsoEZEKlkA_9UkKjUVJXmDaY8uks5qQFN6gaJpZM4I_lTo.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
  <link itemprop="url" href="https://github.com/geany/geany/pull/1095"></link>
  <meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>