generate_package_defs.pl
changeset 1074 15428d415dba
parent 1073 ac18844eb787
equal deleted inserted replaced
1073:ac18844eb787 1074:15428d415dba
    20 # get the codelines from the packages repo
    20 # get the codelines from the packages repo
    21 opendir(DIR, "packages");
    21 opendir(DIR, "packages");
    22 my @codelines = grep(($_ !~ /^\.\.?$/ and $_ =~ /^symbian/), readdir(DIR));
    22 my @codelines = grep(($_ !~ /^\.\.?$/ and $_ =~ /^symbian/), readdir(DIR));
    23 close(DIR);
    23 close(DIR);
    24 
    24 
    25 my $packages_changeset = '';
    25 # get the changeset from the platform repo 
       
    26 my $platform_changeset = `hg -R platforms identify -i`;
       
    27 chomp $platform_changeset;
       
    28 print "-->$platform_changeset<--\n";
    26 
    29 
    27 # loop over codelines
    30 # loop over codelines
    28 for my $codeline (@codelines)
    31 for my $codeline (@codelines)
    29 {
    32 {
    30 	mkdir($codeline);
    33 	mkdir($codeline);
    55 	my $diff_cmd = "hg -R packages diff --stat";
    58 	my $diff_cmd = "hg -R packages diff --stat";
    56 	print "$diff_cmd\n";
    59 	print "$diff_cmd\n";
    57 	my @diff_output = `$diff_cmd`;
    60 	my @diff_output = `$diff_cmd`;
    58 	if (@diff_output)
    61 	if (@diff_output)
    59 	{
    62 	{
    60 		my $commit_cmd = "hg -R packages commit -m \"Update package models from auto generated system model (packages\@$packages_changeset)\" -u\"Dario Sestito <darios\@symbian.org>\"";
    63 		my $commit_cmd = "hg -R packages commit -m \"Update package models from latest system model  (platform\@$platform_changeset)\" -u\"Dario Sestito <darios\@symbian.org>\"";
    61 		print "$commit_cmd\n";
    64 		print "$commit_cmd\n";
    62 		system($commit_cmd);
    65 		system($commit_cmd);
    63 		my $push_cmd = "hg -R packages push http://darios:symbian696b\@developer.symbian.org/oss/MCL/sftools/fbf/projects/packages";
    66 		my $push_cmd = "hg -R packages push http://darios:symbian696b\@developer.symbian.org/oss/MCL/sftools/fbf/projects/packages";
    64 		print "$push_cmd\n";
    67 		print "$push_cmd\n";
    65 		system($push_cmd);
    68 		system($push_cmd);