Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
scripts
mahara-scripts
Commits
f430cb21
Commit
f430cb21
authored
Jun 17, 2011
by
Richard Mansfield
Browse files
Allow country part to be uppercase when checking presence of langconfig.php file
parent
d83e41cd
Changes
1
Hide whitespace changes
Inline
Side-by-side
mahara-langpacks/langpacks.pl
View file @
f430cb21
...
...
@@ -232,7 +232,24 @@ foreach my $lang (@langkeys) {
}
}
elsif
(
$repotype
eq
'
gitorious
'
&&
-
f
"
$currentdir
/lang/
$lang
.utf8/langconfig.php
"
)
{
elsif
(
$repotype
eq
'
gitorious
'
)
{
# .po is not available, so this is a php langpack
my
$langconfig
=
0
;
if
(
$lang
=~
m/^([a-z]{2})_([a-z]{2})$/
)
{
$langconfig
=
-
f
"
$currentdir
/lang/$1_
"
.
lc
(
$
2
)
.
'
.utf8/langconfig.php
'
||
-
f
"
$currentdir
/lang/$1_
"
.
uc
(
$
2
)
.
'
.utf8/langconfig.php
';
}
else
{
$langconfig
=
-
f
"
$currentdir
/lang/
$lang
.utf8/langconfig.php
";
}
if
(
!
$langconfig
)
{
print
STDERR
"
$lang
$branch
: Couldn't find lang/
$lang
.utf8/langconfig.php in
$currentdir
; skipping
\n
";
next
;
}
$last
->
{
$lang
}
->
{
branches
}
->
{
$branch
}
->
{
type
}
=
'
mahara
';
...
...
@@ -277,7 +294,7 @@ foreach my $lang (@langkeys) {
}
}
else
{
print
STDERR
"
$lang
$branch
: Couldn't find mahara/
$lang
.po or lang/
$lang
.utf8/langconfig.php in
$currentdir
; skipping
";
print
STDERR
"
$lang
$branch
: Couldn't find mahara/
$lang
.po or lang/
$lang
.utf8/langconfig.php in
$currentdir
; skipping
\n
";
next
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment