diff --git a/Makefile b/Makefile index 602a690..af9426c 100644 --- a/Makefile +++ b/Makefile @@ -23,13 +23,8 @@ ifdef SAN CFLAGS += -fsanitize=${SAN} endif -ifeq (${NO_VULN},1) - CPPFLAGS += -DNO_VULN_COMMANDS -endif - ifeq (${ENABLE_SSL},1) LDLIBS += -lssl -lcrypto - CPPFLAGS += -DIRC_SSL_SUPPORT endif all: include/config.h ${PROGN} @@ -40,9 +35,6 @@ ${PROGN}: ${HDR} ${SRC} # do nothing but update them... ${SRC} ${HDR}: -submodules: - git submodule update --init --recursive - include/config.h: config.mk.h cp -f $< $@ diff --git a/README.md b/README.md index d8ae21c..0a0c647 100644 --- a/README.md +++ b/README.md @@ -3,30 +3,30 @@ Healthy for your coding ability, take once weekly, excessive doses may result in arthritis, ass pain, and death. -Only for real chads, goto irc.rizon.net/#/g/chad for first-hand -enjoyment of the one and only probotic and to yell at the developers. - * Description -This bot will let you be delagated with challenges at dates within -it's database, this can all be done via the IRC interface. +Prints useful challenges when requested. See doc/api.md for detailed information about this interface. * Building and Installation -First, you'll want specify your server and channel as well as bot username -and a password. This can be done either with command-line options or in a -specified credentials file. +Building requires (debian derived): +libsqlite3-dev build-essentials + +** Submodules +git submodule update --init --recursive +make -C lib/libircclient + +** Configuration (Optional but highly recommended) +make include/config.h && $EDITOR include/config.h -You can simply run install.sh to build and install this project. See the -Makefile for specific build options, I highly recommend NVULN=1 for all -non-developmental deployments. +** Building and Installation +make && BOOTSTRAP_ONLY=1 ./install.sh -This'll require a few libraries: -libircclient-dev libsqlite3-dev build-essentials +remove BOOTSTRAP_ONLY=1 if you plan to install this somewhere. -* Hosting +* Source Code Hosts https://git.lain.church/emil/probotic https://bis64wqhh3louusbd45iyj76kmn4rzw5ysawyan5bkxwyzihj67c5lid.onion/emil/probotic diff --git a/include/config.mk.h b/include/config.mk.h index ccfc09d..71eed2f 100644 --- a/include/config.mk.h +++ b/include/config.mk.h @@ -1 +1,7 @@ #define DBFILE "probotic_data.sqlite" + +/* Disables vulnerable commands */ +/* #define NO_VULN_COMMANDS */ + +/* Enables SSL support */ +/* #define IRC_SSL_SUPPORT */ diff --git a/install.sh b/install.sh old mode 100644 new mode 100755 index 652c937..d87c966 --- a/install.sh +++ b/install.sh @@ -7,9 +7,10 @@ TARGET=${TARGET-/opt/probotic} DIR=$(dirname $(readlink -f "$0")) cd $DIR -# BUILD & BOOTSTRAP -make -C $DIR DEBUG=0 NVULN=1 || exit 1 -$DIR/bootstrap/bootstrap.sh || exit 1 +# BOOTSTRAP +cd $DIR/bootstrap && ./bootstrap.sh || exit 1 +cd ..; +[ "$BOOTSTRAP_ONLY" = 1 ] && exit 0 # INSTALL mkdir -p $TARGET diff --git a/uninstall.sh b/uninstall.sh old mode 100644 new mode 100755