Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Krita
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Merge Requests
27
Merge Requests
27
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Jobs
Commits
Open sidebar
KDE
Krita
Commits
127857b2
Commit
127857b2
authored
Sep 18, 2018
by
Boudewijn Rempt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove places where cat doesn't need to be used
BUG:398688
parent
dc44b077
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
kundo2_aware_xgettext.sh
kundo2_aware_xgettext.sh
+4
-4
No files found.
kundo2_aware_xgettext.sh
100644 → 100755
View file @
127857b2
...
...
@@ -36,7 +36,7 @@ function add_ctxt_qtundo() {
# lastLine != "#, fuzzy" is the check for the .pot header.
# If lastLine starts with '"' the msgctxt has been split on several lines and is treated by sed above, so skip it
mv
"
${
POT_PART_QUNDOFORMAT
}
"
"
${
POT_PART_QUNDOFORMAT2
}
"
cat
"
${
POT_PART_QUNDOFORMAT2
}
"
|
awk
'
< file
"
${
POT_PART_QUNDOFORMAT2
}
"
|
awk
'
/^msgid "/ {
if (lastLine !~ /^\"/ && lastLine !~ /^msgctxt/ && lastLine != "#, fuzzy") {
print "msgctxt \"(qtundo-format)\""
...
...
@@ -80,9 +80,9 @@ function kundo2_aware_xgettext_internal() {
echo
""
>>
${
POT_PART_NORMAL
}
${
MSGCAT
}
-F
"
${
POT_PART_NORMAL
}
"
"
${
POT_PART_QUNDOFORMAT
}
"
>
${
POT_MERGED
}
MERGED_HEADER_LINE_COUNT
=
$(
cat
${
POT_MERGED
}
|
grep
"^$"
-B
100000
--max-count
=
1 |
wc
-l
)
KDE_HEADER
=
"
$(
cat
${
POT_PART_NORMAL
}
|
grep
"^$"
-B
100000
--max-count
=
1
)
"
MERGED_TAIL
=
"
$(
cat
${
POT_MERGED
}
|
tail
-n
+
$MERGED_HEADER_LINE_COUNT
)
"
MERGED_HEADER_LINE_COUNT
=
$(
< file
${
POT_MERGED
}
grep
"^$"
-B
100000
--max-count
=
1 |
wc
-l
)
KDE_HEADER
=
"
$(
< file
${
POT_PART_NORMAL
}
grep
"^$"
-B
100000
--max-count
=
1
)
"
MERGED_TAIL
=
"
$(
< file
${
POT_MERGED
}
tail
-n
+
$MERGED_HEADER_LINE_COUNT
)
"
# Print out the resulting .pot
echo
"
$KDE_HEADER
"
...
...
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