1338 Commits

Author SHA1 Message Date
Akos Kitta
c8a1b3549e chore: update to arduino-fwuploader@2.4.1
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2.2.1
2023-08-31 12:50:58 +02:00
Akos Kitta
ba1293f4f0 fix(ci): fix the changelog generation
Pinned `@octokit/rest` to `19.0.13`, so that it works with Node.js 16+.

Closes arduino/arduino-ide#2200

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-31 11:43:37 +02:00
Akos Kitta
1542744f9d fix(i18n): corrected the module for tr and ru
Closes arduino/arduino-ide#2201

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-31 09:45:35 +02:00
Akos Kitta
ee97feb42c chore: update version to 2.2.1
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-31 09:45:26 +02:00
Akos Kitta
06ad7d143c fix: name of translation (UA) module
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2.2.0
2023-08-29 08:22:39 +02:00
github-actions[bot]
b78c4621fc Updated translation files 2023-08-28 11:24:10 +02:00
Akos Kitta
e08439b6a4
fix: missing app icon for AppImage on Linux (#2190)
Closes #131

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-24 17:04:58 +02:00
Akos Kitta
e03e5eb603 chore: bump the version to 2.2.0
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-24 17:01:15 +02:00
Akos Kitta
b723951d78 chore(deps): Use arduino-cli@0.34.0
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-24 10:18:47 +02:00
Akos Kitta
ea2c54bff0 chore(deps): Use arduino-fwuploader@2.4.0
Ref: arduino/arduino-fwuploader#211
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-24 10:18:47 +02:00
Akos Kitta
5fd02b9fd7 fix: falsy context menu handlerId
The very first context menu item with ID `0` has not had a click handler

Ref: eclipse-theia/theia#12500
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-22 08:51:00 +02:00
per1234
10b38820bc Generalize name of "Firmware Updater"
Some Arduino boards have a supplemental hardware module that provides functionality separate from the primary
microcontroller the sketch program runs on.

Enhancements or fixes to the firmware that runs on these supplemental modules may be made over time so it is important
for the users of these boards to have an easy way to update the firmware. Arduino IDE provides a tool for doing this.

At the time the tool was created, the poor choice was made to include the names of the specific modules it supported at
the time in the tool's name. As was inevitable, that list has changed, rendering the tool name no longer accurate.

The immediate problem is that support has been added for updating the "bridge" and radio module on the UNO R4 WiFi. That
module is neither a "WiFi101" nor a "NINA", so the tool name does not reflect the support for the UNO R4 WiFi.

More significant changes in the supported modules are under way and will be introduced in the next release:

- Dropping support for the "WiFi101" module
- Adding support for the module on the Portenta C33 board

Rather than attempting to maintain a regularly changing and overly verbose name that includes the list of every
supported module, it is better to use a name for the tool that only describes its general purpose, leaving the task of
describing the specific supported modules to the documentation.
2023-08-21 08:44:10 -07:00
per1234
ea91904f00 Do full run of "Arduino IDE" workflow on tag push
The project was recently switched to using a "trunk-based" development strategy. This necessitated some adjustments to
the configuration of the GitHub Actions workflows in order to ensure the CI system could be used to effectively validate
the project at the state staged for release in the release branch.

A `run-determination` job was added to the workflow. This job determines whether the conditions under which the workflow
was triggered indicate that the rest of the jobs in the workflow should be run.

A validation workflow should run fully under any of the following conditions:

- The trigger event was something other than a branch creation
- The trigger event was a release branch creation

Since the project is fully validated prior to a release, running the workflow when triggered by a release tag is
pointless (and even harmful in some specific standardized workflows not currently used in this repository), so (even if
for no other reason than efficiency) verification workflows are configured to not run under these conditions.

The standardized Arduino tooling workflows follow a modular design where each workflow has a narrow scope of purpose.
That path was not taken by those who set up the infrastructure for this repository. They instead created a single
massive monolithic "Arduino IDE" workflow that performs many unrelated operations under various conditions. This workflow generates
releases in addition to doing validation. Even though it is pointless to run the workflow's validation operations when
the workflow is triggered by a release tag, it is essential to run it for the release generation.

Previously, the code used in the "Arduino IDE" workflow's `run-determination` job was configured as appropriate for a
verification workflow. This meant that a release would not be generated on push of a release tag as intended. The bug is
fixed by adjusting the code to do a full run of the workflow when triggered by a release tag.
2023-08-20 14:39:44 -07:00
Akos Kitta
57fa18b940 fix: do not start obsolete daemon watcher process
Before arduino/arduino-cli#488, IDE2 required a way to stop the daemon
process if the parent (backend) process crashed. However, this mechanism
is no longer necessary as the CLI daemon process is not actually a true
daemon process.

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-20 21:54:13 +02:00
Akos Kitta
2aae9e0a07 fix: execute the Arduino CLI without a shell
Closes arduino/arduino-ide#2112
Ref: arduino/arduino-ide#2067

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-20 21:54:13 +02:00
Akos Kitta
9a99957e73
fix: incorrect certificate flashing command string (#2181)
Use a `string` array of command flags instead of the concatenated final
`string` command.

Ref: arduino/arduino-ide#2067
Closes arduino/arduino-ide#2179

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-20 21:53:43 +02:00
Akos Kitta
b25665561e fix: handle UNKNOWN code on syscall: 'stat'
Closes #2166

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-20 17:15:00 +02:00
Akos Kitta
420d31ff4b chore(cli): pin version to 0.34.0-rc.1
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-20 17:14:29 +02:00
Akos Kitta
db01efead3 fix: expand boards if available on detected port
moved the board inference logic from UI to  model

Closes #2175

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-20 17:14:29 +02:00
dependabot[bot]
5a76be306a build(deps): Bump svenstaro/upload-release-action from 2.6.1 to 2.7.0
Bumps [svenstaro/upload-release-action](https://github.com/svenstaro/upload-release-action) from 2.6.1 to 2.7.0.
- [Release notes](https://github.com/svenstaro/upload-release-action/releases)
- [Changelog](https://github.com/svenstaro/upload-release-action/blob/master/CHANGELOG.md)
- [Commits](https://github.com/svenstaro/upload-release-action/compare/2.6.1...2.7.0)

---
updated-dependencies:
- dependency-name: svenstaro/upload-release-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-18 20:53:13 -07:00
Akos Kitta
69ae38effa
feat: simplify board and port handling (#2165)
Use Arduino CLI revision `38479dc`

Closes #43
Closes #82
Closes #1319
Closes #1366
Closes #2143
Closes #2158

Ref: 38479dc706

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-18 14:42:50 +02:00
Akos Kitta
9a6a457bc4
chore(deps): Updated to Theia 1.39.0 (#2144)
- update Theia to `1.39.0`,
 - remove the application packager and fix the security vulnerabilities,
 - bundle the backed application with `webpack`, and
 - enhance the developer docs.

Co-authored-by: Akos Kitta <a.kitta@arduino.cc>
Co-authored-by: per1234 <accounts@perglass.com>

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-08-14 12:12:05 +02:00
per1234
144df893d0 Clean localization data files before pulling from Transifex
The localization of the UI strings specific to the Arduino IDE application is done via the Transifex localization
platform. A scheduled workflow pulls the data from Transifex weekly and submits a pull request for the updates.

Previously, the script used to pull the data did not clean the data files before pulling. This meant that a vestigial
file would accumulate in the repository whenever a language was removed from the Transifex project.

The accumulation is avoided by deleting the data files for the locales managed on Transifex (all locales other than the
source English locale) before downloading the data from Transifex.
2023-07-26 01:10:25 -07:00
coby2023t
e17472ef07
Add 中文(繁體) ("Chinese (Traditional)") localization (#2151)
This will add a "中文(繁體)" option to the "Language" menu in the Arduino IDE preferences, which will cause the strings
in the IDE UI to be localized for "Chinese (Traditional)".

In addition to the translations for the strings that originate from the Eclipse Theia IDE framework provided by the
"Chinese (Traditional) Language Pack for Visual Studio Code" language pack, this will also utilize the translations of
the Arduino IDE-specific strings contributed by the community.
2023-07-25 23:52:04 -07:00
dankeboy36
f6a43254f5 feat: can dock the monitor widget to the "right"
Added a new preference (`arduino.monitor.dockPanel`) to specify the
location of the application shell where the _Serial Monitor_ widget
resides. The possible values are `"bottom"` and `"right"`. The default\
value is the `"bottom"`.

The dock panel is per application and not per workspace or window.
However, advanced users can create the `./.vscode/settings.json` and
configure per sketch preference.

Signed-off-by: dankeboy36 <dankeboy36@gmail.com>
2023-07-13 09:42:47 +02:00
Akos Kitta
94d2962985 fix: include all log args in the log message
- In the bundled application, the customized logger that writes the log
files bogusly includes only the first message fragment in the log
message. This PR ensures all message fragments are included in the final
message before it is printed to the console/terminal and persisted to
the rotating log files.
 - Includes messages with `debug` severity in the log.
 - Disables the ANSI coloring in the CLI daemon log by adding the
`NO_COLOR=true` environment variable to the spawned CLI daemon process.
 - Trims trailing line ending of the daemon log.

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-07-07 17:28:16 +02:00
Akos Kitta
95fdc593ed chore(version): updated the version to 2.1.2
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-07-05 20:00:34 +02:00
dankeboy36
954fee41a0 fix(terminal): split-terminal visibility
Removed the toolbar contribution from the UI.

Ref: eclipse-theia/theia#12626/
Signed-off-by: dankeboy36 <dankeboy36@gmail.com>
2023-07-05 16:58:44 +02:00
dankeboy36
0bcb182ec0 fix(terminal): widget flickering on resize
Ref: eclipse-theia/theia#12587
Signed-off-by: dankeboy36 <dankeboy36@gmail.com>
2023-07-05 16:58:44 +02:00
dankeboy36
42d017e876 feat: expose Arduino state to VS Code extensions
- Update a shared state on fqbn, port, sketch path, and etc. changes.
VS Code extensions can access it and listen on changes.
 - Force VISX activation order: API VSIX starts first.

Signed-off-by: dankeboy36 <dankeboy36@gmail.com>
2023-07-05 16:58:44 +02:00
Akos Kitta
c66b720509 chore(cli): Bumped the CLI version to 0.33.1
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-07-05 09:31:23 +02:00
Akos Kitta
a5c9735619 Revert "Revert "chore(cli): Bumped the CLI version to 0.33.0""
This reverts commit d0bce15f8baaa17b0272a5b8c0ba45e5577ed3a9.

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-07-05 09:31:23 +02:00
per1234
6e18dca644 Adjust release procedure and CI system for "trunk-based" development strategy
Previously, releases were always made from a point in the revision history of the `main` branch (typically the tip of
the branch at the time of the release). Although the simplicity of this approach is nice, it can be limiting in some
cases. For this reason, the project is switching to using a "trunk-based" development strategy, as described here:

https://trunkbaseddevelopment.com/

This approach allows making releases at any time that consist of the arbitrary subset of revisions suitable for shipping
to the users at that time. The commits that should be included in the release are cherry-picked to a release branch and
the tag created on that branch.

This means that:

- PRs can be merged to the `main` branch as soon as they have passed review rather than having to postpone the merge of
  changes that are not ready to be included in the next release.
- Releases don't need to be postponed if the prior revision history on the `main` branch contains changes that are not
  ready to be included in the release.

The documented release procedure must be adjusted to reflect the new development strategy.

CI System Adjustments
---------------------

The status of the GitHub Actions workflows should be evaluated before making a release. However, this is not so simple as
checking the status of the commit at the tip of the release branch. The reason is that, for the sake of efficiency, the
workflows are configured to run only when the processes are relevant to the trigger event (e.g., no need to run unit
tests for a change to the readme).

In the case of the default branch, you can simply set the workflow runs filter to that branch and then check the result
of the latest run of each workflow of interest. However, that was not possible to do with the release branch since it
might be that the workflow was never run in that branch. The status of the latest run of the workflow in the default
branch might not match the status for the release branch if the release branch does not contain the full history.

For this reason, it will be helpful to trigger all relevant workflows on the creation of a release branch. This will
ensure that each of those workflows will always have at least one run in the release branch. Subsequent commits pushed to
the branch can run based on their usual trigger filters and the status of the latest run of each workflow in the branch
will provide an accurate indication of the state of that branch.

Branches are created for purposes other than releases, most notably feature branches to stage work for a pull request.
Due to the comprehensive nature of this project's CI system, it would not be convenient or efficient to fully run all CI
workflows on the creation of every feature branch.

Unfortunately, GitHub Actions does not support filters on the `create` event of branch creation like it does for the
`push` and `pull_request` events. There is support for a `branches` filter of the `push` event, but that filter is an
"AND" to the `paths` filter while this application requires an "OR". For this reason, the workflows must be triggered by
the creation of any branch. The unwanted job runs are prevented by adding a `run-determination` job with the branch
filter handled by Bash commands. The other jobs of the workflow use this `run-determination` job as a dependency, only
running when it indicates they should via a job output. Because this minimal `run-determination` job runs very quickly,
it is roughly equivalent to the workflow having been skipped entirely for non-release branch creations.
2023-06-30 11:31:47 -07:00
Akos Kitta
f3b99b08da chore(cli): Bumped the CLI version to 0.32.3
Ref: arduino/arduino-cli#2234
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-06-30 16:38:48 +02:00
Akos Kitta
d0bce15f8b Revert "chore(cli): Bumped the CLI version to 0.33.0"
This reverts commit 0fbd1fbe85fbbd864ad5e6a00850b32cbd2e83e0.
2023-06-30 14:02:08 +02:00
Andrew Sepulveda
d79bc0d083
add linux-arm64 to download-ls (#2078) 2023-06-12 13:45:58 +02:00
Akos Kitta
8f8b46fa6f fix: warn user when IDE cannot save the sketch
Happens when the IDE2 backend process crashes, and the communication
drops between the client and the server.

Closes #2081

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-06-09 12:11:31 +02:00
dependabot[bot]
d1fa6d4f3b build(deps): Bump svenstaro/upload-release-action from 2.5.0 to 2.6.1
Bumps [svenstaro/upload-release-action](https://github.com/svenstaro/upload-release-action) from 2.5.0 to 2.6.1.
- [Release notes](https://github.com/svenstaro/upload-release-action/releases)
- [Changelog](https://github.com/svenstaro/upload-release-action/blob/master/CHANGELOG.md)
- [Commits](https://github.com/svenstaro/upload-release-action/compare/2.5.0...2.6.1)

---
updated-dependencies:
- dependency-name: svenstaro/upload-release-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-09 00:02:33 -07:00
Akos Kitta
4af488b05e fix: relaxed saveAll if no Internet connection
The previous logic has incorrectly bailed the save when there is no
Internet connection. The corrected logic disallows saving files if there
is no connection between the frontend and the backend.

Ref: cff2c956845e04d320231e8a924d1a47ad016af7
Closes #2079

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-06-08 08:53:47 +02:00
Akos Kitta
db0049d635 fix: omit port from upload request when not set
Previously, if the `port` was not set in IDE2, the compile request
object has been created with an empty port object (`{}`). From now on,
if the port is not specified, IDE2 will create a compile request with
the default `null` `port` value.

Closes #2089

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-06-06 19:40:03 +02:00
Akos Kitta
0fbd1fbe85 chore(cli): Bumped the CLI version to 0.33.0
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-06-06 13:03:46 +02:00
Akos Kitta
9d2297c684 fix: removed unsafe shell when executing process
Ref: PNX-3671

Co-authored-by: per1234 <accounts@perglass.com>
Co-authored-by: Akos Kitta <a.kitta@arduino.cc>

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-06-06 11:39:37 +02:00
Akos Kitta
e47fb2e651 fix: remove setting unsafe innerHTML
As it is vulnerable to stored Cross-Site Scripting.

Ref: PNX-3669
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-05-16 10:57:17 +02:00
Akos Kitta
ee43a12eb7 fix: show no errors if users cancel lib install
Throwing and catching a `UserAbortError` is part of the natural flow.

Closes #2063

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-05-16 10:56:39 +02:00
Akos Kitta
31deeebb49 test: use raw core index-update for the tests
It should make integration tests more resilient on the Windows CI.

From now on, tests are not starting a daemon to initialize the
`directories.data` folder for the test suites but rely on the raw
command. It is required to avoid spawning the discovery processes, which
cannot be terminated on Windows while the daemon is up and running.

Closes #2059

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-05-12 09:40:42 +02:00
Akos Kitta
117b2a4fc7 fix: do not enqueue write operations on conflict
Closes #2051

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-05-11 11:16:49 +02:00
Akos Kitta
278dd4ba87 fix: show notification if lib/core install failed
Closes #621

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-05-11 10:03:56 +02:00
Akos Kitta
36e2092398 build: use execa for the packager
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-05-09 17:37:24 +02:00
Akos Kitta
33ab2a6955 build: use execFileSync for npm scripts
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-05-09 17:37:24 +02:00
Akos Kitta
192aac5a81 chore: updated to Theia 1.37.0
- Updated `@theia/*` to `1.37.0`.
 - Fixed all `yarn audit` security vulnerabilities.
 - Updated to `electron@23.2.4`:
   - `contextIsolation` is `true`,
   - `nodeIntegration` is `false`, and the
   - `webpack` target is moved from `electron-renderer` to `web`.
 - Updated to `typescript@4.9.3`.
 - Updated the `eslint` plugins.
 - Added the new `Light High Contrast` theme to the IDE2.
 - High contrast themes use Theia APIs for style adjustments.
 - Support for ESM modules: `"moduleResolution": "node16"`.
 - Node.js >= 16.14 is required.
 - VISX langage packs were bumped to `1.70.0`.
 - Removed undesired editor context menu items. (Closes #1394)

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
2023-05-09 17:37:24 +02:00