Skip to content

Commit 47a4eb3

Browse files
committed
Initial Commit
1 parent be84c72 commit 47a4eb3

51 files changed

Lines changed: 20155 additions & 2 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/ci.yml

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
name: ci
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
tags:
8+
- '*'
9+
pull_request:
10+
branches:
11+
- main
12+
workflow_dispatch:
13+
14+
jobs:
15+
build:
16+
name: Build
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: actions/setup-node@v6
20+
with:
21+
node-version: 22
22+
- uses: actions/checkout@v6
23+
with:
24+
fetch-depth: 0
25+
- run: npm install --ignore-scripts
26+
- run: npm run build
27+
- run: npm run package
28+
- uses: actions/upload-artifact@v7
29+
with:
30+
name: vsix-package
31+
path: ./*.vsix
32+
retention-days: 1
33+
34+
release:
35+
needs: build
36+
name: Release
37+
runs-on: ubuntu-latest
38+
permissions:
39+
contents: write
40+
if: startsWith(github.ref, 'refs/tags/')
41+
steps:
42+
- uses: actions/checkout@v6
43+
- uses: actions/download-artifact@v4
44+
with:
45+
path: artifacts
46+
- uses: softprops/action-gh-release@v2
47+
with:
48+
files: artifacts/*/*.vsix
49+
50+
publish-open-vsx-registry:
51+
needs:
52+
- release
53+
name: Open VSX
54+
runs-on: ubuntu-latest
55+
if: startsWith(github.ref, 'refs/tags/')
56+
steps:
57+
- uses: actions/checkout@v6
58+
- uses: actions/download-artifact@v4
59+
with:
60+
path: artifacts
61+
- uses: actions/setup-node@v6
62+
with:
63+
node-version: 22
64+
- name: Publish
65+
run: |
66+
npx ovsx publish -i artifacts/*/*.vsix -p ${{secrets.OPEN_VSX_TOKEN}}
67+
68+
publish-vscode-marketplace:
69+
needs:
70+
- release
71+
name: VS Code Marketplace
72+
runs-on: ubuntu-latest
73+
if: startsWith(github.ref, 'refs/tags/')
74+
steps:
75+
- uses: actions/checkout@v6
76+
- uses: actions/download-artifact@v4
77+
with:
78+
path: artifacts
79+
- uses: actions/setup-node@v6
80+
with:
81+
node-version: 22
82+
- name: Publish
83+
run: |
84+
npx @vscode/vsce publish -i artifacts/*/*.vsix -p ${{secrets.VS_MARKETPLACE_TOKEN}}

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
.DS_Store
2+
node_modules
3+
dist
4+
*.vsix

.npmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
omit-lockfile-registry-resolved=true

.vscode/launch.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
// A launch configuration that compiles the extension and then opens it inside a new window
2+
// Use IntelliSense to learn about possible attributes.
3+
// Hover to view descriptions of existing attributes.
4+
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5+
{
6+
"version": "0.2.0",
7+
"configurations": [
8+
{
9+
"name": "Desktop Extension",
10+
"type": "extensionHost",
11+
"request": "launch",
12+
"args": [
13+
"--extensionDevelopmentPath=${workspaceFolder}"
14+
],
15+
"outFiles": [
16+
"${workspaceFolder}/dist/**/*.js"
17+
]
18+
}
19+
]
20+
}

.vscode/tasks.json

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"version": "2.0.0",
3+
"tasks": [
4+
{
5+
"type": "npm",
6+
"script": "watch",
7+
"group": {
8+
"kind": "build",
9+
"isDefault": true
10+
},
11+
"problemMatcher": [],
12+
"label": "npm: watch",
13+
"detail": "tsc --sourceMap --watch"
14+
}
15+
]
16+
}

.vscodeignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
.github
2+
.vscode
3+
dist/**/*.js.map
4+
node_modules
5+
src
6+
*.vsix

README.md

Lines changed: 68 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,68 @@
1-
# vscode-mbed
2-
VSCode Extension for Mbed OS Projects
1+
# VS Code Mbed
2+
3+
VS Code Extension for Mbed OS Projects.
4+
5+
## Overview
6+
Mbed for VS Code enables you to work with Mbed OS projects, handling library dependencies, target connection, build, debug and serial output.
7+
8+
## Usage
9+
10+
- Install the extension from within your IDE (search for 'mbed') or from an extension marketplace:
11+
12+
- VS Code: https://marketplace.visualstudio.com/items?itemName=mbed.mbed
13+
- Open VSX: https://open-vsx.org/extension/mbed/mbed
14+
15+
- This will also install the following extensions:
16+
- arm.armls - For working with assembly code.
17+
- arm.device-manager - For detecting and managing connected devices.
18+
- arm.embedded-debug - For deploying to your device and debugging programs.
19+
- arm.environment-manager - For setting up a compiler.
20+
21+
- Open an existing Mbed OS project or use the user interface to clone an existing example using git.
22+
- The user interface will help you recursively clone any dependant libraries (hydration) and install the Arm GNU toolchain (GCC) or Arm Compiler for Embedded toolchains.
23+
- You can then select your target and profile, build, deploy and debug your application.
24+
25+
## Contribution
26+
27+
This extension is intended to serve as a permissive, open-source reference for working with Mbed after the July 2026 end-of-life, offering an alternative to the standalone Mbed Studio application.
28+
29+
Pull requests may be accepted, but this primarily serves as a reference application for developing your own tools.
30+
31+
## Development
32+
33+
### Prerequisites
34+
35+
A working [Node.js](https://nodejs.org/) environment.
36+
37+
### Clone
38+
39+
```bash
40+
git clone https://github.com/ARMmbed/vscode-mbed
41+
```
42+
43+
### Build
44+
45+
In the `vscode-mbed` folder:
46+
47+
```bash
48+
## Install node dependencies
49+
npm install
50+
```
51+
52+
```bash
53+
## Build the extension
54+
npm run build
55+
```
56+
57+
```bash
58+
## Package the extension
59+
npm run package
60+
```
61+
62+
### Watch
63+
64+
Start the default build task in VS Code.
65+
66+
### Debug
67+
68+
Launch the default debug task in VS Code.

0 commit comments

Comments
 (0)