<p dir="auto">The problem with current project files, which contain absolute paths to<br>
open documents, is, that when moved to another directory, they become<br>
invalid.</p>
<p dir="auto">There have been various pull requests in the past attempting to start<br>
using relative paths, the problem was, that given Geany's flexibility<br>
in placing the project file, which can theoretically be stored on<br>
another drive inaccessible using relative paths, using relative paths<br>
would break things.</p>
<p dir="auto">This patch tries to address only one specific situation where we can<br>
be sure relative paths work - when the user specifies the base directory<br>
using a relative path against the project file. Since it's the user<br>
who specifies the base path as relative and this relative path works<br>
for him, we can be sure files within base path are reachable using<br>
relative paths too.</p>
<p dir="auto">Only files within the base path are stored as relative paths. Files<br>
outside the base path are still stored as absolute paths.</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/3021'>https://github.com/geany/geany/pull/3021</a></p>

<h4>Commit Summary</h4>
<ul>
  <li><a href="https://github.com/geany/geany/pull/3021/commits/557c8fa8998b2979c0d953390b7b0b8bf41bd7df" class="commit-link">557c8fa</a>  Use relative paths for project session files if base directory is relative</li>
</ul>

<h4 style="display: inline-block">File Changes </h4> <p style="display: inline-block">(<a href="https://github.com/geany/geany/pull/3021/files">3 files</a>)</p>
<ul>
  <li>
    <strong>M</strong>
    <a href="https://github.com/geany/geany/pull/3021/files#diff-2810524eed127fdf86cd7a7aaac164efa0d240a2da10844304e79e0307dccaf3">src/keyfile.c</a>
    (39)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/geany/geany/pull/3021/files#diff-330d1a72c6819419fc2755e72764d05eb6414482586ce4f7cf8896e2b117794e">src/keyfile.h</a>
    (2)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/geany/geany/pull/3021/files#diff-08a2b89559e9135e3864640c098dc6367f44fdf0816a023ec7aab4a2edaa251c">src/project.c</a>
    (2)
  </li>
</ul>

<h4>Patch Links:</h4>
<ul>
  <li><a href='https://github.com/geany/geany/pull/3021.patch'>https://github.com/geany/geany/pull/3021.patch</a></li>
  <li><a href='https://github.com/geany/geany/pull/3021.diff'>https://github.com/geany/geany/pull/3021.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/3021">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAIOWJ3NICU5LCOHCK5QUWTUNZJBJANCNFSM5IYZ3XZA">unsubscribe</a>.<br />Triage notifications on the go with GitHub Mobile for <a href="https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675">iOS</a> or <a href="https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub">Android</a>.
<img src="https://github.com/notifications/beacon/AAIOWJ4LCZ7CHZHGCIDKKLDUNZJBJA5CNFSM5IYZ3XZKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4P3HC5JA.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/geany/geany/pull/3021",
"url": "https://github.com/geany/geany/pull/3021",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>