clean:
$(RM) *.o lib*/*.o tests/*.o *.a xpick xedit unittests
+ $(RM) *.d lib*/*.d tests/*.d
$(RM) *.gcno lib*/*.gcno tests/*.gcno
$(RM) *.gcda lib*/*.gcda tests/*.gcda
$(RM) *.gcov lib*/*.gcov tests/*.gcov
* invalid memory accesses while viewing docs/waf
* check for file changes on save
* check for file changes when window regains focus
-* Use $SHELL if defined, fallback on /bin/sh
-* Set ENV to ~/.config/edit/rc if undefined
The Rest:
* add a distinct state for pointer move versus drag
* Add a SaveAs tag that takes an argument for the filename to save as
* Add a GoTo tag for ctags lookup and line number jump
-* implement command diffing logic to optimize the undo/redo log
* add command line flags to toggle options (Tabs, Indent, etc..)
* Add a ctrl+space shortcut to autocomplete ctag
* off by one error on scrolling up with wrapped lines
* 100% coverage with unit and unit-integration tests
* shortcut to repeat previous operation
+* implement command diffing logic to optimize the undo/redo log
+
The Future:
* Acme-like window manager
* Win-like terminal emulator
* File browser
+
# while editing.
export PATH="$HOME/.config/edit/tools:$PATH"
+# If $SHELL is bash, this will allow us to define functions in an RC file and
+# use them in the editor
+export EDITRCFILE="$HOME/.config/edit/editrc"
+export BASH_ENV="$EDITRCFILE"
+
# Now figure out the correct editor to execute
if [ -z "$DISPLAY" ]; then
if [ -z "$EDITOR" ]; then
(nohup xedit > /dev/null 2>&1) &
else
for f in "$@"; do
+ [ -f "$EDITRCFILE" ] && . "$EDITRCFILE"
(nohup xedit "$f" > /dev/null 2>&1) &
done
fi
/* External Commands
*****************************************************************************/
+/* The shell: Filled in with $SHELL. Used to execute commands */
+static char* ShellCmd[] = { NULL, "-c", NULL, NULL };
+
#ifdef __MACH__
static char* CopyCmd[] = { "pbcopy", NULL };
static char* PasteCmd[] = { "pbpaste", NULL };
static char* CopyCmd[] = { "xsel", "-bi", NULL };
static char* PasteCmd[] = { "xsel", "-bo", NULL };
#endif
-static char* ShellCmd[] = { "/bin/sh", "-c", NULL, NULL };
static char* PickFileCmd[] = { "xfilepick", ".", NULL };
static char* PickTagCmd[] = { "xtagpick", "tags", NULL, NULL };
static char* OpenCmd[] = { "xedit", NULL, NULL };
*****************************************************************************/
#ifndef TEST
int main(int argc, char** argv) {
+ /* setup the shell */
+ ShellCmd[0] = getenv("SHELL");
+ if (!ShellCmd[0]) ShellCmd[0] = "/bin/sh";
/* load the buffer views */
char* tags = getenv("EDITTAGS");
view_init(getview(TAGS), NULL);