Skip to content

Commit

Permalink
Create guide for uninstalling (#27)
Browse files Browse the repository at this point in the history
* Create guide for uninstalling

* Update the syntax in README.md

* Update README.md

* Update README.md

* Update README.md
  • Loading branch information
lebr0nli authored Nov 29, 2023
1 parent 7b47b8c commit ede98bb
Showing 1 changed file with 23 additions and 3 deletions.
26 changes: 23 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,10 @@ $ bash -c "$(curl -fsSL https://raw.githubusercontent.com/lebr0nli/GEP/main/inst
$ bash -c "$(wget https://raw.githubusercontent.com/lebr0nli/GEP/main/install.sh -O -)"
```

3. Enjoy!
5. Enjoy!

> [!IMPORTANT]
> After the installation, the script will automatically add `source /path/to/GEP/gdbinit-gep.py` to your `~/.gdbinit` file. Please make sure this line is **always** at the end of your `~/.gdbinit` file during future modifications of your `~/.gdbinit` to avoid some unexpected behaviors.
## How to update the version of GEP?

Expand All @@ -53,6 +56,7 @@ You can modify the configuration for history, auto-completion, and other GEP con

You can also add your custom key bindings by modifying `/path/to/GEP/geprc.py`.

> [!NOTE]
> The `example` subdirectory houses samples and default configurations.
## The trade-offs
Expand All @@ -76,7 +80,7 @@ The GDB Python API event: `gdb.event.before_prompt` may be called only once.

So if you are using a GDB plug-in that is listening on this event, this plug-in will cause some bugs.

> **Note**
> [!NOTE]
> As far as I know, pwndbg and gef won't be bothered by this side effect now.
To avoid this, you can change the callback function by adding them to `gdb.prompt_hook`, `gdb.prompt_hook` has almost
Expand All @@ -95,11 +99,27 @@ repeatedly executing them.

If you have some user-defined function that has `dont-repeat` property, add your command into the set manually, too.

> **Note**
> [!NOTE]
> The set of those user-defined commands are in `geprc.py` and the variable name for it is `DONT_REPEAT`.
>
> If you found some builtin commands which should or shouldn't be added by default, let me know on the issue page, thanks!
## Uninstall

If this is your current `~/.gdbinit` file after the installation:

```shell
source /path/to/GEP/gdbinit-gep.py
```

Then, you can uninstall this plug-in by:

```shell
rm -rf /path/to/GEP
```

And remove `source /path/to/GEP/gdbinit-gep.py` from your `~/.gdbinit`.

## Credits

Some ideas/code are inspired by [hugsy/gef](https://github.com/hugsy/gef) and [pwndbg/pwndbg](https://github.com/pwndbg/pwndbg).
Expand Down

0 comments on commit ede98bb

Please sign in to comment.