Skip to content

Commit c38ea56

Browse files
committed
Correct documentation on recompiling Sentry when using source code context
1 parent 815ac73 commit c38ea56

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -144,12 +144,12 @@ Sentry uses the [hackney HTTP client](https://github.com/benoitc/hackney) for HT
144144

145145
Sentry's server supports showing the source code that caused an error, but depending on deployment, the source code for an application is not guaranteed to be available while it is running. To work around this, the Sentry library reads and stores the source code at compile time. This has some unfortunate implications. If a file is changed, and Sentry is not recompiled, it will still report old source code.
146146

147-
The best way to ensure source code is up to date is to recompile Sentry itself via `mix do clean, compile`. It's possible to create a Mix Task alias in `mix.exs` to do this. The example below would allow one to run `mix sentry_recompile` which will force recompilation of Sentry so it has the newest source and then compile the project:
147+
The best way to ensure source code is up to date is to recompile Sentry itself via `mix deps.compile sentry --force`. It's possible to create a Mix Task alias in `mix.exs` to do this. The example below would allow one to run `mix sentry_recompile` which will force recompilation of Sentry so it has the newest source and then compile the project:
148148

149149
```elixir
150150
# mix.exs
151151
defp aliases do
152-
[sentry_recompile: ["clean", "compile"]]
152+
[sentry_recompile: ["deps.compile sentry --force", "compile"]]
153153
end
154154
```
155155

docs/index.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,13 +142,13 @@ Including Source Code
142142

143143
Sentry's server supports showing the source code that caused an error, but depending on deployment, the source code for an application is not guaranteed to be available while it is running. To work around this, the Sentry library reads and stores the source code at compile time. This has some unfortunate implications. If a file is changed, and Sentry is not recompiled, it will still report old source code.
144144

145-
The best way to ensure source code is up to date is to recompile Sentry itself via ``mix do clean, compile``. It's possible to create a Mix Task alias in ``mix.exs`` to do this. The example below would allow one to run ``mix.sentry_recompile`` which will force recompilation of Sentry so it has the newest source and then compile the project:
145+
The best way to ensure source code is up to date is to recompile Sentry itself via ``mix deps.compile sentry --force``. It's possible to create a Mix Task alias in ``mix.exs`` to do this. The example below would allow one to run ``mix.sentry_recompile`` which will force recompilation of Sentry so it has the newest source and then compile the project:
146146

147147
.. code-block:: elixir
148148
149149
# mix.exs
150150
defp aliases do
151-
[sentry_recompile: ["clean", "compile"]]
151+
[sentry_recompile: ["deps.compile sentry --force", "compile"]]
152152
end
153153
154154
To enable, set ``:enable_source_code_context`` and ``root_source_code_path``:

lib/sentry/sources.ex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,13 +37,13 @@ defmodule Sentry.Sources do
3737
it will still report old source code.
3838
3939
The best way to ensure source code is up to date is to recompile Sentry
40-
itself via `mix do clean, compile`. It's possible to create a Mix
40+
itself via `mix deps.compile sentry --force`. It's possible to create a Mix
4141
Task alias in `mix.exs` to do this. The example below would allow one to
4242
run `mix.sentry_recompile` which will force recompilation of Sentry so
4343
it has the newest source and then compile the project:
4444
4545
defp aliases do
46-
[sentry_recompile: ["clean", "compile"]]
46+
[sentry_recompile: ["deps.compile sentry --force", "compile"]]
4747
end
4848
4949
"""

0 commit comments

Comments
 (0)