Advertisement
trocster

OCS 2.3.5 patching with recommended patches

Jan 29th, 2014
137
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 10.65 KB | None | 0 0
  1. # For list of recommended patches on http://pkp.sfu.ca/wiki/index.php/OCS_2.3.5_Recommended_Patches as of 2014-01-28
  2. # I was faced by a similar situation that OP tshore  was in http://pkp.sfu.ca/support/forum/viewtopic.php?f=14&t=10270
  3.  
  4. # Initially I tried a git clone http://github.com/pkp/ocs and submodules,checkout stable  tags etc etc, however I
  5. # quickly ran into trouble, as git merge/ git cherry-pick didn't want to play along. So this is what I settled on.
  6.  
  7. # Seems to be a handy (if somewhat laborious) way of applying patches and seeing/tracking what has changed on your
  8. # local install.
  9.  
  10. # SETUP
  11. curl -s http://pkp.sfu.ca/ocs/download/ocs-2.3.5.tar.gz | tar -zxvf -
  12. mv ocs-2.3.5/* .
  13. rm -r ocs-2.3.5/
  14. mv config.TEMPLATE.inc.php config.inc.php
  15. #chmod skipped as SuexecUserGroup in effect
  16. mkdir ../ocs-{files,public}
  17. # emacs config.inc.php # see file for instructions ?
  18. echo 'cache/' > .gitignore
  19. echo 'RedirectMatch 404 /\.git' >> .htaccess
  20. git init .
  21. git add .
  22. git commit -m 'initial commit'
  23. #I branch here just ... because (its cheaP? )
  24. git checkout -b patches
  25.  
  26.  
  27. # Bug #6900: Submissions with tags in titles truncated to '...' in submission lists
  28. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=6900
  29. curl -s http://pkp.sfu.ca/bugzilla/attachment.cgi?id=3751 | git apply
  30. #  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
  31. #                                 Dload  Upload   Total   Spent    Left  Speed
  32. #100 20408  100 20408    0     0  11359      0  0:00:01  0:00:01 --:--:-- 47131
  33. git status
  34. # On branch patches
  35. # Changes not staged for commit:
  36. #   (use "git add <file>..." to update what will be committed)
  37. #   (use "git checkout -- <file>..." to discard changes in working directory)
  38. #
  39. #       modified:   plugins/generic/staticPages/settingsForm.tpl
  40. #       modified:   templates/author/active.tpl
  41. #       modified:   templates/author/completed.tpl
  42. #       modified:   templates/comment/comments.tpl
  43. #       modified:   templates/director/schedulingQueue.tpl
  44. #       modified:   templates/director/submissionsAccepted.tpl
  45. #       modified:   templates/director/submissionsArchives.tpl
  46. #       modified:   templates/director/submissionsInReview.tpl
  47. #       modified:   templates/director/submissionsUnassigned.tpl
  48. #       modified:   templates/manager/conferenceEventLog.tpl
  49. #       modified:   templates/manager/reviewForms/reviewFormElements.tpl
  50. #       modified:   templates/reviewer/active.tpl
  51. #       modified:   templates/reviewer/completed.tpl
  52. #       modified:   templates/rt/rt.tpl
  53. #       modified:   templates/trackDirector/submissionEventLog.tpl
  54. #       modified:   templates/trackDirector/submissionEventLogEntry.tpl
  55. #       modified:   templates/trackDirector/submissionHistory.tpl
  56. #       modified:   templates/trackDirector/submissionsAccepted.tpl
  57. #       modified:   templates/trackDirector/submissionsArchives.tpl
  58. #       modified:   templates/trackDirector/submissionsInReview.tpl
  59. #
  60. # no changes added to commit (use "git add" and/or "git commit -a")
  61. git commit -am " Bug 6900: Submissions with tags in titles truncated to '...' in submission lists"
  62.  
  63.  
  64. # Bug #7425: Favicon missing on paper view and help pages
  65. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=7425
  66. curl -s http://pkp.sfu.ca/bugzilla/attachment.cgi?id=3764 | git apply
  67. git commit -am 'Bug 7425: Favicon missing on paper view and help pages'
  68.  
  69.  
  70. # Bug #7427: Favicon missing on reading tools and editor comments pages
  71. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=7427
  72. curl -s http://pkp.sfu.ca/bugzilla/attachment.cgi?id=3766 | git apply
  73. git commit -am 'Bug 7427: - Favicon missing on reading tools and editor comments pages '
  74.  
  75.  
  76. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=6495
  77. # Bug #6495: Favicon doesn't display in Internet Explorer
  78. curl -s http://pkp.sfu.ca/bugzilla/attachment.cgi?id=3771 | git apply
  79. git commit -am "Bug 6495: Favicon doesn't display in IE"
  80.  
  81.  
  82. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=7275
  83. # Bug #7275: MergeUsers errors when updating comments
  84. curl -s http://pkp.sfu.ca/bugzilla/attachment.cgi?id=3792 | git apply
  85. git commit -am "Bug 7275: MergeUsers errors when updating comments"
  86.  
  87.  
  88. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=7957
  89. # Bug #7957: login source parameter needs escaping
  90. # not is from is from pkp/lib repo, hence path substitution
  91. curl  -s http:// pkp.sfu.ca/bugzilla/attachment.cgi?id=3874  | sed -r -e 's#(a|b)/templates#a/lib/pkp/templates#g' | git apply
  92. git commit -am "Bug 7957: login source parameter needs escaping"
  93.  
  94.  
  95. # Bug 8003 - Browse by title not working
  96. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8003
  97. curl -s http://pkp.sfu.ca/bugzilla/attachment.cgi?id=3886 | git apply
  98. git commit -am 'Bug 8003: Browse by title not working'
  99.  
  100.  
  101. # Bug 8077 - Reference parameter with default
  102. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8077
  103. # note addition of .patch to commit url
  104. curl -s https://github.com/pkp/ocs/commit/ec25e9fec9dff13ce434488011964c060f84883b.patch | git apply
  105. git commit -am 'Bug 8077: Reference parameter with default'
  106.  
  107.  
  108. # Bug 8081 - Typo in UserExportDOM
  109. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8081
  110. # Comment 1 on bug page is for master branch, we are assuming ocs-stable-2_3 is the relevant branch
  111. # i.e. comment 2
  112. curl -s https://github.com/pkp/ocs/commit/9f52c6a11ee33a77807a11246b9c23d770d310e5.patch | git apply
  113. git commit -am 'Bug 8081: Typo in UserExportDOM'
  114.  
  115.  
  116. # Bug 8082 - Unable to specify sched conf path on user import CLI
  117. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8082
  118. curl -s https://github.com/pkp/ocs/commit/b21a23a1814f0434004ca7785c92cca033264f8c.patch | git apply
  119. git commit -am 'Bug 8082: Unable to specify sched conf path on user import CLI'
  120.  
  121.  
  122. # Bug 8089 - PHP fatal error when viewing Notifications
  123. # skipped, as it doesn't seem to be relevant.
  124.  
  125.  
  126. # Bug 8104 - Paper event log always lists the same user
  127. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8104
  128. curl -s https://github.com/pkp/ocs/commit/704591963863d83a989dc9347daf23a23bb0c4ba.patch | git apply
  129. git commit -am 'Bug 8104: Paper event log always lists the same user'
  130.  
  131.  
  132. # Bug 8144 - PayPal payments never complete with site restriction enabled
  133. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8144
  134. curl -s http://pkp.sfu.ca/bugzilla/attachment.cgi?id=3927 | git apply
  135. git commit -am 'Bug 8144: PayPal payments never complete with site restriction enabled'
  136.  
  137.  
  138. # Bug 8200 - OCS director submission validation overzealous in separate submission process
  139. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8200
  140. # aah, nice a hint on how to apply github commits as patches :)
  141. curl -s https://github.com/pkp/ocs/commit/c14f10dee35a42d8264ecdfe3a2c1f57d3870c37.diff| git apply
  142. git commit -am 'Bug 8200 - OCS director submission validation overzealous in separate submission process'
  143.  
  144.  
  145. # Bug 8321 - Cannot set editor version with subsequent revisions
  146. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8321
  147. # correct patch seems to be Comment 2 Alec Smecher 2013-07-18 09:45:02 PDT
  148. curl -s https://github.com/pkp/ocs/commit/3073fd99a11aa74cb311a72622cdc29f27168617.patch  | git apply
  149. git commit -am 'Bug 8321: Cannot set editor version with subsequent revisions'
  150.  
  151.  
  152. # Bug 8328 - "Author registration closed" message untranslated
  153. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8328
  154. curl -s https://github.com/pkp/ocs/commit/ef0203a5fec36b1b53c52cc3fb106d9bc799b5eb.diff | git apply
  155. git commit -am 'Bug 8328:  "Author registration closed" message untranslated'
  156.  
  157.  
  158. # Bug 8355 - Director's sort by track causes SQL error
  159. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8355
  160. curl -s https://github.com/pkp/ocs/commit/73183d814cd519af7d8ea54acda8ed8d37875b3e.patch | git apply
  161. git commit -am "Bug 8355: Director's sort by track causes SQL error"
  162.  
  163.  
  164. # Bug 7544 - session_is_registered function is removed in PHP 5.4
  165. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=7544
  166. # patches are numerous but the one you want for ocs-2_3_5 from zip is
  167. # the linked in Comment 12 Alec Smecher 2013-07-31 15:12:02 PDT
  168. curl -s https://github.com/pkp/pkp-lib/commit/be5189d450563e5e7caac322070f3a754e46d11f.patch | sed -r -e 's#classes/#lib/pkp/classes/#g' | git apply
  169. git commit -am 'Bug 7544: session_is_registered function is removed in PHP 5.4'
  170.  
  171.  
  172. # Bug 8357 - Director's Presentations sort by tracks erroneously sorts by submit date
  173. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8357
  174. # Patch associated with 'Comment 2' Alec Smecher 2013-08-02 09:17:02 PDT
  175. curl -s https://github.com/pkp/ocs/commit/02a344b1b15d75baf643f6f20f7beb2c7633c5f1.patch | git apply
  176. git commit -am "Bug 8357: Director's Presentations sort by tracks erroneously sorts by submit date"
  177.  
  178.  
  179. # Bug 8396 - File manager with path_info_disabled can explore outside files dir
  180. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8396
  181. # Patch for ocs-2_3_5 is linked in "Comment 3" Alec Smecher 2013-08-15 09:45:02 PDT
  182. curl -s https://github.com/pkp/ocs/commit/b6da8cfcf13032a29694c46bbe21a52985b987a9.patch | git apply
  183. git commit -am 'Bug 8396: File manager with path_info_disabled can explore outside files dir'
  184.  
  185.  
  186. # Bug 8400 - Temporary file MIME type detection may fail with "file" tool fallback
  187. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8400
  188. curl -s https://github.com/pkp/pkp-lib/commit/0f41aa61360adb7efd6cb151a945449ae0bb2260.diff | sed -r -e 's#(a|b)/classes#a/lib/pkp/classes#g' | git apply
  189. git commit -am 'Bug 8400: Temporary file MIME type detection may fail with "file" tool fallback'
  190.  
  191.  
  192. # Bug 7402 - Incomplete articles appear in Articles Report
  193. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=7402
  194. curl -s https://github.com/pkp/ocs/commit/35d2c63d09b03dd933cfa181a9c6e02fd79ac2f0.diff | git apply
  195. git commit -am 'Bug 7402: Incomplete articles appear in Articles Report'
  196.  
  197.  
  198. # Bug 8119 - Author acknowledgment emails may be sent without contents
  199. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8119
  200. # 2013-02-15 17:21 PST, Alec Smecher Patch against OCS 2.3.x (772 bytes, patch)
  201. curl -s http://pkp.sfu.ca/bugzilla/attachment.cgi?id=3909 | git apply
  202. # Additional patch against OCS 2.3.5 (2.21 KB, patch) 2013-12-16 10:30 PST, Alec Smecher
  203. # has some issues, part of the patch seem to already be in zip/tgz
  204. # http://pkp.sfu.ca/ocs/download/ocs-2.3.5.tar.gz so we exclude it
  205. curl -s http://pkp.sfu.ca/bugzilla/attachment.cgi?id=3980 | git apply --exclude classes/mail/MailTemplate.inc.php
  206. git commit -am 'Bug 8119: Author acknowledgment emails may be sent without contents'
  207.  
  208.  
  209. # Bug 8226 - Update it_IT countries list
  210. # http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8226
  211. # lib/pkp patch cd to correct path or replace it
  212. curl -s https://github.com/pkp/pkp-lib/commit/7ffb11de62fedfc5ed34775cff1a401c8804368f.diff | sed -r -e 's#locale/#lib/pkp/locale/#g' | git apply
  213. git commit -am 'Bug 8226: Update it_IT countries list'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement