Edgewall Software

Ticket #4778 (new enhancement)

Opened 23 months ago

Last modified 13 months ago

simplified wikification of svn log messages

Reported by: Sergei Haller <sergei@…> Owned by: cboos
Priority: normal Milestone: 0.13
Component: wiki system Version: devel
Severity: normal Keywords: formatter
Cc:

Description (last modified by cboos) (diff)

Is it possible to simplify the wikification of svn log messages? The problem I get is if we have some math content (like

x^5+x^4+x

which will show like x5+x4+x. There are some other things as well, which we don't actually need in or project, as the log messages are and will always be plain text. The only thing I'd like to keep is the recognition of revision numbers in the log messages with the appropriate links.

Is it hard to achieve this? (Would be ok if it is in the source, i.e. not configurable by admin/user)

Thanks.

Attachments

format.patch (0.6 KB) - added by Sergei Haller <sergei@…> 23 months ago.
short-mes.patch (0.7 KB) - added by Sergei Haller <sergei@…> 23 months ago.
somewhat related. fixes shorten_line call in revision log if wiki_format_messages is disabled.

Change History

  Changed 23 months ago by Sergei Haller <sergei@…>

  • type changed from defect to enhancement

  Changed 23 months ago by Sergei Haller <sergei@…>

well, I found the place (template/changeset) and replaced

-              ${wiki_to_html(context, changeset.message, escape_newlines=True)}
+              <pre>${changeset.message}</pre>

is there any easy way to parse the message for revision numbers and convert them to links?

follow-up: ↓ 4   Changed 23 months ago by cboos

  • description modified (diff)
  • component changed from changeset view to wiki
  • summary changed from wikification of svn log messages to simplified wikification of svn log messages
  • owner changed from cboos to jonas
  • milestone set to 0.11
  • keywords formatter added

There's currently a TracIni#changeset-section option for that (wiki_format_messages).

Also, I'm in the process of refactoring the Wiki engine. I think it should be possible to create a "TracLinks only" formatter, so that only things like tickets and changesets links get formatted.

Changed 23 months ago by Sergei Haller <sergei@…>

in reply to: ↑ 3 ; follow-up: ↓ 5   Changed 23 months ago by Sergei Haller <sergei@…>

Replying to cboos:

There's currently a TracIni#changeset-section option for that (wiki_format_messages).

thanks, I must have overseen that option. Though it doesn't respect line breaks. This is easily fixed (see attached patch)

Also, I'm in the process of refactoring the Wiki engine. I think it should be possible to create a "TracLinks only" formatter, so that only things like tickets and changesets links get formatted.

that'd be great, too.

in reply to: ↑ 4   Changed 23 months ago by cboos

Replying to Sergei Haller <sergei@sergei-haller.de>:

Replying to cboos:

There's currently a TracIni#changeset-section option for that (wiki_format_messages).

thanks, I must have overseen that option. Though it doesn't respect line breaks. This is easily fixed (see attached patch)

thanks, applied in r4799.

Changed 23 months ago by Sergei Haller <sergei@…>

somewhat related. fixes shorten_line call in revision log if wiki_format_messages is disabled.

  Changed 23 months ago by cboos

  • owner changed from jonas to cboos

hm, btw, I didn't notice attachment:short-mes.patch but I did notice the columns full of shorten_line(message) -> r4800 ;-)

  Changed 22 months ago by cboos

In #3203, there's the idea to specifically disable one kind of link resolver (the r... style changeset links).

  Changed 22 months ago by cboos

#4944 was closed as duplicate (emphasis was put there on the need to respect whitespace).

  Changed 20 months ago by cboos

  • milestone changed from 0.11 to 0.12

WikiEngine refactoring and related fixes postponed.

  Changed 13 months ago by Alexander@…

Is the "TracLinks only" formatter already implemented? I am new to Trac and do not know how to interpret the message "milestone changed from 0.11 to 0.12" in this thread. The Trac instance I am a user of is still based on 0.10.3, but if I knew there was a feature like "TracLinks only", I might be able to convince the admin to upgrade to a newer version. The problem I had with the Wiki formatter is described in #6510.

  Changed 13 months ago by cboos

It simply means this feature is on the TODO list for 0.12.

Add/Change #4778 (simplified wikification of svn log messages)

Author



Change Properties
<Author field>
Action
as new
as The resolution will be set. Next status will be 'closed'
to The owner will change from cboos. Next status will be 'new'
The owner will change from cboos to anonymous. Next status will be 'assigned'
 
Note: See TracTickets for help on using tickets.