Merge branch 'master' of ssh://git.ikiwiki.info

master
Joey Hess 2013-09-23 13:21:56 -04:00
commit 9ef8c8c47a
8 changed files with 86 additions and 2 deletions

View File

@ -0,0 +1,11 @@
hi,
I'm not sure if I'm doing something wrong but I can't figure out how to get a download link for uploaded attachments.
I'd like to be able to upload arbitrary attachments eg. settings.xml or .gitinore or setup.txt or stuff.zip and be able to add a link to the wiki page which should let the user instantly download that file.
I thought it might be as simple as adding a directive eg. [[!downloadlink .gitinore]] .
This is driving me nuts, so any help or pointers will be appreciated even if I have to dig in to write a plugin.
I'm running the 3.20100815.9 on Debian 6.0 but then also tried a manual install of 3.20130904.1 which seemed to have caused a bunch of timeout errors and not much improvement on the attachment issue.
Should I try the git version?
thanks
marius

View File

@ -0,0 +1,8 @@
[[!comment format=mdwn
username="https://id.koumbit.net/anarcat"
ip="2001:1928:1:9::1"
subject="opened todo"
date="2013-09-21T13:58:45Z"
content="""
I explicitely opened a [[todo item|todo/git-annex_support]] about git-annex. From what I can see, it's currently unsupported, and there would be issues with file duplication between the bare repo and the srcdir, at the very least, unless git-annex magically supports hardlinks in local repos.
"""]]

View File

@ -0,0 +1,13 @@
Hello,
I have started using Ikiwiki for a personal site, which is great. I would like to add search functionality with the search plugin, so have it configured with the one parameter needed, and it does see files.
However, it seems to be doing a couple things with URLs that it shouldn't in this case:
* The link to the page has an extraneous "/cgi" in it, e.g. instead of "https://[hostname]/sandbox/" it has ""https://[hostname]/cgi/sandbox/".
* Also, the help link is the same, so links to "https://[hostname]/cgi/ikiwiki/searching/".
Another question I had is whether I can restrict the pages which get searched? I would like to have an internal section which isn't linked, and which doesn't pop up in search results. I know that I can configure the web server to restrict access, but would prefer that the page snippet and its presence not be advertised.
Thanks!
Tim

View File

@ -0,0 +1,16 @@
[[!comment format=mdwn
username="http://smcv.pseudorandom.co.uk/"
nickname="smcv"
subject="comment 1"
date="2013-09-22T09:07:43Z"
content="""
It sounds as though the `url` and/or `cgiurl` settings in your setup
file might be wrong. What are they? What is the actual \"root\" URL
of your wiki in your web server, and what is the actual URL of the
CGI script?
Regarding private stuff, I would recommend making a separate ikiwiki
instance for that, particularly if your wiki accepts edits from
untrusted people. For instance, anyone who can insert a \[[!map]]
directive can easily enumerate every page in your wiki.
"""]]

View File

@ -0,0 +1,11 @@
[[!comment format=mdwn
username="https://www.google.com/accounts/o8/id?id=AItOawnQpl89u6Sh88gg2irKxbfiwg5h0uLZyzg"
nickname="Tim"
subject="comment 2"
date="2013-09-22T15:44:51Z"
content="""
Thanks. The url parameter is the full hostname, e.g. http://example.com
The cgiurl parameter is the url plus the path to the CGI, e.g. http://example.com/cgi/iw.cgi
Regular operation of Ikiwiki seems fine, so I can log in, edit pages and so on. As far as the more private part goes, the site is essentially just me, so there won't be pages with odd parameters in them unless I add them. :)
"""]]

View File

@ -10,7 +10,7 @@ Why doesn't the TOC appear in the edit page preview? It only appears when the p
> Fixed. --[[Joey]]
Just ran into a side effect of `\[[!toc]]` being a NOP in pages
which are inlined: pages with `\[[!template id=note text="\[[!toc]]"]]`
which are inlined: pages with `\[[!template id=note text="[[!toc]]"]]`
wound up having the note rendered in feeds as "Use this template
to insert a note into a page". Worked around this by making a local
copy of the template and removing its `<TMPL_UNLESS text>...</TMPL_UNLESS>`
@ -18,9 +18,14 @@ section. Besides needing to generate guaranteed-unique anchor names,
are there other reasons this directive couldn't be made to work on
inlined pages? --[[schmonz]]
> Workaround: `\[[!template id=note text=" \[[!toc]]"]]`
> Workaround: `\[[!template id=note text=" [[!toc]]"]]`
> (with whitespace) should work, because then Perl will consider
> the string to be a true value.
>
> Longer-term, my branch on [[bugs/template_creation_error]]
> aims to fix this sort of thing. --[[smcv]]
>> Workaround seems not to. Maybe whitespace is getting trimmed
>> along the way and it stays falsish. Interested in your branch;
>> sorry I can't offer precise feedback right now, but it looks sane
>> at a glance. --[[schmonz]]

View File

@ -0,0 +1,11 @@
A dear [[wishlist]] which would resolve [[this question|forum/ikiwiki_and_big_files]]: ikiwiki should support git-annex repositories.
I am not sure how this would work, but from my POV, it should do a `git annex get` when new commits are pushed to its bare repo. This would assume, of course, that there's another repo somewhere that ikiwiki has access to, which works for HTTP-style remotes, but could be more problematic for SSH remotes that require a key.
Another solution would be to make ikiwiki a remote itself and allow users to push big files to it. The only problem I see with this is those files would end up in the bare repository and not necessarily show up in the web rendering. Ideally, a big file pushed would be hardlinked between the two repos, but it seems [git-annex doesn't support that yet](http://git-annex.branchable.com/todo/wishlist:_use_hardlinks_for_local_clones). --[[anarcat]]
> One technical problem with this is that ikiwiki doesn't allow symlinks
> for [[security]], but git-annex relies on symlinks (unless you're in
> direct mode, but I'm not sure that's really desirable here).
> I'd like to make symlinks possible without compromising security,
> but it'll be necessary to be quite careful. --[[smcv]]

View File

@ -0,0 +1,9 @@
Hi,
I'm currently using git-annex with ikiwiki for a website of mine. [stockholm.kalleswork.net](http://stockholm.kalleswork.net). The site relies heavily on the osm and album plugins. The site just went online and is a bit of an experiment, things seem a bit fragile but works for now. (ikiwiki 3.20130904.1)(git-annex 4.20130904.1)
The trick I had to do to get git-annex, ikiwiki and the album plugin to work was to initialize an annex remote in the `$srcdir`. Then block the bare origin (ie wiki.git folder) with `annex-sync = false` and `annex-ignore = true` on **both** the server and the working laptop. This is to avoid polluting the wiki.git bare repo with annex stuff.
Another critical thing for this to work was to set the `$srcdir` on the server to direct mode `git-annex direct` before adding any content anywhere. On the laptop I can use indirect mode without problems.
For now syncing annex, pushing updates to mdwns etc all seem to work and the album plugin picks up images etc. I'm sure there are problems ahead with this setup but it does seem to work. I barely know how to use git, git-annex and ikiwiki and much less understand how it works behind the scenes. So do let me know if there are fatal flaws in my setup ;) -- Kalle