mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
Feature #1005
- Applied patch for feature #1005, which prevents the update-holidays.pl script from creating duplicate holidays (thanks to Jörg Plate). Signed-off-by: Paul Beckingham <paul@beckingham.net>
This commit is contained in:
parent
a15be33713
commit
26420d74c2
3 changed files with 5 additions and 0 deletions
1
AUTHORS
1
AUTHORS
|
@ -72,6 +72,7 @@ The following submitted code, packages or analysis, and deserve special thanks:
|
||||||
Christoph Robbert
|
Christoph Robbert
|
||||||
Oleksii Tsai
|
Oleksii Tsai
|
||||||
Louis-Claude Canon
|
Louis-Claude Canon
|
||||||
|
Jörg Plate
|
||||||
|
|
||||||
Thanks to the following, who submitted detailed bug reports and excellent
|
Thanks to the following, who submitted detailed bug reports and excellent
|
||||||
suggestions:
|
suggestions:
|
||||||
|
|
|
@ -6,6 +6,8 @@
|
||||||
Features
|
Features
|
||||||
+ Feature #516, which allows the duplication of completed tasks (thanks to
|
+ Feature #516, which allows the duplication of completed tasks (thanks to
|
||||||
Peter De Poorter, Ethan Schoonover).
|
Peter De Poorter, Ethan Schoonover).
|
||||||
|
+ Applied patch for feature #1005, which prevents the update-holidays.pl script
|
||||||
|
from creating duplicate holidays (thanks to Jörg Plate).
|
||||||
+ Added the new 'indented' format for the 'project' attribute.
|
+ Added the new 'indented' format for the 'project' attribute.
|
||||||
+ The 'projects' report now uses 'project.indented' format.
|
+ The 'projects' report now uses 'project.indented' format.
|
||||||
+ The 'summary' report now uses 'project.indented' format.
|
+ The 'summary' report now uses 'project.indented' format.
|
||||||
|
|
|
@ -161,6 +161,7 @@ exit (1) if !defined $data || $data eq '';
|
||||||
# Filter the holidays according to @regions.
|
# Filter the holidays according to @regions.
|
||||||
my $id = 1;
|
my $id = 1;
|
||||||
my $content;
|
my $content;
|
||||||
|
my %seen;
|
||||||
for my $holiday (split /\n/ms, $data)
|
for my $holiday (split /\n/ms, $data)
|
||||||
{
|
{
|
||||||
my $parsed = from_json ($holiday);
|
my $parsed = from_json ($holiday);
|
||||||
|
@ -172,6 +173,7 @@ for my $holiday (split /\n/ms, $data)
|
||||||
(@regions > 0 && ($parsed->{'region'} eq '' ||
|
(@regions > 0 && ($parsed->{'region'} eq '' ||
|
||||||
exists $region_hash{$parsed->{'region'}})))
|
exists $region_hash{$parsed->{'region'}})))
|
||||||
{
|
{
|
||||||
|
next if $seen{ $parsed->{'description'} . ':' . $parsed->{'date'} }++;
|
||||||
$content .= "holiday.${locale}${id}.name=" . $parsed->{'description'} . "\n" .
|
$content .= "holiday.${locale}${id}.name=" . $parsed->{'description'} . "\n" .
|
||||||
"holiday.${locale}${id}.date=" . $parsed->{'date'} . "\n";
|
"holiday.${locale}${id}.date=" . $parsed->{'date'} . "\n";
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue