Skip to content

Commit 2a30bdd

Browse files
lexmagwhatyouhide
authored andcommitted
Replace backticks with quotes in the PO info comment (#220)
1 parent 6ece04c commit 2a30bdd

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

lib/gettext/merger.ex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,13 @@ defmodule Gettext.Merger do
77
alias Gettext.Fuzzy
88

99
@new_po_informative_comment """
10-
## `msgid`s in this file come from POT (.pot) files.
10+
## "msgid"s in this file come from POT (.pot) files.
1111
##
12-
## Do not add, change, or remove `msgid`s manually here as
12+
## Do not add, change, or remove "msgid"s manually here as
1313
## they're tied to the ones in the corresponding POT file
1414
## (with the same domain).
1515
##
16-
## Use `mix gettext.extract --merge` or `mix gettext.merge`
16+
## Use "mix gettext.extract --merge" or "mix gettext.merge"
1717
## to merge POT files into PO files.
1818
"""
1919

test/gettext/merger_test.exs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ defmodule Gettext.MergerTest do
384384
assert new_po.file == new_po_path
385385
assert new_po.headers == ["Language: it\n", "Plural-Forms: nplurals=1\n"]
386386

387-
assert ["## `msgid`s in this file come from POT (.pot) files.", "##" | _] =
387+
assert ["## \"msgid\"s in this file come from POT (.pot) files.", "##" | _] =
388388
new_po.top_of_the_file_comments
389389

390390
assert [%Translation{} = t, %PluralTranslation{} = pt, %Translation{} = ct] =

test/mix/tasks/gettext.merge_test.exs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ defmodule Mix.Tasks.Gettext.MergeTest do
107107
msgstr ""
108108
"""
109109

110-
assert String.starts_with?(new_po, "## `msgid`s in this file come from POT")
110+
assert String.starts_with?(new_po, "## \"msgid\"s in this file come from POT")
111111
end
112112

113113
test "passing just a dir merges with PO files in every locale" do
@@ -161,7 +161,7 @@ defmodule Mix.Tasks.Gettext.MergeTest do
161161
capture_io(fn ->
162162
run([@priv_path, "--locale", "en"])
163163
contents = read_file("en/LC_MESSAGES/inf.po")
164-
assert contents =~ "## `msgid`s in this file"
164+
assert contents =~ "## \"msgid\"s in this file"
165165

166166
# Running the task again without having change the PO file shouldn't
167167
# remove the informative comment.

0 commit comments

Comments
 (0)