summaryrefslogtreecommitdiffstats
path: root/app/models/repository
Commit message (Collapse)AuthorAgeFilesLines
* scm: mercurial: git: save parents in creating changesets (#10470)Toshi MARUYAMA2012-04-032-12/+6
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9311 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: use Changeset#create and Changeset#create_change as same with ↵Toshi MARUYAMA2012-03-291-13/+8
| | | | | | Subversion and Mercurial git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9290 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: mercurial: transaction for each imported revisions (#10470)Toshi MARUYAMA2012-03-291-7/+9
| | | | | | | | Subversion transaction switched at r2563. Subversion and Mercurial have a sequential revision number. So, Mercurial can use the same logic with Subversion. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9288 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: add the comment of the reason to scan database in fetching every ↵Toshi MARUYAMA2012-03-291-0/+14
| | | | | | time (#10470) git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9287 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: fix typo in fetching revisions comment.Toshi MARUYAMA2012-03-291-1/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9286 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: fix model source indents (#10470)Toshi MARUYAMA2012-03-281-41/+41
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9284 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: process new git revisions all at once rather than per branch (#10470)Toshi MARUYAMA2012-03-281-35/+22
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9283 e93f8b46-1217-0410-a6f0-8f06a7374b81
* remove trailing white-space from app/models/repository/git.rbToshi MARUYAMA2012-03-071-2/+2
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9145 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: performance improvements in fetching revisions (#8857, #9472)Toshi MARUYAMA2012-03-071-29/+61
| | | | | | | | | | | | | | | | | | Parse a revision for a given branch, just if we haven't parsed it for any branches before. Moved the db check to for existing revisions into a grouped search. Search for many revisions at once: this reduces db load. Revisions are grouped into sets of 100. This is to improve memory consumption. There will be just one query instead of each 100. The above two methods significantly increase parsing speed. Test case was a git repo with 6000+ commits on a master branch, and several other branches originating for master. Speed improved from 1.4h to 18min. Contributed by Gergely Fábián. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9144 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: reduce saving heads times in fetching revisions (#8857, #9472)Toshi MARUYAMA2012-03-071-3/+15
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9143 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: backout r8839 (#8857)Toshi MARUYAMA2012-03-071-39/+28
| | | | | | call "git log" only once instead of per branch in fetching revisions. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9142 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: backout r8840 (#8857, #9472)Toshi MARUYAMA2012-03-071-7/+2
| | | | | | reduce saving heads times in fetching revisions. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9141 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Rails 3.1 compatibility (order declared on association takes precedence).Jean-Philippe Lang2012-02-261-3/+2
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9015 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Rails3: scm: mercurial: use .to_s for overriding human_attribute_name parameterToshi MARUYAMA2012-02-241-1/+1
| | | | | | On Rails 3.0.11, parameter is symbol not string in activerecord validation. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8976 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Rails3: scm: git: use .to_s for overriding human_attribute_name parameterToshi MARUYAMA2012-02-241-1/+1
| | | | | | On Rails 3.0.11, parameter is symbol not string in activerecord validation. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8975 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Rails3: scm: filesystem: use .to_s for overriding human_attribute_name parameterToshi MARUYAMA2012-02-241-1/+1
| | | | | | On Rails 3.0.11, parameter is symbol not string in activerecord validation. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8974 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Rails3: scm: darcs: use .to_s for overriding human_attribute_name parameterToshi MARUYAMA2012-02-241-1/+1
| | | | | | On Rails 3.0.11, parameter is symbol not string in activerecord validation. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8973 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Rails3: scm: cvs: use .to_s for overriding human_attribute_name parameterToshi MARUYAMA2012-02-241-1/+1
| | | | | | On Rails 3.0.11, parameter is symbol not string in activerecord validation. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8972 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Rails3: scm: bazaar: use .to_s for overriding human_attribute_name parameterToshi MARUYAMA2012-02-241-1/+1
| | | | | | On Rails 3.0.11, parameter is symbol not string in activerecord validation. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8971 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: mercurial: use to_s for revision in find_changeset_by_name methodToshi MARUYAMA2012-02-231-5/+6
| | | | | | | | | | | | On Rails 3.0.11, functional test fails. <pre> Error: test_diff_two_revs(RepositoriesMercurialControllerTest) NoMethodError: undefined method `empty?' for 4:Fixnum app/models/repository/mercurial.rb:76:in `find_changeset_by_name' </pre> git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8938 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: reduce saving heads times in fetching revisions (#8857, #9472)Toshi MARUYAMA2012-02-111-2/+7
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8840 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: call "git log" only once instead of per branch in fetching ↵Toshi MARUYAMA2012-02-111-28/+39
| | | | | | revisions (#8857) git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8839 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: raise exception if "git log" is error and block is given in lib ↵Toshi MARUYAMA2012-02-101-12/+16
| | | | | | revision method (#8857) git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8837 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: add model method to get heads from extra_info branches hash (#8857)Toshi MARUYAMA2012-02-091-0/+7
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8816 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: split fetch_changesets methodToshi MARUYAMA2012-02-081-0/+5
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8814 e93f8b46-1217-0410-a6f0-8f06a7374b81
* human_attribute_name accepts optional argument.Jean-Philippe Lang2011-12-186-12/+12
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8286 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: model: mercurial: set revision graph support true (#5501)Toshi MARUYAMA2011-11-031-0/+4
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7718 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: model: git: set revision graph support true (#5501)Toshi MARUYAMA2011-11-031-0/+4
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7717 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: mercurial: model: save parent/child relation for changesets (#5501)Toshi MARUYAMA2011-11-031-0/+5
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7713 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: model: save parent/child relation for changesets (#5501)Toshi MARUYAMA2011-11-031-1/+6
| | | | | | Contributed by Jan Topiński. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7711 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: fix typo of comments about fetching revisions (#9472)Toshi MARUYAMA2011-10-271-1/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7660 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: recovery and improve comments of fetching from 1.1 about harmful ↵Toshi MARUYAMA2011-10-271-0/+11
| | | | | | influence that git does not have the revision number (#9472) git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7658 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: return saved revision at model "save_revision" (#5501)Toshi MARUYAMA2011-10-251-0/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7654 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: use to_s for branches at model (#5501)Toshi MARUYAMA2011-10-251-1/+2
| | | | | | | "scm.branches" will extend to have the revision for the branch. no "to_s" will have a problem. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7653 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: mercurial: do nothing in fetching if info is nil (#8777).Toshi MARUYAMA2011-07-111-0/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@6246 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: catch exception in model default_branch() (#8458, #6713).Toshi MARUYAMA2011-07-101-0/+3
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@6220 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: mercurial: remove return value from model fetch_changesets().Toshi MARUYAMA2011-07-101-1/+0
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@6219 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: return nil at model default_branch and override at git model (#8458, ↵Toshi MARUYAMA2011-06-301-0/+4
| | | | | | | | | | #6713). Redmine Git and Mercurial adapter support *branches*. Mercurial default branch is *dafault*. But, it is popular to show all revisions on the top page for Mercurial GUI. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@6130 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: mercurial: code clean up model.Toshi MARUYAMA2011-05-261-13/+16
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5931 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: mercurial: use regexp %r{} instead of // in model latest_changesets_cond().Toshi MARUYAMA2011-05-261-1/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5930 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: brush up model fetch_changesets() comment.Toshi MARUYAMA2011-05-191-5/+6
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5858 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: use hash#dup for extra_info in model fetch_changesets().Toshi MARUYAMA2011-05-191-1/+2
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5856 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: set revisions ordering inconsistent in existing database (#5357).Toshi MARUYAMA2011-05-191-1/+11
| | | | | | | Between version 0.9 r2840 (#1406) and version 1.2 r5073 (#7821, #5357), git revisions are stored as *C-B-A-F-E-D* in database. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5853 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: bazaar: code clean up model.Toshi MARUYAMA2011-05-181-6/+11
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5834 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: fix fetching 7 days problem (#7146, #6013).Toshi MARUYAMA2011-05-131-29/+16
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5788 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: show only filename and filesize if setting of reporting last ↵Toshi MARUYAMA2011-05-131-0/+4
| | | | | | commit is disable (#8365, #7047). git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5775 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: git: get "extra_report_last_commit" value from extra_info (#8365, #7047).Toshi MARUYAMA2011-05-131-1/+4
| | | | | | | Browsing repository tree performance problem is git only. So, adding new "report_last_commit" column is very expensive. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5768 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: mercurial: remove trailing white-spaces from model source.Toshi MARUYAMA2011-05-121-5/+5
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5756 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: darcs: code clean up model.Toshi MARUYAMA2011-05-121-7/+7
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5755 e93f8b46-1217-0410-a6f0-8f06a7374b81
* scm: filesystem: code clean up model.Toshi MARUYAMA2011-05-121-5/+4
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5754 e93f8b46-1217-0410-a6f0-8f06a7374b81