Closed davidak closed 4 years ago
According to the unix philosophy, you should be able to pipe the output of a tool into another. With the output of this script, it is not possible.
The actual output of ./codimd import test.md is
./codimd import test.md
Found. Redirecting to https://pad.nixnet.services/gNvbypueQ6awH73V3nx_jw
(don't forget to update usage information when this is changed)
Use awk to manipulate the text:
./codimd import test.md | awk '{print $4}' https://pad.nixnet.services/zKOoDxhQTuaT4dnJAybrfw
This is a bug, not an intentional design, see #31.
It's supposed to return just the note ID, then the user can get the url from that themselves by concatenating it with $CODIMD_SERVER.
$CODIMD_SERVER
According to the unix philosophy, you should be able to pipe the output of a tool into another. With the output of this script, it is not possible.
The actual output of
./codimd import test.md
isFound. Redirecting to https://pad.nixnet.services/gNvbypueQ6awH73V3nx_jw
(don't forget to update usage information when this is changed)
Workaround
Use awk to manipulate the text: