<blockquote>
<p>My filemanager names copies you paste in the same directory as "filename(copy).ext" "filename(another copy).ext" "filename(3rd copy).ext" and there I got too bored to see what it did at 10 :) </p>
</blockquote>

<p>It's all about making cloning of documents easier and faster.</p>

<blockquote>
<p>I'm not sure this is really enough of a problem to need code added for it, do a lot of users clone files all the time?</p>
</blockquote>

<p>I do.  Most of the time, when creating versions, or using a document as a template for another, and also when creating temporary copies; one of the reasons is to differentiate versions among branches in git, or just use as reference for copying code; another is simply for immediate backup.</p>

<p>This is pretty much very helpful to developers, especially if combined with in-place renaming.</p>

<blockquote>
<p>1) it is touching the filesystem to check the existence of the selected filename, which is fine if its a fast local SSD, but not so much for a remote SSHFS directory.</p>
</blockquote>

<p>I'm not sure if that's a concern with a one-time command.  The loop may run up to 99 but it would never always go that far.  <code>g_file_test()</code> is also pretty much commonly used around Geany.</p>

<p>An option to disable this can be added if that's really a concern.</p>

<blockquote>
<p>2) AFAICT it also changes the readonly behaviour, please do not include extra things in an implementation not described in the PR.</p>
</blockquote>

<p>Ok, reverted.</p>

<blockquote>
<p>3) probably needs user documentation :)</p>
</blockquote>

<p>Done.</p>

<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/1191#issuecomment-242067864">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABDrJ9UZb1mj2TnkZe6sczMlMC4YTjJIks5qjEo9gaJpZM4Jr1Jh">mute the thread</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/ABDrJzQoCNu0NT5qcYpXNMCi9pPziLDlks5qjEo9gaJpZM4Jr1Jh.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/1191#issuecomment-242067864"></link>
  <meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>

<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/geany/geany","title":"geany/geany","subtitle":"GitHub repository","main_image_url":"https://cloud.githubusercontent.com/assets/143418/17495839/a5054eac-5d88-11e6-95fc-7290892c7bb5.png","avatar_image_url":"https://cloud.githubusercontent.com/assets/143418/15842166/7c72db34-2c0b-11e6-9aed-b52498112777.png","action":{"name":"Open in GitHub","url":"https://github.com/geany/geany"}},"updates":{"snippets":[{"icon":"PERSON","message":"@konsolebox in #1191: \u003e My filemanager names copies you paste in the same directory as \"filename(copy).ext\" \"filename(another copy).ext\" \"filename(3rd copy).ext\" and there I got too bored to see what it did at 10 :) \r\n\r\nIt's all about making cloning of documents easier and faster.\r\n\r\n\u003e I'm not sure this is really enough of a problem to need code added for it, do a lot of users clone files all the time?\r\n\r\nI do.  Most of the time, when creating versions, or using a document as a template for another, and also when creating temporary copies; one of the reasons is to differentiate versions among branches in git, or just use as reference for copying code; another is simply for immediate backup.\r\n\r\nThis is pretty much very helpful to developers, especially if combined with in-place renaming.\r\n\r\n\u003e 1) it is touching the filesystem to check the existence of the selected filename, which is fine if its a fast local SSD, but not so much for a remote SSHFS directory.\r\n\r\nI'm not sure if that's a concern with a one-time command.  The loop may run up to 99 but it would never always go that far.  `g_file_test()` is also pretty much commonly used around Geany.\r\n\r\nAn option to disable this can be added if that's really a concern.\r\n\r\n\u003e 2) AFAICT it also changes the readonly behaviour, please do not include extra things in an implementation not described in the PR.\r\n\r\nOk, reverted.\r\n\r\n\u003e 3) probably needs user documentation :)\r\n\r\nDone.\r\n"}],"action":{"name":"View Pull Request","url":"https://github.com/geany/geany/pull/1191#issuecomment-242067864"}}}</script>