From: Jorgen Grahn <grahn+nntp@snipabacken.se>
To: help-gnu-emacs@gnu.org
Subject: Re: Copy Paste Detection
Date: 21 Jan 2011 19:52:30 GMT [thread overview]
Message-ID: <slrnijjovu.t7d.grahn+nntp@frailea.sa.invalid> (raw)
In-Reply-To: mailman.2.1295611177.26310.help-gnu-emacs@gnu.org
On Fri, 2011-01-21, Gary wrote:
> Deniz Dogan wrote:
>
>> 2011/1/21 Gary:
>>> Does anyone know of any modes that do (programming-)language
>> independent
>>> copy/paste (kill/yank) detection in emacs?
>>>
>>> I suppose external tools would also work, but I really would prefer it
>>> if it was something I could usable on an emacs buffer.
>>
>> What do you mean?
>
> I mean that if in some code file someone has written the same code more
> than once, or more likely copy/pasted it, I would like to identify those
> code blocks. See http://pmd.sourceforge.net/cpd.html for an example. The
> difference is, the language that I use is so little known that a tool
> explicitly targeting it won't exist, hence the "language independent"
> part.
Sounds more like a job for
% sort -b | uniq -c | sort -nr
And manually detect suspiciously similar lines.
/Jorgen
--
// Jorgen Grahn <grahn@ Oo o. . .
\X/ snipabacken.se> O o .
prev parent reply other threads:[~2011-01-21 19:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-21 10:12 Copy Paste Detection Gary
2011-01-21 10:25 ` Deniz Dogan
2011-01-21 11:59 ` Gary
[not found] ` <mailman.2.1295611177.26310.help-gnu-emacs@gnu.org>
2011-01-21 19:52 ` Jorgen Grahn [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=slrnijjovu.t7d.grahn+nntp@frailea.sa.invalid \
--to=grahn+nntp@snipabacken.se \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).