]> git.armaanb.net Git - gen-shell.git/commitdiff
updated dockerfile, install loc
authorArmaan Bhojwani <3fb650a9-b47e-4604-a282-1dd91953b2ee@anonaddy.me>
Thu, 5 Nov 2020 20:19:20 +0000 (15:19 -0500)
committerArmaan Bhojwani <3fb650a9-b47e-4604-a282-1dd91953b2ee@anonaddy.me>
Thu, 5 Nov 2020 20:19:20 +0000 (15:19 -0500)
Dockerfile
README.md
src/CMakeLists.txt

index 112a123dcc62cbb1af1f24ab488396c81fb262f8..fce7b684ff15200c3ccf82cc77b7a7daa3b0f558 100644 (file)
@@ -9,4 +9,4 @@ FROM debian:buster-slim AS run
 RUN apt-get update && apt-get install -y cpp libreadline7 libncurses6
 WORKDIR /app
 COPY --from=builder /app/src/gen-shell .
-ENTRYPOINT ./gen-shell -c $CMD
+ENTRYPOINT ./gen-shell -c $command -b $before_command -a $after_command -p $custom_prompt
index 481053d4e7edc3dd5a06969ae9c1cc2e7bdaeaca..3a62a96872a5a452421c44649e8e99483345741f 100644 (file)
--- a/README.md
+++ b/README.md
@@ -3,7 +3,7 @@
 A simple way to turn any command into a shell with arrow key/history support (if compiled with libreadline). Forked from [taskshell](https://github.com/GothenburgBitFactory/taskshell).
 
 ## Usage
-Just put the command that you want to repeat after the c flag, eg; `gen-shell -c ls`, or even something much more complex like `gen-shell -c "cd /home/armaa/Clone/words && /home/armaa/Clone/words/bin/words"` This command was actually the inspiration for gen-shell.
+See `gen-shell --help`
 
 ## Installation
 ### From a binary
@@ -27,23 +27,18 @@ Then download and build gen shell:
 git clone --recursive https://codeberg.org/armaan/gen-shell
 cd gen-shell
 cmake .
-make
-sudo cp src/gen-shell /usr/bin/
+sudo make install
 ```
-Or, if you don't have root access, you can subsitute the last line with
-`cp src/gen-shell ~/.local/bin`
-
 ### Docker
 You can also run gen-shell in docker. Simply use
 ```bash
-docker run -it -e CMD=<command-to-run> armaanb/gen-shell
+docker run -it -e command=<command> -e before_command=<before command> -e after_command=<after command> -e custom_prompt=<custom prompt> armaanb/gen-shell
 ```
 Or to build the docker container locally, run:
 ```bash
 git clone --recursive https:/codeberg.org/armaan/gen-shell
 cd gen-shell
 docker build --no-cache -t gen-shell:latest .
-docker run -it -e CMD=<command-to-run> gen-shell
 ```
 ## License
 Following suit from taskshell, gen-shell is MIT licensed by Armaan Bhojwani, 2020. Gen-shell is forked from taskshell, which was developed by [these people](https://github.com/GothenburgBitFactory/taskshell/blob/master/AUTHORS).
index 841ad0f009d49c62febf75168c0e9b0638087502..ecd29b155c318176ceda4bc1cf667af3c003e97a 100644 (file)
@@ -13,4 +13,4 @@ target_link_libraries (gen-shell_executable gen-shell ${GEN-SHELL_LIBRARIES})
 
 set_property (TARGET gen-shell_executable PROPERTY OUTPUT_NAME "gen-shell")
 
-install (TARGETS gen-shell_executable DESTINATION .)
+install (TARGETS gen-shell_executable DESTINATION /usr/bin/)