Commit Graph

188 Commits (bfad3f23d07ab58502a507fcdaf9254b08f4f23d)

Author SHA1 Message Date
intrigeri aed42eb34a po: fix istranslation/istranslatable for pages starting with /
Signed-off-by: intrigeri <intrigeri@boum.org>
2008-11-12 17:29:12 +01:00
intrigeri 2b4e76a961 po: change a bit the way links are generated
This will soon enable usage of translated page titles in link.

Signed-off-by: intrigeri <intrigeri@boum.org>
2008-11-11 22:29:47 +01:00
intrigeri f0abaa9fc9 po: fixed link to home page when po_link_to=negotiated, added testcase
Signed-off-by: intrigeri <intrigeri@boum.org>
2008-11-11 18:42:14 +01:00
intrigeri cfe101fff9 po: fixed link to homepage from non-translation page
Added testcases for this bug.
It remains broken when generated from <TMPL_VAR BASEURL>, though.

Signed-off-by: intrigeri <intrigeri@boum.org>
2008-11-11 15:06:26 +01:00
intrigeri 45694a8623 t/po.t: removed debug lines
Signed-off-by: intrigeri <intrigeri@boum.org>
2008-11-10 19:40:54 +01:00
intrigeri 812f775e0a Merge commit 'upstream/master' into prv/po 2008-11-10 15:41:29 +01:00
Joey Hess 7f80e52543 Fix the link() pagespec to match links that are internally recorded as absolute.
This fixes a problem exposed by the recent change to tags
(a2839de936). That recorded tag links as
absolute by including a leading slash in the link. The same could also be
done with an absolute wikilink.

In either case, link() would not match such links, unless the leading slash
was included in the link to match. But that's not right, because pagespecs
match absolute by default. So strip the leading slash.

Note that to keep any existing `link(/foo)` pagespecs working after this
change, the leading slash is removed from there, too.
2008-11-09 15:31:57 -05:00
intrigeri a0ac346079 po: finished backlinks implementation
Signed-off-by: intrigeri <intrigeri@boum.org>
2008-11-07 22:17:54 +01:00
intrigeri d1e5affbc2 po: oops, removed debug output from testsuit
Signed-off-by: intrigeri <intrigeri@boum.org>
2008-11-07 21:39:55 +01:00
intrigeri 14415a2b67 po: implemented linking specification in testcase
Signed-off-by: intrigeri <intrigeri@boum.org>
2008-11-07 21:24:00 +01:00
intrigeri 7d88fb3ff8 po plugin: added test cases for index.*
(Translatable index is currently buggy, let's fix this.)

Signed-off-by: intrigeri <intrigeri@boum.org>
2008-11-02 18:54:04 +01:00
intrigeri 06e3558318 po plugin: added testsuite
I want to have an easy way to know if I break something when I'll convert custom
added hooks to the new "inject" feature. It will also be useful after this
conversion, to trigger an alert when IkiWiki's internals change enough to break
my wrapper functions.

Signed-off-by: intrigeri <intrigeri@boum.org>
2008-11-02 16:46:09 +01:00
intrigeri a021d97d30 syntax.t: skip po since it uses a perl module not in build deps
Signed-off-by: intrigeri <intrigeri@boum.org>
2008-10-18 16:22:37 +02:00
Joey Hess 3ef2824350 add test for empty, and for entirely negated pagespecs 2008-09-30 15:06:12 -04:00
Joey Hess 9ec9d6901d Export pagetitle, titlepage, linkpage. 2008-09-27 14:27:42 -04:00
Joey Hess dfe55e8956 Add keepextension parameter to htmlize hook. (Willu) 2008-09-23 13:39:21 -04:00
Joey Hess a7ff240afc test for brokenlinks when listdirectives is enabled, too 2008-09-11 19:06:44 -04:00
Joey Hess 2d43eda27d display broken links on failure 2008-09-11 18:56:28 -04:00
Joey Hess 210b9ba2f3 test skeleton.pm.example 2008-08-03 19:36:10 -04:00
Joey Hess 2faf1ec601 update rcs tests for new rcs plugin load method
As a side effect, since loadplugins is called, mdwn is loaded, so
rcs_recentchanges will return page names, not filenames, for mdwn files.
2008-08-01 16:45:05 -04:00
Joey Hess 6154dd03cb finish with rcs plugin conversion 2008-07-26 22:28:18 -04:00
Joey Hess 14cd75746a Version control backends promoted to first-class plugins 2008-07-26 22:27:24 -04:00
Joey Hess bb888daea0 add a test case 2008-07-26 22:10:09 -04:00
Joey Hess fdf3b7c4b8 add test data 2008-07-25 19:41:01 -04:00
Joey Hess 88e9ef449d add a regression test to ensure that permalinks never change 2008-07-25 19:40:28 -04:00
Joey Hess a69e3f26dd 2 was apparently correct
I don't think it really matters whether directories are returned or not.
2008-07-25 15:16:49 -04:00
Joey Hess ef1f4defed bring git test to parity with bazaar test
Also, fixed bug I introduced in bazaar test.
2008-07-25 15:08:17 -04:00
Joey Hess acf94414e3 expose a bug in bzr renameing code 2008-07-25 12:16:09 -04:00
Joey Hess 256a118e88 add missing --quiet 2008-07-25 12:07:48 -04:00
Joey Hess c401cf4f0c Merge commit 'jelmer/master' 2008-07-25 12:03:34 -04:00
Jelmer Vernooij 7538d356c8 Support staging commands in bzr backend. 2008-07-24 22:43:57 +02:00
Joey Hess c2f621cb1c fix encoding issues with link conversion
Have to convert link text to page name going in.
And on the way out, need to replace spaces with underscores in the link
text, which is not normally done with titles.
2008-07-24 12:36:10 -04:00
Joey Hess 8b3d2ab0bc test suite and partial fix for encoding issues in link renaming 2008-07-23 21:04:11 -04:00
Joey Hess 4918c164e8 preserve case of subpage 2008-07-23 19:03:37 -04:00
Joey Hess 8b063a24d9 case preservation 2008-07-23 18:57:27 -04:00
Joey Hess 4691a2ad39 add renamepage hooks
Implemented for regular wikilinks, with a test suite.
2008-07-23 18:14:20 -04:00
Joey Hess 2c05a34be1 Merge commit 'intrigeri/pedigree' 2008-07-16 17:31:15 -04:00
intrigeri 35668b87d3 pedigree rename to parentlinks: rename/adapt everything
* Renamed to parentlinks every single variable or function called
  pedigree
* Removed the parentlinks function from Render.pm
* Enabled the new parentlinks plugin by default
* Adapted testsuite and documentation to reflate the above facts

Signed-off-by: intrigeri <intrigeri@boum.org>
2008-07-15 16:25:39 +02:00
intrigeri 486f460132 pedigree rename to parentlinks: renamed files, to start with
Signed-off-by: intrigeri <intrigeri@boum.org>
2008-07-15 16:09:40 +02:00
intrigeri 55000fd779 pedigree: rewrote with different design
(and updated testsuite + docs accordingly)

Signed-off-by: intrigeri <intrigeri@boum.org>
2008-07-15 13:06:52 +02:00
Joey Hess d7da4a8e16 todo is not built, so don't try to check it 2008-07-14 21:20:48 -04:00
intrigeri 9b8ba60dac added testsuite for the pedigree plugin
Signed-off-by: intrigeri <intrigeri@boum.org>
2008-07-14 23:03:27 +02:00
Simon McVittie 60dc17c39c Hopefully fix regression tests in non-English environments 2008-07-12 23:00:57 +01:00
Joey Hess 1dddec0ba9 Pass a destpage parameter to the sanitize hook.
Because the search plugin needed it, also because it's one of the few
plugins that didn't already have it.

I also considered adding it to htmlize, but I really cannot imagine caring
what the destpage is when htmlizing. (I'll probably be poven wrong later.)
2008-06-04 01:24:23 -04:00
Joey Hess a436a064d2 fix test to support rel= 2008-05-30 17:12:32 -04:00
Joey Hess 71555b5951 fix regression test 2008-05-25 14:12:49 -04:00
Joey Hess a09bd3b00f skip amazon_s3 since it uses a perl module not in build deps 2008-05-09 13:10:08 -04:00
Joey Hess 7d7f85bbb5 Correct a bug in pagespec matching, where a empty pagespec matched all pages.
This manifested as wikis with no locked pages treating them all as locked.
The bug was introduced in version 2.41.

Medium urgency upload due to above fix.
2008-04-24 13:49:15 -04:00
Joey Hess f1228946bd Bring back the svnrepo setup file option. This is needed for recentchangediff to work with svn repos. 2008-04-17 14:37:55 -04:00
Joey Hess 20271cf172 add loadindex/saveindex test suite 2008-03-22 13:56:44 -04:00
Joey Hess fa101abf08 misc improvements 2008-02-24 15:58:11 -05:00
Joey Hess 023e3c47a4 fix test to intialise plugins 2008-02-24 14:54:01 -05:00
Joey Hess dfd6bb3854 fix data:image handling 2008-02-10 15:24:03 -05:00
Joey Hess d7e0c035e5 * htmlscrubber security fix: Block javascript in uris.
* Add htmlscrubber test suite.
2008-02-10 13:16:40 -05:00
Joey Hess 5e47db9356 improved sanitiser test suite 2008-02-10 12:21:20 -05:00
Joey Hess 17246f6b45 add some more tests 2008-02-10 03:42:54 -05:00
Joey Hess e9a215982b new test case 2008-02-10 03:38:30 -05:00
Joey Hess f92505d78b Merge branch 'master' into prefix-directives 2008-02-05 15:59:42 -05:00
Jelmer Vernooij 246e93a300 Expand file-id in diffurl in the bzr backend. 2008-01-30 02:29:28 +01:00
Joey Hess cddc335b2b Merge git://git.samba.org/jelmer/ikiwiki 2008-01-29 19:28:51 -05:00
Joey Hess 3803266b8f merged the recentchanges branch
misc fixes
2008-01-29 17:50:11 -05:00
Joey Hess 8b31c53366 added configuration for recentchanges
I kept it to a simple global configuration, rather than using the
preprocessor directive for recentchanges, because that had chicken and egg
problems and seemed overcomplicated. This should work reasonably well,
though it would be good to add some more metadata so that more customised
recentchanges pages can be made.
2008-01-29 15:51:32 -05:00
Joey Hess d7fdd04b5a * Removed support for sending commit notification mails. Along with it went
the svnrepo and notify settings, though both will be ignored if left in
  setup files.
2008-01-29 00:36:58 -05:00
Joey Hess 652781c50f update test suite to fully test both with and without prefix_directives 2008-01-28 16:22:07 -05:00
Jelmer Vernooij d3f91f37ff Finish bazaar backend and make the remaining test pass. 2008-01-28 07:30:37 +01:00
Jelmer Vernooij 0be7aad67d Initial work adding support for Bazaar. 2008-01-28 06:16:56 +01:00
Josh Triplett 1b03a06c8c Add new preprocessor directive syntax¸ using a '!' prefix.
Add a prefix_directives option to the setup file to turn this syntax
on; currently defaults to false, for backward compatibility.  Support
optional '!' prefix even with prefix_directives off, and use that in
the underlay to support either setting of prefix_directives.  Add NEWS
entry with migration information.
2008-01-27 16:14:38 -08:00
Joey Hess 633f8d4dd3 shut up git commands run manually 2007-12-27 19:38:55 -05:00
Joey Hess 10e26c0370 file_pruned regression tests 2007-12-18 00:38:06 -05:00
joey 7e144b8f4a arg, the test suite was testing for bugs 2007-09-30 19:15:17 +00:00
joey 2de411ac86 * Exclude external plugin from syntax check since it uses a module that is
not in the build depends. Closes: #441171
2007-09-07 17:06:42 +00:00
joey 8fd13334af fix path issue when runnign test 2007-09-05 23:51:08 +00:00
joey 6b5ab21959 * Change git test suite to reflect change in log for initial repo creation
commit.
2007-09-05 23:45:39 +00:00
joey 67c6ff9b08 * mercurial: Fix rcs_getctime (thanks, bma) 2007-08-29 02:16:45 +00:00
joey 9c5f4761d8 * Support for looking in multiple directories for underlay files.
* Plugins can add new directories to the search path with the add_underlay
  function.
* Split out smiley underlay files into a separate underlay, so if the plugin
  isn't used, the wiki isn't bloated with all those files.
2007-08-28 01:59:01 +00:00
joey 7c032d1465 test suite fixes 2007-08-21 19:58:14 +00:00
joey e0da57358c get confused. So it's best for ikiwiki to follow the compatability
* Support building on systems that lack asprintf.
* mercurial getctime is currently broken, apparently by some change in
  mercurial version 0.9.4. Turn the failing test case into a TODO test case.
2007-07-09 00:39:55 +00:00
joey afcf0dc79e * Patch fixing various additional problems with test suite. Closes: #425891
once more.
2007-06-26 22:11:59 +00:00
joey 3bfa109971 * Allow svnpath config option to contain additional extra slashes anywhere
w/o confusing ikiwiki.
* Rcs modules are now imported, so other modules that need similar
  normalisation of configs etc can do so.
2007-06-23 12:12:59 +00:00
joey 7e3cfbb8a4 couple more 2007-06-02 05:08:33 +00:00
joey bf228acd0a * Add test suite for preprocessor directive parsing. 2007-06-02 05:05:22 +00:00
joey 66cb6baf4e * Apply a patch from Carl Worth adding support for using globs in link()
in a PageSpec.
2007-05-30 19:54:08 +00:00
joey ffc06c8e4d * Fix FTBFS in test suite introduced in last version. Closes: #425891 2007-05-24 20:21:45 +00:00
joey 05fbbad4b4 build fixes 2007-05-20 01:04:24 +00:00
joey d3d528b5c4 * Add a test ensuring that the basewiki is self-contained and has no broken
links.
2007-05-20 01:00:21 +00:00
joey e7d4a00bf0 fix 2007-04-29 22:58:27 +00:00
joey 0d01b4f426 updates for usedirs 2007-04-29 22:57:21 +00:00
joey 8fa8bd0adb the kind of perl code that can only be written at 4:30 am
(Get a good message when a PageSpec fails due to a negated success by
creating success objects with a reason string, which morph into failure
objects when negated.)
2007-04-27 08:34:09 +00:00
joey f8a7fb227b * Make pagespec_match on failure return a value that is false, but in a
scalar context, evaluates to a reason why the match failed.
* Add testpagespec plugin, which might be useful to see why a pagespec isn't
  matching something.
2007-04-27 07:55:40 +00:00
joey ee1ad53c4c * pagespec_match() has changed to take named parameters, to better allow
for extended pagespecs. The old calling convention will still work for
  back-compat for now.
* The calling convention for functions in the IkiWiki::PageSpec namespace
  has changed so they are passed named parameters.
* Plugin interface version increased to 2.00 since I don't anticipate any
  more interface changes before 2.0.
2007-04-27 02:55:52 +00:00
joey 250bd850e2 support %destsources 2007-04-14 20:41:43 +00:00
joey 2a0d91af2f * Fix link() PageSpecs to not just look at the raw link text, but at where
that given link points based on the page doing the linking. Note that this
  could make such PageSpecs match different things than before, if you
  relied on the old behavior of them only matching the raw link text.
* This required changing the match_* interface, adding a third parameter.
* Allow link() PageSpecs to match relative, as is allowed with globs.a
* Add postform option to inline plugin.
* Add an bug tracker to the softwaresite example.
2007-03-21 23:11:09 +00:00
joey b365d864c5 My fix to support encoded underscores in page titles broke links to pages
with underscores in their filenames, since the link code also used
titlepage. Create a new linkpage function and have the link code use that
instead.
2007-03-07 09:48:59 +00:00
joey 3660b1c7a1 * Allow for underscores to appear in page titles, if encoded appropriately
(__95__) in filenames. Previously, all underscores were replaced with
  spaces. Thanks, Enrico Zini for noticing that bug.
2007-03-02 00:37:22 +00:00
joey fa52a730ff * Changed calling convention for httmllink slightly. The first three
parameters remain the same, but additional options are now passed in using
  named parameters.
* Change plugin interface version to 1.02 to reflect this change.
* Add a new anchor option to htmllink. Thanks Ben for the idea.
* Support anchors in wikilinks.
* Add a "more" plugin based on one contributed by Ben to allow implementing
  those dreaded "Read more" links in blogs.
2007-02-20 03:05:47 +00:00
joey 897ec7cb79 add test 2007-02-20 01:51:23 +00:00
joey 479c7a1ea6 * Allow plugins to add new types of tests that can be used in PageSpecs.
* Add a "conditional" plugin, which allows displaying text if a condition
  is true. It is enabled by default so conditional can be used in the
  basewiki.
* Use conditionals in the template for plugins, so that plugin pages
  say if they're currently enabled or not, and in various other places
  in the wiki.
2007-02-12 02:44:47 +00:00
joey d472e293cd fixes and more tests 2007-02-07 00:45:00 +00:00
joey 58141a0ebc * Patch based on a patch from Ethan to support relative matching in
PageSpecs, by using "./". pagespec_match() has grown a new third parameter
  to support this.
2007-02-06 21:17:25 +00:00
joey 7c7bbfc3a9 Add userdir testcases. This also fixes an undefined value. 2007-01-06 04:22:46 +00:00