{"thread":{"id":"35100","subject":"[PATCH] path-utils: Rename mingw_path function to print_path","startedAt":"2013-10-10T20:49:43Z","lastAt":"2013-10-10T20:49:43Z","messageCount":1,"participants":["Sebastian Schuberth"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"228716","messageId":"525712E7.2010608@gmail.com","threadId":"35100","inReplyTo":null,"subject":"[PATCH] path-utils: Rename mingw_path function to print_path","fromName":"Sebastian Schuberth","fromEmail":"sschuberth@gmail.com","sentAt":"2013-10-10T20:49:43Z","receivedAt":"2013-10-10T20:49:43Z","isPatch":true,"sender":{"key":"sschuberth@gmail.com","avatar":"https://avatars.githubusercontent.com/u/349154?v=4"},"body":"mingw_path was introduced in abd4284 to output a mangled path as it is\npassed as an argument to main(). But the name is misleading because\nmangling does not come from MinGW, but from MSYS [1]. As abd4284 does not\nintroduce any MSYS or MinGW specific code but just prints out argv[2] as\nit is passed to main(), give the function the more generic and less\nconfusing name \"print_path\".\n\n[1] http://www.mingw.org/wiki/Posix_path_conversion\n\nSigned-off-by: Sebastian Schuberth <sschuberth@gmail.com>\n---\n t/t0060-path-utils.sh | 4 ++--\n test-path-utils.c     | 2 +-\n 2 files changed, 3 insertions(+), 3 deletions(-)\n\ndiff --git a/t/t0060-path-utils.sh b/t/t0060-path-utils.sh\nindex 3a48de2..2bd5e32 100755\n--- a/t/t0060-path-utils.sh\n+++ b/t/t0060-path-utils.sh\n@@ -8,13 +8,13 @@ test_description='Test various path utilities'\n . ./test-lib.sh\n \n norm_path() {\n-\texpected=$(test-path-utils mingw_path \"$2\")\n+\texpected=$(test-path-utils print_path \"$2\")\n \ttest_expect_success $3 \"normalize path: $1 => $2\" \\\n \t\"test \\\"\\$(test-path-utils normalize_path_copy '$1')\\\" = '$expected'\"\n }\n \n relative_path() {\n-\texpected=$(test-path-utils mingw_path \"$3\")\n+\texpected=$(test-path-utils print_path \"$3\")\n \ttest_expect_success $4 \"relative path: $1 $2 => $3\" \\\n \t\"test \\\"\\$(test-path-utils relative_path '$1' '$2')\\\" = '$expected'\"\n }\ndiff --git a/test-path-utils.c b/test-path-utils.c\nindex bb975e4..3dd3744 100644\n--- a/test-path-utils.c\n+++ b/test-path-utils.c\n@@ -116,7 +116,7 @@ int main(int argc, char **argv)\n \t\treturn 0;\n \t}\n \n-\tif (argc == 3 && !strcmp(argv[1], \"mingw_path\")) {\n+\tif (argc == 3 && !strcmp(argv[1], \"print_path\")) {\n \t\tputs(argv[2]);\n \t\treturn 0;\n \t}\n-- \n1.8.4.msysgit.0\n"}]}