]> git.armaanb.net Git - gen-shell.git/commitdiff
updated for Sarge
authorArmaan Bhojwani <3fb650a9-b47e-4604-a282-1dd91953b2ee@anonaddy.me>
Mon, 2 Nov 2020 18:13:47 +0000 (13:13 -0500)
committerArmaan Bhojwani <3fb650a9-b47e-4604-a282-1dd91953b2ee@anonaddy.me>
Mon, 2 Nov 2020 18:13:47 +0000 (13:13 -0500)
Dockerfile
README.md
src/CMakeLists.txt

index 82f372dbe574bbe643699d4659067efef969c08f..112a123dcc62cbb1af1f24ab488396c81fb262f8 100644 (file)
@@ -1,6 +1,6 @@
 FROM debian:buster-slim AS builder
 RUN apt-get update && apt-get install -y cmake gcc g++ git libreadline-dev make
-RUN git clone https://codeberg.org/armaan/gen-shell.git /app
+RUN git clone --recursive https://codeberg.org/armaan/gen-shell.git /app
 WORKDIR /app
 RUN cmake --configure .
 RUN cmake --build .
@@ -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 $CMD
+ENTRYPOINT ./gen-shell -c $CMD
index a7d8e301c5152da1e988e80c36ed00c6a21d2281..b696a29937d2e06641d2af61f81d9a532419a5d6 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. This is a fork of [taskshell](https://github.com/GothenburgBitFactory/taskshell) with a highly reduce codebase.
 
 ## Usage
-Just put the command that you want to repeat after `gen-shell`, eg; `gen-shell ls`, or even something much more complex like `gen-shell "cd /home/armaa/Clone/words && /home/armaa/Clone/words/bin/words` This command was actually the inspiration for gen-shell.
+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.
 
 ## Installation
 ### Binaries
@@ -17,8 +17,14 @@ If you would like to avoid this, you can build from source. Doing so requires:
   - g++ (sometimes packaged as gcc-c++ or gcc-g++)
   - cpp (11 or higher)
   - libreadline development files (7 or 8 is fine, 5 is untested)
+
+On a Debian or Ubuntu based distribution, you can install these dependencies with this command:
+```bash
+sudo apt update && sudo apt install cmake make gcc g++ cpp libreadline-dev
+```
+
 ```bash
-git clone https://codeberg.org/armaan/gen-shell
+git clone --recursive https://codeberg.org/armaan/gen-shell
 cd gen-shell
 cmake .
 make
@@ -32,11 +38,11 @@ You can also run gen-shell in docker. Simply use
 ```bash
 docker run -it -e CMD=<command-to-run> armaanb/gen-shell:latest
 ```
-Or to build the docker container locally
+Or to build the docker container locally, which ensures that you are using the latest version, or lets you make changes to the source code before building:
 ```bash
-git clone https://codeberg.org/armaan/gen-shell
+git clone --recursive https:/codeberg.org/armaan/gen-shell
 cd gen-shell
-docker build -t armaanb/gen-shell:latest .
+docker build --no-cache -t armaanb/gen-shell:latest .
 docker run -it -e CMD=<command-to-run> armaanb/gen-shell
 ```
 ## License
index 8f0418b28699dddc8a56f854d1cd2dadc4925b91..e67bb26efce63105d52987c678e0f43219ed5bd6 100644 (file)
@@ -1,7 +1,6 @@
 cmake_minimum_required (VERSION 2.8)
 include_directories (${CMAKE_SOURCE_DIR}
                      ${CMAKE_SOURCE_DIR}/src
-                     ${CMAKE_SOURCE_DIR}/src/libshared/src
                      ${GEN-SHELL_INCLUDE_DIRS})
 
 set (gen-shell_SRCS prompt.cpp