To check out this repository please hg clone the following URL, or open the URL using EasyMercurial or your preferred Mercurial client.
root / app / models / repository / filesystem.rb @ 1298:4f746d8966dd
History | View | Annotate | Download (1.41 KB)
| 1 | 441:cbce1fd3b1b7 | Chris | # Redmine - project management software
|
|---|---|---|---|
| 2 | 1295:622f24f53b42 | Chris | # Copyright (C) 2006-2013 Jean-Philippe Lang
|
| 3 | 0:513646585e45 | Chris | #
|
| 4 | # FileSystem adapter
|
||
| 5 | # File written by Paul Rivier, at Demotera.
|
||
| 6 | #
|
||
| 7 | # This program is free software; you can redistribute it and/or
|
||
| 8 | # modify it under the terms of the GNU General Public License
|
||
| 9 | # as published by the Free Software Foundation; either version 2
|
||
| 10 | # of the License, or (at your option) any later version.
|
||
| 11 | 441:cbce1fd3b1b7 | Chris | #
|
| 12 | 0:513646585e45 | Chris | # This program is distributed in the hope that it will be useful,
|
| 13 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
| 14 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||
| 15 | # GNU General Public License for more details.
|
||
| 16 | 441:cbce1fd3b1b7 | Chris | #
|
| 17 | 0:513646585e45 | Chris | # You should have received a copy of the GNU General Public License
|
| 18 | # along with this program; if not, write to the Free Software
|
||
| 19 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||
| 20 | |||
| 21 | 1136:51d7f3e06556 | chris | require_dependency 'redmine/scm/adapters/filesystem_adapter'
|
| 22 | 0:513646585e45 | Chris | |
| 23 | class Repository::Filesystem < Repository |
||
| 24 | attr_protected :root_url
|
||
| 25 | validates_presence_of :url
|
||
| 26 | |||
| 27 | 1115:433d4f72a19b | Chris | def self.human_attribute_name(attribute_key_name, *args) |
| 28 | attr_name = attribute_key_name.to_s |
||
| 29 | 441:cbce1fd3b1b7 | Chris | if attr_name == "url" |
| 30 | attr_name = "root_directory"
|
||
| 31 | end
|
||
| 32 | 1115:433d4f72a19b | Chris | super(attr_name, *args)
|
| 33 | 245:051f544170fe | Chris | end
|
| 34 | |||
| 35 | def self.scm_adapter_class |
||
| 36 | 0:513646585e45 | Chris | Redmine::Scm::Adapters::FilesystemAdapter |
| 37 | end
|
||
| 38 | 245:051f544170fe | Chris | |
| 39 | 0:513646585e45 | Chris | def self.scm_name |
| 40 | 'Filesystem'
|
||
| 41 | end
|
||
| 42 | 245:051f544170fe | Chris | |
| 43 | 441:cbce1fd3b1b7 | Chris | def supports_all_revisions? |
| 44 | false
|
||
| 45 | end
|
||
| 46 | |||
| 47 | 0:513646585e45 | Chris | def fetch_changesets |
| 48 | nil
|
||
| 49 | end
|
||
| 50 | end |