Redmine Development¶
Prepare your Redmine development environment and keep it up to date.
- Table of contents
- Redmine Development
Installation¶
Clone repository¶
Clone the Redmine repository from GitHub:
# clone repo
(user@host):~$ git clone https://github.com/redmine/redmine
# change alias name of the remote repository
(user@host):~$ cd redmine && git remote rename origin upstream
Checkout stable branches¶
Since the master branch is Redmine's current development branch we will also checkout the last two stable branches:
# fetch all branches
(user@host):~/path/to/redmine$ git fetch upstream
# get the list of all remote branches
(user@host):~/path/to/redmine$ git branch -r
# latest stable branch
(user@host):~/path/to/redmine$ git checkout -b develop-<latest-stable-branch> upstream/<latest-stable-branch>
# previous stable branch
(user@host):~/path/to/redmine$ git checkout -b develop-<previous-stable-branch> upstream/<previous-stable-branch>
Modifications¶
We need to modify the branches to get ready for development.
IMPORTANT
All modifications need to be done in all newly checked out branches.
Create some further directories:
(user@host):~/path/to/redmine$ mkdir gem_home patches
.gitignore¶
Add some further files and directories to .gitignore
# [xmera]
.history/
.vscode/
patches/
*patch
gem_home
Commit your changes:
(user@host):~/path/to/redmine$ git add . && git commit -m "Extends .gitignore"
Update Redmine Repository¶
Due to our changes we need to update the repository by using rebase:
# update master branch
(user@host):~/path/to/redmine$ git checkout master
(user@host):~/path/to/redmine$ git pull --rebase upstream master
# update development branches
(user@host):~/path/to/redmine$ git checkout develop-<(previous|latest)-stable-branch>
(user@host):~/path/to/redmine$ git pull --rebase <(previous|latest)-stable-branch>
NOTE
In case there is a new stable branch repeat the process Checkout stable branches .