2015年11月21日 星期六

Ubuntu安裝Redmine(7) --- Plugin安裝

Redmine 雖然已具備很功能,但外掛程式也是Redmine重要使用的一環,筆者會將目前常用的外掛程式、安裝與移除外掛程式整理於下。
1. Redmine - Code Review
    對開發人員提交的代碼進行線上review。
2. Advanced Roadmap
   對roadmap view進行了功能強化,可顯示每個具體version或者milestone的詳細工數和任務。
3. ezFAQ
   為redmine增加FAQ管理技能。
4. Charts
   為redmine增加了圖表功能。
5. Graph
   為redmine增加了圖表功能和Charts可以一起使用。
6. Kanban
   為redmine增加了一個白板view,方便管理者對issue進行管理。
7. WorkTime
   強大的工數管理外掛程式。
8. Wiki Extensions Plugin
   為撰寫wiki提供了許多擴展技能。
9. Time Tracker
   提供一對time start/stop按鈕,方便對工數進行精確統計。
10. Close Issue Button
   為issue view增加了一個close按鈕, 方便關閉issue。
一般的外掛程式安裝方法,需參照redmine wiki即可。
11. Redmine - OpenID Selector Plugin
   可由Google或Yahoo帳號進行註冊及登入。

12. Redmine_ckeditor
可代替Redmine預設文字編輯功能。


安裝Redmine plugin
Step 1. 外掛程式存放點
Redmine 2.x、Redmine 3.x 版本
#{RAILS_ROOT}/plugins
{RAILS_ROOT}位置就是Redmine安裝的資料夾路徑
/var/www/redmine/plugins/
or
/usr/share/redmine/plugins/

Redmine 1.x 版本
#{RAILS_ROOT}/vendor/plugins
{RAILS_ROOT}位置就是Redmine安裝的資料夾路徑
/var/www/redmine/vendor/plugins/
or
/usr/share/redmine/vendor/plugins/

目前安裝Redmine版本是 3.1.2
cd /var/www/redmine_test/public
wget https://bitbucket.org/haru_iida/redmine_code_review/downloads/redmine_code_review-0.6.3.zip
unzip redmine_code_review-0.6.3.zip

Step 2. 安裝外掛程式
Redmine 2.x、Redmine 3.x 版本
rake redmine:plugins:migrate RAILS_ENV=production

Redmine 1.x 版本
rake db:migrate_plugins RAILS_ENV=production

Step 3. 重啟Redmine
Service apache2 restart


如果外掛程式來源是GitHub,請使用以下指令下載
git clone git://github.com/user_name/name_of_the_plugin.git 資料夾名稱
git clone git://github.com/user_name/name_of_the_plugin.git projects_table
rake db:migrate_plugins RAILS_ENV=production

rake db:migrate_plugins NAME=projects_table RAILS_ENV=production
以上兩者差異在於有指定資料夾者,只會針對資料夾的plugin進行安裝,沒有指定資料夾者,會將public全部的plugin全部安裝。



移除Redmine plugin Step 1.
Redmine 2.x、Redmine 3.x 版本
rake redmine:plugins:migrate NAME=外掛程式名稱(文件夾名稱) VERSION=0 RAILS_ENV=production

Redmine 1.x 版本
rake db:migrate:plugin NAME=外掛程式名稱(文件夾名稱) VERSION= 0 RAILS_ENV=production

Step 2. 清除外掛程式
Redmine 2.x、Redmine 3.x 版本
#{RAILS_ROOT}/plugins

Redmine 1.x 版本
#{RAILS_ROOT}/vendor/plugins

Step 3. 重啟Redmine
Service apache2 restart


參考資料