From cc857cd611e5c35613bedc5991bd3df863239feb Mon Sep 17 00:00:00 2001 From: anki-code Date: Fri, 6 Mar 2020 22:08:59 +0300 Subject: [PATCH 1/4] Update README.md --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index dc5a4f6..34ece02 100644 --- a/README.md +++ b/README.md @@ -3,14 +3,14 @@ 1. Fork this repo to create your [xxh](https://github.com/xxh/xxh) shell entrypoint. 2. Rename your repo to `xxh-shell-myshell` 3. Install [xxh](https://github.com/xxh/xxh) and run once to creating `~/.xxh` -4. `cd ~/.xxh/shells && git clone https://github.com/you/xxh-shell-myshell && cd xxh-shell-myshell` +4. `cd ~/.xxh/xxh/shells && git clone https://github.com/you/xxh-shell-myshell && cd xxh-shell-myshell` 5. Edit `build.xsh` script 6. Edit `entrypoint.sh` script 7. Run `./build.xsh` -8. Try to connect `xxh myhost +s xxh-shell-myshell` +8. Try to connect `xxh myhost +s xxh-shell-myshell` (add `+if` to force reinstall) 9. If everything works commit and push your changes 10. You rock! [Tell us about your work](https://gitter.im/xonssh-xxh/community)! ## xxh-shell example -Real life example of creating xxh-shell and xxh-plugins you could find in [xxh-shell-xonsh-appimage](https://github.com/xxh/xxh-shell-xonsh-appimage). \ No newline at end of file +Real life example of creating xxh-shell and xxh-plugins you could find in [xxh-shell-xonsh-appimage](https://github.com/xxh/xxh-shell-xonsh-appimage). From 66d4fa1c9a42fa63eacc0745ee0ac4bb3abba61f Mon Sep 17 00:00:00 2001 From: anki-code Date: Sat, 7 Mar 2020 10:23:09 +0300 Subject: [PATCH 2/4] Update build.xsh --- build.xsh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/build.xsh b/build.xsh index 66c792d..49bc4da 100755 --- a/build.xsh +++ b/build.xsh @@ -16,7 +16,9 @@ rm -rf @(build_dir)/ mkdir -p @(build_dir) cd @(build_dir) +cp @(script_dir / 'entrypoint.sh') @(build_dir)/ + if p'your_portable_shell'.exists(): eprint('SKIP: Portable shell already builded') else: - wget https://your_portable_shell \ No newline at end of file + wget https://your_portable_shell From 777edae8d433f8b4108ded84eeee052edea5e1dd Mon Sep 17 00:00:00 2001 From: anki-code Date: Sat, 7 Mar 2020 10:24:06 +0300 Subject: [PATCH 3/4] Update build.xsh --- build.xsh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/build.xsh b/build.xsh index 49bc4da..2aa1794 100755 --- a/build.xsh +++ b/build.xsh @@ -14,10 +14,9 @@ script_dir = pf"{__file__}".absolute().parent build_dir = script_dir / 'build' rm -rf @(build_dir)/ mkdir -p @(build_dir) -cd @(build_dir) - cp @(script_dir / 'entrypoint.sh') @(build_dir)/ +cd @(build_dir) if p'your_portable_shell'.exists(): eprint('SKIP: Portable shell already builded') else: From 418dcfea4d7b65915fe630ac054c14040d90aabc Mon Sep 17 00:00:00 2001 From: anki-code Date: Sat, 7 Mar 2020 23:24:05 +0300 Subject: [PATCH 4/4] Update entrypoint.sh --- entrypoint.sh | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/entrypoint.sh b/entrypoint.sh index 6a94c52..f49327b 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -9,15 +9,15 @@ # -c Execute command on host, print the result and exit # -v Verbose mode to debug # -while getopts f:c:v: option -do -case "${option}" -in -f) EXECUTE_FILE=${OPTARG};; -c) EXECUTE_COMMAND=${OPTARG};; -v) VERBOSE=${OPTARG};; -esac -done +#while getopts f:c:v: option +#do +#case "${option}" +#in +#f) EXECUTE_FILE=${OPTARG};; +#c) EXECUTE_COMMAND=${OPTARG};; +#v) VERBOSE=${OPTARG};; +#esac +#done # # Move to current directory @@ -28,4 +28,4 @@ cd $CURRENT_DIR # # Run the portable shell # -./your_portable_shell # $EXECUTE_FILE $EXECUTE_COMMAND $VERBOSE \ No newline at end of file +./your_portable_shell # $EXECUTE_FILE $EXECUTE_COMMAND $VERBOSE