emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Quick note about subtree copy and paste
@ 2011-01-06 17:23 Robert Goldman
  2011-01-11 14:03 ` Giovanni Ridolfi
  0 siblings, 1 reply; 3+ messages in thread
From: Robert Goldman @ 2011-01-06 17:23 UTC (permalink / raw)
  To: Org Mode

I just did a copy and paste and noticed that when I did so the copied
properties included the ID which, after being copied, meant that the
unique identifier became a non-unique identifier.

Is it work tweaking the org-paste-special command to rip out ID properties?

cheers,
r

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Quick note about subtree copy and paste
  2011-01-06 17:23 Quick note about subtree copy and paste Robert Goldman
@ 2011-01-11 14:03 ` Giovanni Ridolfi
  2011-01-11 14:32   ` Robert Goldman
  0 siblings, 1 reply; 3+ messages in thread
From: Giovanni Ridolfi @ 2011-01-11 14:03 UTC (permalink / raw)
  To: rpgoldman; +Cc: Org Mode

Robert Goldman <rpgoldman@sift.info> writes:

> I just did a copy and paste and noticed that when I did so the copied
> properties included the ID which, after being copied, meant that the
> unique identifier became a non-unique identifier.
Well, you shouldn't ! ;-)

If you have to copy/paste a subtree, please... *clone* it.

manual: Structure editing:

`C-c C-x c' (`org-clone-subtree-with-time-shift')

(then the :ID: is changed)

Giovanni

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Quick note about subtree copy and paste
  2011-01-11 14:03 ` Giovanni Ridolfi
@ 2011-01-11 14:32   ` Robert Goldman
  0 siblings, 0 replies; 3+ messages in thread
From: Robert Goldman @ 2011-01-11 14:32 UTC (permalink / raw)
  To: Giovanni Ridolfi; +Cc: Org Mode

On 1/11/11 Jan 11 -8:03 AM, Giovanni Ridolfi wrote:
> Robert Goldman <rpgoldman@sift.info> writes:
> 
>> I just did a copy and paste and noticed that when I did so the copied
>> properties included the ID which, after being copied, meant that the
>> unique identifier became a non-unique identifier.
> Well, you shouldn't ! ;-)
> 
> If you have to copy/paste a subtree, please... *clone* it.
> 
> manual: Structure editing:
> 
> `C-c C-x c' (`org-clone-subtree-with-time-shift')
> 
> (then the :ID: is changed)
> 
> Giovanni

I get the point, but the current presentation is unnecessarily
confusing.  I was just /copying/ --- there was no time shifting
involved, so when I look at them menu and see "copy" and "clone with
time shift," it is "copy" that's what I naturally do.

Actually, as I look at the manual I see:

`C-c C-x c'     (`org-clone-subtree-with-time-shift')
     Clone a subtree by making a number of sibling copies of it.  You
     will be prompted for the number of copies to make, and you can
     also specify if any timestamps in the entry should be shifted.
     This can be useful, for example, to create a number of tasks
     related to a series of lectures to prepare.  For more details, see
     the docstring of the command `org-clone-subtree-with-time-shift'.

There's nothing there to even remotely suggest to me that this is going
to Do The Right Thing about properties.  It's all about dates and
time-shifting.  It may /happen/ to do the right thing with properties,
but it sure doesn't /say/ that it will.  The ID property is mentioned
only in the interactive docstring, and pretty deeply down.

I'd like to make a somewhat radical suggestion:

If cloning is the primary option, and more safe than copy --- i.e., if
copy is "this is the primitive operation that you should only do if you
know what you are doing, because it might corrupt data," then I would
argue that it's CLONE that should be bound to C-c C-x M-y --- the
standard emacs keybinding I'm going to go to first --- and COPY should
be demoted to the less-familiar alternative.

This assumes that the answer to "Is there any case where I should do
copy and /not/ prefer clone?" is "no."

But I'm not sure that's the case.  They clone doesn't do the same thing
to the cut buffer as copy, does it?  e.g., I don't use clone to make a
copy of a subtree from file A into file B.

Even more radical suggestion:

So maybe the right answer is not to ask us to use clone all the time,
but that COPY and PASTE should be fixed to Do The Right Thing with the
ID property.

Best,
r

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-01-11 14:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-01-06 17:23 Quick note about subtree copy and paste Robert Goldman
2011-01-11 14:03 ` Giovanni Ridolfi
2011-01-11 14:32   ` Robert Goldman

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).