Skip to content

Commit

Permalink
Make the readme more consistent with the other debuggers
Browse files Browse the repository at this point in the history
  • Loading branch information
Gama11 committed Jul 4, 2018
1 parent 91b8678 commit c41dc93
Showing 1 changed file with 49 additions and 18 deletions.
67 changes: 49 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,26 +1,57 @@
# Howto use
after install you need to include `hxcpp-debug-server` library into your project:
# HXCPP Debugger

* build.hxml
```
-lib hxcpp-debug-server
```
[![Build Status](https://travis-ci.org/vshaxe/hxcpp-debugger.svg?branch=master)](https://travis-ci.org/vshaxe/hxcpp-debugger) [![Version](https://vsmarketplacebadge.apphb.com/version-short/vshaxe.hxcpp-debugger.svg)](https://marketplace.visualstudio.com/items?itemName=vshaxe.hxcpp-debugger) [![Installs](https://vsmarketplacebadge.apphb.com/installs-short/vshaxe.hxcpp-debugger.svg)](https://marketplace.visualstudio.com/items?itemName=vshaxe.hxcpp-debugger)

* openfl project.xml:
```
<haxelib name="hxcpp-debug-server" if="debug" />
This VSCode extension allows you to debug [HXCPP](https://haxe.org/manual/target-cpp-getting-started.html) applications.

## Usage

To debug a HXCPP application, it needs to be compiled with the `hxcpp-debug-server` library. First, install the library by running `haxelib install hxcpp-debug-server` or running the "HXCPP: Setup Debugging" command.

Then the library needs to be included in your project:

* `build.hxml`:

```
-lib hxcpp-debug-server
```

* Lime/OpenFL `project.xml`:

```
<haxelib name="hxcpp-debug-server" if="debug" />
```

Finally, you need a launch configuration:


```json
{
"version": "0.2.0",
"configurations": [
{
"name": "HXCPP",
"type": "hxcpp",
"request": "launch",
"program": "${workspaceRoot}/bin/application.exe"
}
]
}
```

# Installing from source
Navigate to the extensions folder (C:\Users\<username>\.vscode\extensions on Windows, ~/.vscode/extensions otherwise)
Replace `/bin/application.exe` with the path to your executable file.

Clone this repo: git clone https://github.com/vshaxe/vscode_hxcpp_debugger
## Installing from source

Change current directory to the cloned one: cd vscode_hxcpp_debugger.
1. Navigate to the extensions folder (`C:\Users\<username>\.vscode\extensions` on Windows, `~/.vscode/extensions` otherwise)
2. Clone this repo: `git clone https://github.com/vshaxe/hxcpp-debugger`
3. Change current directory to the cloned one: `cd hxcpp-debugger`.
4. Install dependencies:

Install dependencies:
```hxml
npm install
haxelib install hxnodejs
haxelib git vscode-debugadapter https://github.com/vshaxe/vscode-debugadapter-extern
```
npm install
haxelib install hxnodejs
haxelib git vscode-debugadapter https://github.com/vshaxe/vscode-debugadapter-extern
Do haxe build.hxml
5. Do `haxe build.hxml`

0 comments on commit c41dc93

Please sign in to comment.