File tree Expand file tree Collapse file tree 1 file changed +12
-7
lines changed Expand file tree Collapse file tree 1 file changed +12
-7
lines changed Original file line number Diff line number Diff line change 11Red []
22
3- CURRENT_CMD : to-block system /script/args
3+ CURRENT-CMD : to-block system /script/args
44HOTLIB-PATH: to-red-file rejoin [get-env either system /platform == 'Windows ["USERPROFILE" ]["HOME" ] %/.hot/ ]
55
66foreach file read HOTLIB-PATH [
@@ -22,18 +22,23 @@ cmd: context [
2222]
2323
2424help : does [
25- foreach [f _] to-block do cmd [
26- print to-string rejoin ["cmd/" f]
25+ fn-name-rule: charset [#"a" - #"z" #"-" ]
26+ foreach [fn _] to-block do cmd [
27+ if parse to-string fn [some fn-name-rule] [
28+ print to-string rejoin ["cmd/" fn]
29+ ]
2730 ]
2831 foreach file read HOTLIB-PATH [
29- c: replace to-string file ".red" ""
30- foreach [f _] to-block do to-word c [
31- print to-string rejoin [c "/" f]
32+ ctx: replace to-string file ".red" ""
33+ foreach [fn _] to-block do to-word ctx [
34+ if parse to-string fn [some fn-name-rule] [
35+ print to-string rejoin [ctx "/" fn]
36+ ]
3237 ]
3338 ]
3439]
3540
3641;
3742; Main
3843;
39- do CURRENT_CMD
44+ do CURRENT-CMD
You can’t perform that action at this time.
0 commit comments