User:Mcktimo/scripts: Difference between revisions

From wiki.occupyboston.org
Jump to navigation Jump to search
No edit summary
 
(7 intermediate revisions by the same user not shown)
Line 8: Line 8:
:                                Usage:<obout>% pperl ../makeXML.pl >obXML/mw.xml
:                                Usage:<obout>% pperl ../makeXML.pl >obXML/mw.xml


====TO Move Discussion pages:====
====TO Move Discussion pages:====  
Wikispace discussion pages don't show up in the export. Pages with discussion pages have a topics page with links to another page containing the discussion on that topic. So each wiki page might have multiple topics in discussion and multiples posts comprising each topic.
 
Mediawiki also has discussion pages but each topic is put under its own <nowiki>==heading==</nowiki> so all the discussion for a page are contained in one page.


;[[/discussgrab2.php|discussgrab2.php]] :looks through directory of wiki pages, identifies which have discussion section and assembles discussions into a discussion page on mediawiki, creating an xml import file.
;[[/discussgrab2.php|discussgrab2.php]] :looks through directory of wiki pages, identifies which have discussion section and assembles discussions into a discussion page on mediawiki, creating an xml import file.
:            usage:<ob>% php discussgrab2.php >obout/obXML/dis.xml
:            usage:<ob>% php discussgrab2.php >obout/obXML/dis.xml


;[http://pathboston.com/assess/ob/obout obout] <dir>: contains page files that have been translated with movespace.pl
;[http://pathboston.com/assess/ob/obout obout] <dir>: contains (some test) page files that have been translated with movespace.pl
;[http://pathboston.com/assess/ob/occupyboston occupybosotn] <dir>: the export of wikispaces
;occupyboston <dir>: the export of wikispaces


I don't have admin privileges on the new wiki so I tried it on http://pathboston.com/hum3p/User:Mcktimo/take1/statement_of_purpose
====test page====
If you hit the discussion tab you can see how the discussion pages of wikispaces is translated
[[User:Mcktimo/take1/statement_of_purpose]]
:If you hit the discussion tab you can see how the discussion pages of wikispaces are translated

Latest revision as of 14:53, 22 October 2011

Files to move occupyboston wiki from the http://occupyboston.wikispaces.com to http://wiki.occupyboston.org

Files are also at http://pathboston.com/assess/ob

These two scripts by User:Matt get most of the work done:

movespace.pl
translates each page.
Usage:<occupyboston>% perl ../movespace.pl Education >../obout/Education
makeXML.pl
turns a directory of translated pages into MW import file
Usage:<obout>% pperl ../makeXML.pl >obXML/mw.xml

TO Move Discussion pages:

Wikispace discussion pages don't show up in the export. Pages with discussion pages have a topics page with links to another page containing the discussion on that topic. So each wiki page might have multiple topics in discussion and multiples posts comprising each topic.

Mediawiki also has discussion pages but each topic is put under its own ==heading== so all the discussion for a page are contained in one page.

discussgrab2.php
looks through directory of wiki pages, identifies which have discussion section and assembles discussions into a discussion page on mediawiki, creating an xml import file.
usage:<ob>% php discussgrab2.php >obout/obXML/dis.xml
obout <dir>
contains (some test) page files that have been translated with movespace.pl
occupyboston <dir>
the export of wikispaces

test page

User:Mcktimo/take1/statement_of_purpose

If you hit the discussion tab you can see how the discussion pages of wikispaces are translated