Finally updating the readme...

This commit is contained in:
2018-06-06 10:01:30 +09:00
parent b54ce9fcbd
commit 3b238d7622
2 changed files with 23 additions and 66 deletions
+13 -5
View File
@@ -53,13 +53,19 @@ add_launcher({win32, nt}, _ZompDir) ->
add_unix_link(ZompDir) ->
Home = filename:dirname(ZompDir),
Link = filename:join(Home, "bin/zx"),
LinkH = filename:join(Home, "bin/zxh"),
HomeBin = filename:dirname(Link),
Target = filename:join(ZompDir, "zx.sh"),
Target = filename:join(ZompDir, "zx"),
TargetH = filename:join(ZompDir, "zxh"),
ok = filelib:ensure_dir(Link),
LinkCommand = "env LANG=en ln -s " ++ Target ++ " " ++ Link,
LinkCommandH = "env LANG=en ln -s " ++ TargetH ++ " " ++ LinkH,
ModeCommand = "env LANG=en chmod +x " ++ Target,
ModeCommandH = "env LANG=en chmod +x " ++ TargetH,
ok = os_cmd(LinkCommand),
ok = os_cmd(LinkCommandH),
ok = os_cmd(ModeCommand),
ok = os_cmd(ModeCommandH),
Path = os:getenv("PATH"),
Parts = string:lexemes(Path, ":"),
Message =
@@ -67,8 +73,9 @@ add_unix_link(ZompDir) ->
true ->
"A link to ~ts has been created at ~ts.~n"
"~ts seems to be in $PATH already.~n"
"You should be able to run any zomp/zx program by typing `zx` "
"from anywhere in your system.~n"
"You should be able to run any Zomp/ZX program as a normal shell "
"command by typing `zx`, or with an Erlang shell attached by "
"typing `zxh` from anywhere in your system.~n"
"Creating launchers to the link that start specific programs may be "
"conveinent.~n"
"A desktop launcher would need to run the command:~n"
@@ -79,7 +86,8 @@ add_unix_link(ZompDir) ->
"A link to ~ts has been created at ~ts. "
"~ts seems to be NOT in your $PATH. "
"You will need to add that to $PATH if you want to be able to run "
"zx by simply typing `zx` from anywhere in your system."
"zx by simply typing `zx` (or zxh to attach an Erlang shell) from "
"anywhere in your system.~n"
"Creating launchers to the link that start specific programs may be "
"conveinent.~n"
"A desktop launcher would need to run the command:~n"
@@ -108,7 +116,7 @@ os_cmd(Command) ->
zomp_dir({unix, _}) ->
Home = os:getenv("HOME"),
filename:join(Home, "zomp");
filename:join(Home, ".zomp");
zomp_dir({win32, _}) ->
Path = os:getenv("LOCALAPPDATA"),
filename:join(Path, "zomp");