Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve readme and CDT Cloud update logo #109

Merged
merged 10 commits into from
Mar 25, 2024
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ Contributors guide: https://github.com/eclipse-cdt-cloud/vscode-memory-inspector

#### Review checklist

- [ ] as an author, I have thoroughly tested my changes and carefully followed [the review guidelines](https://github.com/theia-ide/theia/blob/master/doc/pull-requests.md#requesting-a-review)
- [ ] as an author, I have thoroughly tested my changes and carefully followed [the contribution guidelines](https://github.com/eclipse-cdt-cloud/vscode-memory-inspector/blob/main/CONTRIBUTING.md)
planger marked this conversation as resolved.
Show resolved Hide resolved

#### Reminder for reviewers

- as a reviewer, I agree to behave in accordance with [the review guidelines](https://github.com/theia-ide/theia/blob/master/doc/pull-requests.md#reviewing)
- as a reviewer, I agree to behave in accordance with [the code of conduct](https://github.com/eclipse-cdt-cloud/vscode-memory-inspector/blob/main/CODE_OF_CONDUCT.md)
40 changes: 18 additions & 22 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,50 +1,46 @@
# Contributing to Eclipse Theia C/C++ Extensions
# Contributing to Eclipse CDT Cloud Memory Inspector

This repository is the home to Theia's C/C++ extensions.

See Theia's main repository to get more information about the IDE:
https://github.com/eclipse/theia
This repository is the home to the CDT Cloud Memory Inspector.

## How Can I Contribute?

In the following some of the typical ways of contribution are described.

### Asking Questions

It's totally fine to ask questions by opening an issue in the Theia GitHub
repository. We will close it once it's answered and tag it with the 'question'
label. Please check if the question has been asked before there or on [Stack
Overflow](https://stackoverflow.com).
It's totally fine to ask questions by opening an issue in the
[GitHub repository](https://github.com/eclipse-cdt-cloud/vscode-memory-inspector).
We will close it once it's answered and tag it with the 'question' label.
Please check if the question has been asked before.

### Reporting Bugs

If you have found a bug, you should first check if it has already been filed
and maybe even fixed. If you find an existing unresolved issue, please add your
case. If you could not find an existing bug report, please file a new one. In
any case, please add all information you can share and that will help to
and maybe even fixed in the
[issues](https://github.com/eclipse-cdt-cloud/vscode-memory-inspector/issues).
If you find an existing unresolved issue, please add your case. If you could not
find an existing bug report, please
[file a new one](https://github.com/eclipse-cdt-cloud/vscode-memory-inspector/issues/new/choose).
In any case, please add all information you can share and that will help to
reproduce and solve the problem.

### Reporting Feature Requests

You may want to see a feature or have an idea. You can file a request and we
can discuss it. If such a feature request already exists, please add a comment
or some other form of feedback to indicate you are interested too. Also in this
You may want to see a feature or have an idea. You can
[file a request](https://github.com/eclipse-cdt-cloud/vscode-memory-inspector/issues/new/choose)
and we can discuss it. If such a feature request already exists, please add a comment
or some other form of feedback to indicate you are interested, too. Also in this
case any concrete use case scenario is appreciated to understand the motivation
behind it.

### Pull Requests

Before you get started investing significant time in something you want to get
merged and maintained as part of Theia, you should talk with the team through
an issue. Simply choose the issue you would want to work on, and tell everyone
merged and maintained as part of this project, you should talk with the team
by posting on an issue. Simply choose the issue you would want to work on, and tell everyone
that you are willing to do so and how you would approach it. The team will be
happy to guide you and give feedback.

## Coding Guidelines

We follow the coding guidelines described
[here](https://github.com/eclipse/theia/wiki/Coding-Guidelines).

## Eclipse Contributor Agreement

Before your contribution can be accepted by the project team contributors must
Expand Down
57 changes: 44 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,27 +1,58 @@
# Memory Inspector

This extension contributes a set of widgets for viewing memory in different ways.
A Visual Studio Code extension that provides a powerful and configurable memory viewer that works with debug adapters.
planger marked this conversation as resolved.
Show resolved Hide resolved

## Requirements
![Screenshot of the Memory Inspector](https://raw.githubusercontent.com/eclipse-cdt-cloud/vscode-memory-inspector/master/media/memory-inspector-screenshot.png)

This extension must be used in conjunction with a Debug Adapter that implements a ReadMemoryRequest handler or alternative custom request that returns
memory data. It has been tested against the [CDT-GDB Adapter](https://github.com/eclipse-cdt/cdt-gdb-adapter) used as the backend for the
[CDT-GDB VSCode](https://github.com/eclipse-cdt/cdt-gdb-vscode) plugin.
## Features

## The Memory Provider
- **Configurable Memory Display**: Shows memory data with various display options.
- **Address Navigation**: Easily jump to and scroll through memory addresses.
- **Variable Highlights**: Colors memory ranges for variables.
- **Multiple Memory Formats**: Shows memory data on hover in multiple formats.
- **Edit Memory**: Allows in-place memory editing, if the debug adapter supports the `WriteMemoryRequest`.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's get #108 in to make this completely true :-).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, you are right. I'm an optimist, but I'm completely fine to leave this PR open until #108 is merged.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am sure it will come for the next release one or the other way. ;-)

- **Memory Management**: Enables saving and restoring memory data for specific address ranges (Intel Hex format).
- **Customized Views**: Create and customize as many memory views as you need.
- **Lock Views**: Keep views static, unaffected by updates from the debug session.
- And much more

## Getting Started

### Prerequisites

1. **Install**: Add the extension to VS Code.
2. **Verify Debugger Capability**: Ensure the debug adapter supports [`ReadMemory` requests](https://microsoft.github.io/debug-adapter-protocol/specification#Requests_ReadMemory).
3. **Enable Debug Type**: Enable the Memory Inspector for the debug configuration type (VS Code setting *Debug Types*: `memory-inspector.debugTypes`).

### Use Memory Inspector

1. **Debug Session**: Start a debug session.
2. **Open Memory Inspector**: Either run the *Memory: Show Memory Inspector* command or right-click a variable in the Variables view and select *Show in Memory Inspector*.
3. **Adjust View**: Modify the memory range you're interested in, as needed.

## Configuration

Use the gear symbol in each memory view to customize the individual settings like columns, grouping, and formats.
Default settings can be adjusted in the VS Code settings of this extension.

## Contributing

We welcome contributions on [GitHub](https://github.com/eclipse-cdt-cloud/vscode-memory-inspector).
Check our [contribution guidelines](./CONTRIBUTING.md) for more info.
This open-source project is part of [Eclipse CDT Cloud](https://eclipse.dev/cdt-cloud/).

## Behind the Scenes

### The Memory Provider

The primary entry point for the backend functionality of the plugin is the the [`MemoryProvider`](./src/plugin/memory-provider.ts) class. That class
has two primary functions: it handles requests that are specified by the [Debug Adapter Protocol](https://microsoft.github.io/debug-adapter-protocol/),
and it instantiates custom handlers that can provide additional functionality depending on the capabilities of a given debug adapter. In order to
register custom capabilities, the [`AdapterRegistry`](./src/plugin/adapter-registry/adapter-registry.ts) matches debug types to objects implementing
the [`AdapterCapabilities`](./src/plugin/adapter-registry/adapter-capabilities.ts) interface.

## The Widgets

### Memory Widget

The basic [`MemoryWidget` class](./src/webview/components/memory-widget.ts) is a wrapper around two functional widgets, a `MemoryOptionsWidget` and
a`MemoryTableWidget`. The [`MemoryOptionsWidget`](./src/webview/components/options-widget.tsx) is responsible for configuring the display
and fetching memory, and the [`MemoryTableWidget`](./src/webview/components/table.tsx) renders the memory according to the options
specified by the user in the `MemoryOptionsWidget`. The basic combination of these three classes offers variable highlighting, ascii display, and
dynamic updating in response to events from the debug session, as well as the option to lock the view to ignore changes from the session.
The [`MemoryWidget`](./src/webview/components/memory-widget.tsx) is a wrapper around two functional widgets, a `MemoryOptionsWidget` and a`MemoryTableWidget`.
The [`OptionsWidget`](./src/webview/components/options-widget.tsx) is responsible for configuring the display and fetching memory, and the
[`MemoryTable`](./src/webview/components/memory-table.tsx) renders the memory according to the options specified by the user in the options.
Binary file modified media/cdtcloud.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/memory-inspector-screenshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading