Add GDB 'Stop on warnings' and 'Running with batch commands'

sections.



git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@3388 ea778897-0a13-0410-b9d1-a72fbfd435f5
This commit is contained in:
Nick Treleaven 2008-12-16 17:11:09 +00:00
parent 4b000e09ae
commit e726bf942a
2 changed files with 34 additions and 2 deletions

View File

@ -15,6 +15,9 @@
working directory if the current file has no path. working directory if the current file has no path.
* src/editor.c: * src/editor.c:
Move %ws and %newline% replacement into snippets-only code. Move %ws and %newline% replacement into snippets-only code.
* HACKING:
Add GDB 'Stop on warnings' and 'Running with batch commands'
sections.
2008-12-15 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de> 2008-12-15 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de>

33
HACKING
View File

@ -292,8 +292,37 @@ Update init_tag_list() for foo, listing the tm_tag_* types corresponding
to the s_tag_type_names strings used in foo.c for FooKinds. to the s_tag_type_names strings used in foo.c for FooKinds.
Loading a plugin from GDB GDB
------------------------- ---
Stop on warnings
^^^^^^^^^^^^^^^^
When a GLib or GTK warning is printed, often you want to get a
backtrace to find out what code caused them. You can do that with the
``--g-fatal-warnings`` argument, which will abort Geany on the first
warning it receives.
But for ordinary testing, you don't always want your editor to abort
just because of a warning - use::
(gdb) b handler_log if level <= G_LOG_LEVEL_WARNING
Running with batch commands
^^^^^^^^^^^^^^^^^^^^^^^^^^^
Use::
$ gdb src/geany -x gdb-commands
Where ``gdb-commands`` is a file with the following lines::
set pagination off
b handler_log if level <= G_LOG_LEVEL_WARNING
r -d
Loading a plugin
^^^^^^^^^^^^^^^^
This is useful so you can load plugins without installing them first. This is useful so you can load plugins without installing them first.
Alternatively you can use a symlink in ~/.config/geany/plugins or Alternatively you can use a symlink in ~/.config/geany/plugins or
$prefix/lib/geany (where $prefix is /usr/local by default). $prefix/lib/geany (where $prefix is /usr/local by default).