diff options
author | Felix Fietkau <nbd@openwrt.org> | 2015-05-10 15:51:19 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2015-05-10 15:51:19 +0000 |
commit | 894476db48cf583f409d56999a7ddfa11da83150 (patch) | |
tree | 55cd4c41a6d1ac406c92cc4d1726e8f61f1d218e /scripts/feeds | |
parent | beecdd63b322328994c80d83bdbc18eaefe426e6 (diff) | |
download | master-187ad058-894476db48cf583f409d56999a7ddfa11da83150.tar.gz master-187ad058-894476db48cf583f409d56999a7ddfa11da83150.tar.bz2 master-187ad058-894476db48cf583f409d56999a7ddfa11da83150.zip |
scripts/feeds: add support for optionally using a full clone of git repositories
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@45668 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'scripts/feeds')
-rwxr-xr-x | scripts/feeds | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/scripts/feeds b/scripts/feeds index 785be385a9..89cb5a22c5 100755 --- a/scripts/feeds +++ b/scripts/feeds @@ -51,7 +51,7 @@ sub parse_config() { $line++; my $valid = 1; - $line[0] =~ /^src-\w+$/ or $valid = 0; + $line[0] =~ /^src-[\w-]+$/ or $valid = 0; $line[1] =~ /^\w+$/ or $valid = 0; @src = split /\s+/, $line[2]; $valid or die "Syntax error in feeds.conf, line: $line\n"; @@ -128,6 +128,13 @@ my %update_method = ( 'update' => "git pull --ff", 'controldir' => ".git", 'revision' => "git show --abbrev-commit HEAD | head -n 1 | cut -d ' ' -f 2 | tr -d '\n'"}, + 'src-git-full' => { + 'init' => "git clone '%s' '%s'", + 'init_branch' => "git clone --branch '%s' '%s' '%s'", + 'init_commit' => "git clone '%s' '%s' && cd '%s' && git checkout -b '%s' '%s' && cd -", + 'update' => "git pull --ff", + 'controldir' => ".git", + 'revision' => "git show --abbrev-commit HEAD | head -n 1 | cut -d ' ' -f 2 | tr -d '\n'"}, 'src-gitsvn' => { 'init' => "git svn clone -r HEAD '%s' '%s'", 'update' => "git svn rebase", |