### gdbinit ¶

    /etc/gdb/gdbinit

    /etc/gdb/gdbinit.d/*

    ~/.config/gdb/gdbinit

    ~/.gdbinit

    ./.gdbinit

These files contain GDB commands to automatically execute during GDB startup. The lines of contents are canned sequences of commands, described in Canned Sequences of Commands.

Please read more in What GDB Does During Startup.

`/etc/gdb/gdbinit`

  System-wide initialization file. It is executed unless user specified GDB option `-nx` or `-n`. See more in

`/etc/gdb/gdbinit.d`

  System-wide initialization directory. All files in this directory are executed on startup unless user specified GDB option `-nx` or `-n`, as long as they have a recognized file extension. See more in System-wide configuration and settings.

``~/.config/gdb/gdbinit` or `~/.gdbinit``

  User initialization file. It is executed unless user specified GDB options `-nx`, `-n` or `-nh`.

``.gdbinit``

  Initialization file for current directory. It may need to be enabled with GDB security command `set auto-load local-gdbinit`. See more in Automatically loading init file in the current directory.