From f3458babb6ad639fe17d11b6073373449d8323ca Mon Sep 17 00:00:00 2001 From: Offray Luna Date: Fri, 9 Oct 2020 13:22:59 -0500 Subject: [PATCH] Adding platform specific commands for exportation before testing on Windows. --- .../Grafoscopio-Utils/Markdown.class.st | 23 ++++++++++--------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/repository/Grafoscopio-Utils/Markdown.class.st b/repository/Grafoscopio-Utils/Markdown.class.st index bda223a..508ec56 100644 --- a/repository/Grafoscopio-Utils/Markdown.class.st +++ b/repository/Grafoscopio-Utils/Markdown.class.st @@ -72,17 +72,18 @@ Markdown >> exportMetadataAsJson [ in '.local/share/Grafoscopio/Scripts' should be developed in the near future." | output luaScript | luaScript := FileLocator home / '.local/share/Brea/scripts/meta-to-json.lua'. - OSSUnixSubprocess new - workingDirectory: self file parent fullName; - command: 'pandoc'; - arguments: { '--lua-filter=', luaScript fullName . self file basename }; - redirectStdout; - redirectStdin; - runAndWaitOnExitDo: [ :process :outString :errString | - output := process isSuccess - ifTrue: [ outString ] - ifFalse: [ errString ] - ]. + Smalltalk platformName = 'unix' ifTrue: [ + OSSUnixSubprocess new + workingDirectory: self file parent fullName; + command: 'pandoc'; + arguments: { '--lua-filter=', luaScript fullName . self file basename }; + redirectStdout; + redirectStdin; + runAndWaitOnExitDo: [ :process :outString :errString | + output := process isSuccess + ifTrue: [ outString ] + ifFalse: [ errString ] + ]]. ^ output correctAccentedCharacters ]