Edgewall Software
Modify

Opened 17 years ago

Closed 17 years ago

Last modified 17 years ago

#4285 closed enhancement (worksforme)

wiki history in svn

Reported by: fabien.no.spam.please@… Owned by: Jonas Borgström
Priority: normal Milestone:
Component: wiki system Version: 0.10.2
Severity: normal Keywords:
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description

ISTM that having the wiki history handled by a relationnal table is not good idea, esp. as "svn" is readily available!

I tried to put wikis as simple files in the svn repos, and I can create a direct link to this file from the wiki. However I have not found any way to make trac process the file as a wiki so as to add prettyprints and so. there is only a "raw" format that can be used for links, but no "wiki" format. I've tried some python macros without great success. I can just show the file in raw format.

Attachments (1)

RawLink.py (935 bytes ) - added by fabien.no.spam.please@… 17 years ago.
link to svn file shown in raw format.

Download all attachments as: .zip

Change History (5)

by fabien.no.spam.please@…, 17 years ago

Attachment: RawLink.py added

link to svn file shown in raw format.

comment:1 by Christian Boos, 17 years ago

Resolution: worksforme
Status: newclosed

Well, you address several different topics here:

  1. using svn as a storage backend for the wiki subsystem is addressed in #1132 (the TighterSubversionIntegration page linked from there has even a patch…)
  2. wiki formatting of text files which are using the Trac wiki syntax and stored in the svn repository can be triggered by two ways:
    • by setting the text/x-trac-wiki property on the files
    • by choosing some file extension (e.g. .trac) and adding a mapping in the trac.ini (see TracIni#mimeviewer-section, mime_map entry).

I'll use the worksforme resolution for point 2., as I think this was your main concern.

in reply to:  1 ; comment:2 by fabien.no.spam.please@…, 17 years ago

  1. wiki formatting of text files which are using the Trac wiki syntax and stored in the svn repository can be triggered by two ways:

I tried both without much success on 10.2 with source:… links.

  • by setting the text/x-trac-wiki property on the files

Do you mean to set the "svn:mime-type" svn property on the file?

  • by choosing some file extension (e.g. .trac) and adding a mapping in the trac.ini (see TracIni#mimeviewer-section, mime_map entry).

The documentation is scarce;-) I tried to add without much luck on a *.wiki file:

mime_map = …,text/x-trac-wiki:wiki

thanks for your (one month old) anwer anyway.

in reply to:  2 ; comment:3 by Christian Boos, 17 years ago

Replying to fabien.no.spam.please@coelho.net:

  1. wiki formatting of text files which are using the Trac wiki syntax and stored in the svn repository can be triggered by two ways:

I tried both without much success on 10.2 with source:… links.

  • by setting the text/x-trac-wiki property on the files

Do you mean to set the "svn:mime-type" svn property on the file?

Yes, e.g. svn pset svn:mime-type text/x-trac-wiki README

  • by choosing some file extension (e.g. .trac) and adding a mapping in the trac.ini (see TracIni#mimeviewer-section, mime_map entry).

The documentation is scarce;-) I tried to add without much luck on a *.wiki file:

mime_map = …,text/x-trac-wiki:wiki

That should work: here's the line which I tested and worked for me:

[mimeview]
mime_map = text/x-python:pyt:pyr,text/x-ruby:rub,text/x-trac-wiki:wiki

in reply to:  3 comment:4 by fabien.no.spam.please@…, 17 years ago

Ok, it worked!

I had a stupid unexpected character at the beginning of the wiki text, so that the wiki transformer was not working properly.

Thanks a lot for your help.

Submission rejected as potential spam (SpamBayes determined spam probability of 61.22%)

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Jonas Borgström.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Jonas Borgström to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.