Plugins
Plugin list
A full list of available Redmine plugins can be found at the Plugin Directory.
More plugins (some in very early development), which are not listed at the Plugin Directory but are publicly available on GitHub, can be found using a search like this.
Installing a plugin
1. Copy your plugin directory into #{RAILS_ROOT}/plugins
(Redmine 2.x) or #{RAILS_ROOT}/vendor/plugins
(Redmine 1.x). If you are downloading the plugin directly from GitHub, you can do so by changing into your plugin directory and issuing a command like git clone git://github.com/user_name/name_of_the_plugin.git
.
2. If the plugin requires a migration, run the following command in #{RAILS_ROOT}
to upgrade your database (make a db backup before).
2.1. For Redmine 1.x:
rake db:migrate_plugins RAILS_ENV=production
2.2. For Redmine 2.x:
rake redmine:plugins:migrate RAILS_ENV=production
3. Restart Redmine
You should now be able to see the plugin list in Administration -> Plugins and configure the newly installed plugin (if the plugin requires to be configured).
Uninstalling a plugin
1. If the plugin required a migration, run the following command to downgrade your database (make a db backup before):
1.1. For Redmine 1.x:
rake db:migrate:plugin NAME=plugin_name VERSION=0 RAILS_ENV=production
1.2. For Redmine 2.x:
rake redmine:plugins:migrate NAME=plugin_name VERSION=0 RAILS_ENV=production
1.3 For Redmine 3.x
Redmine提供了比較豐富的插件,介紹幾個插件的安裝。RM.2.3是目前最新版本,使用的是bitnami redmine一鍵安裝
下載zip包,解壓文件夾名為:redmine_backlogs
放到
redmine-3.0.3-0\apps\redmine\htdocs\plugins\文件夾下
cmd到redmine-3.0.3-0目錄,運行use_redmine命令
彈出新的cmd,跳轉到redmine-3.0.3-0\apps\redmine\htdocs
運行下面命令:
D:\Bitnami\redmine-3.0.3-0\apps\redmine\htdocs>bundle exec rake redmine:plugins:
migrate RAILS_ENV=production
或
D:\Bitnami\redmine-3.0.3-0\apps\redmine\htdocs>bundle exec rake redmine:plugins RAILS_ENV=production --trace
轉到管理-插件(redmine backlogs )-配置,進行配置
重啟服務即可
1. https://github.com/pharmazone/redmine_charts2 下載壓縮包
2.解壓,放到plugins下面,改名redmine_charts2
3.https://github.com/pullmonkey/open_flash_chart 下載壓縮包
4.解壓,放到plugins目錄下面,改名為open_flash_chart
5.將open_flash_chart目錄下的asserts目錄拷貝到public\plugin_assets目錄下,改名為open_flash_chart
6.cd到htdocs目錄下,執行 rake redmine:plugins RAILS_ENV=production 命令
7.重啟redmine,管理員登錄后配置,即可使用
安裝gem in windows:
1. 下載gem.zip;
2. 解壓;
3. cd 解壓目錄;
4. C:\Users\win7\Desktop\climate_control-0.0.3>gem build climate_control.gemspec
5. 生成:climate_control-0.0.3.gem文件;
6. C:\Users\win7\Desktop\climate_control-0.0.3>gem install climate_control-0.0.3.gem
安裝完成。
Linux:
安裝插件:
cd redmine
./use_redmine
cd /apps\redmine\htdocs\plugins
git clone https://github.com/scrum2b/scrum2b.git
bundle install
bundle exec rake redmine:plugins:migrate RAILS_ENV=production
service nginx restart
重啟\Redmine服務:
To start/stop/restart application on Linux you can use the included ctlscript.sh utility, as shown below: ./ctlscript.sh (start|stop|restart) ./ctlscript.sh (start|stop|restart) mysql ./ctlscript.sh (start|stop|restart) apache ./ctlscript.sh (start|stop|restart) redmine ./ctlscript.sh (start|stop|restart) subversion
git clone git://github.com/backlogs/redmine_backlogs.git (git已經在前面安裝railinstaller的過程中安裝過了)
2. Remove your plugin from the plugins folder: #{RAILS_ROOT}/plugins
(Redmine 2.x) or #{RAILS_ROOT}/vendor/plugins
(Redmine 1.x)..
3. Restart Redmine
Writing plugins
There is a step-by-step tutorial about writing a plugin. Some more (detailed) information is collected and stored in the "plugin internals" page.
More (general) developer information can be found in the Redmine Developer Guide.
Migrating Plugins
There are changes in Plugins API or new Rails requirements which need to be considered if you want to use plugin from prior version of redmine.
In any case it's proposed to update and migrate redmine core system first without plugins and then if stable try to drop in one by one, to know where problems come from if any.
Consideration towards plugins which overwrite views completly because of bad coding style or there is no "hook" available shall be made in any case. Maybe you can collect and write down plugin references here which are of this type.
Let's start with..
Redmine 1.3 > 1.4
- routes.rb which defines url to controller (parameter, action) mapping must be created in <plugin>/config/routes.rb
ARCondition
is gone with no replacementTabularFormBuilder
is nowRedmine::Views::LabelledFormBuilder
- defining your own context menus now requires
helper :context_menus
in the respective controller - of course,
returning
is deprecated in favor oftap
- if you're doing anything with repos check it twice, because there can be multiple repos now per project
Project#visible_by
is deprecated and replaced byProject#visible_condition