Skip to content
Open
Show file tree
Hide file tree
Changes from all 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
7 changes: 7 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,13 @@ jobs:
name: com.espressif.idf.update-${{ env.VERSION }}
path: releng/com.espressif.idf.update/target/repository

- name: Upload offline update site artifacts
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v4
with:
name: com.espressif.idf.update.offline-${{ env.VERSION }}
path: releng/com.espressif.idf.update.offline/target/repository

- name: Upload Windows x86_64 artifact
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v4
Expand Down
127 changes: 78 additions & 49 deletions .github/workflows/ci_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,70 +76,84 @@ jobs:
echo "Using certificate chain file"
fi

REPO_DIR="releng/com.espressif.idf.update/target/repository"
REPO_DIRS=(
"releng/com.espressif.idf.update/target/repository"
"releng/com.espressif.idf.update.offline/target/repository"
)
SIGFILE="ECLIPSE"

echo "Signing IDF plugin JARs in $REPO_DIR..."
echo "Only signing JARs matching com.espressif.* pattern..."

find "$REPO_DIR" -type f -name "*.jar" | while read -r file; do
if [[ "$file" =~ (plugins|features)/com\.espressif\. ]]; then
echo "Signing IDF plugin/feature JAR: $file"

jarsigner \
-J-cp -Jjsign-7.4.jar \
-J--add-modules -Jjava.sql \
-providerClass net.jsign.jca.JsignJcaProvider \
-providerArg "${{ secrets.AZURE_KEYVAULT_URI }}" \
-keystore NONE \
-storetype AZUREKEYVAULT \
-storepass "$AZURE_TOKEN" \
-sigfile "$SIGFILE" \
-digestalg SHA-256 \
-tsa http://timestamp.digicert.com \
$CERTCHAIN_ARG \
-certs \
-verbose \
"$file" \
"${{ secrets.AZURE_KEYVAULT_CERT_NAME }}"

if [ $? -eq 0 ]; then
echo "Successfully signed: $file"
for REPO_DIR in "${REPO_DIRS[@]}"; do
echo "Signing IDF plugin JARs in $REPO_DIR..."
echo "Only signing JARs matching com.espressif.* pattern..."

find "$REPO_DIR" -type f -name "*.jar" | while read -r file; do
if [[ "$file" =~ (plugins|features)/com\.espressif\. ]]; then
echo "Signing IDF plugin/feature JAR: $file"

jarsigner \
-J-cp -Jjsign-7.4.jar \
-J--add-modules -Jjava.sql \
-providerClass net.jsign.jca.JsignJcaProvider \
-providerArg "${{ secrets.AZURE_KEYVAULT_URI }}" \
-keystore NONE \
-storetype AZUREKEYVAULT \
-storepass "$AZURE_TOKEN" \
-sigfile "$SIGFILE" \
-digestalg SHA-256 \
-tsa http://timestamp.digicert.com \
$CERTCHAIN_ARG \
-certs \
-verbose \
"$file" \
"${{ secrets.AZURE_KEYVAULT_CERT_NAME }}"

if [ $? -eq 0 ]; then
echo "Successfully signed: $file"
else
echo "Failed to sign: $file"
exit 1
fi
else
echo "Failed to sign: $file"
exit 1
echo "Skipping non-IDF JAR: $file"
fi
else
echo "Skipping non-IDF JAR: $file"
fi
done
done

echo "JAR files signed!"

- name: Verify JAR signatures
run: |
echo "Verifying JAR signatures..."
find releng/com.espressif.idf.update/target/repository -type f -name "*.jar" | while read -r file; do
echo "Verifying: $file"
# Note: Certificate chain warnings are expected if CA is not in Java truststore
jarsigner -verify -verbose "$file" || true
for REPO_DIR in \
releng/com.espressif.idf.update/target/repository \
releng/com.espressif.idf.update.offline/target/repository; do
find "$REPO_DIR" -type f -name "*.jar" | while read -r file; do
echo "Verifying: $file"
# Note: Certificate chain warnings are expected if CA is not in Java truststore
jarsigner -verify -verbose "$file" || true
done
done

- name: Regenerate P2 metadata after signing
env:
MAVEN_OPTS: "-Djdk.xml.maxGeneralEntitySizeLimit=0 -Djdk.xml.maxParameterEntitySizeLimit=0 -Djdk.xml.totalEntitySizeLimit=0 -Djdk.xml.entityExpansionLimit=0"
run: |
REPO_DIR="releng/com.espressif.idf.update/target/repository"

echo "Updating P2 metadata for signed JARs in $REPO_DIR..."
mvn -f releng/com.espressif.idf.update/pom.xml \
org.eclipse.tycho:tycho-p2-repository-plugin:fix-artifacts-metadata \
-DrepositoryPath="$REPO_DIR" \
-DskipTests=true || \
mvn -f releng/com.espressif.idf.update/pom.xml \
org.eclipse.tycho:tycho-p2-repository-plugin:fix-artifacts-metadata \
-DskipTests=true

update_p2_metadata() {
local POM="$1"
local REPO_DIR="$2"
echo "Updating P2 metadata for signed JARs in $REPO_DIR..."
mvn -f "$POM" \
org.eclipse.tycho:tycho-p2-repository-plugin:fix-artifacts-metadata \
-DrepositoryPath="$REPO_DIR" \
-DskipTests=true || \
mvn -f "$POM" \
org.eclipse.tycho:tycho-p2-repository-plugin:fix-artifacts-metadata \
-DskipTests=true
}

update_p2_metadata releng/com.espressif.idf.update/pom.xml releng/com.espressif.idf.update/target/repository
update_p2_metadata releng/com.espressif.idf.update.offline/pom.xml releng/com.espressif.idf.update.offline/target/repository

echo "P2 metadata updated with correct hashes for signed JARs"

- name: Cleanup
Expand Down Expand Up @@ -218,12 +232,19 @@ jobs:
name: espressif-ide-macosx.cocoa.aarch64
path: releng/ide-dmg-builder/Espressif-IDE-macosx-cocoa-aarch64.dmg

- name: Upload build artifacts
- name: Upload online update site
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v4
with:
name: com.espressif.idf.update
path: releng/com.espressif.idf.update/target/repository

- name: Upload offline update site
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v4
with:
name: com.espressif.idf.update.offline
path: releng/com.espressif.idf.update.offline/target/repository

- name: Upload windows rcp
if: ${{ !cancelled() }}
Expand Down Expand Up @@ -373,12 +394,18 @@ jobs:
name: espressif-ide-macosx.cocoa.aarch64
path: artifacts/macos_arm

- name: Download update site zip
- name: Download online update site zip
uses: actions/download-artifact@v4
with:
name: com.espressif.idf.update
path: artifacts/update

- name: Download offline update site
uses: actions/download-artifact@v4
with:
name: com.espressif.idf.update.offline
path: artifacts/update_offline

- name: Extract version from tag and prepare folder
id: get_version
run: |
Expand Down Expand Up @@ -410,6 +437,7 @@ jobs:
run: |
VERSION="${{ env.VERSION }}"
zip -r "com.espressif.idf.update-v$VERSION.zip" artifacts/update/*
zip -r "Espressif-IDE-Offline-Update-v$VERSION.zip" artifacts/update_offline/*
zip -r "Espressif-IDE-$VERSION-win32.win32.x86_64.zip" artifacts/win32/*

- name: Listing files for upload to verify and debug
Expand Down Expand Up @@ -441,6 +469,7 @@ jobs:
aws s3 cp --acl=public-read ./releng/index.html "s3://${{ secrets.DL_BUCKET }}/dl/idf-eclipse-plugin/updates/$UPLOAD_PATH/"

aws s3 cp --acl=public-read "com.espressif.idf.update-v$VERSION.zip" "s3://${{ secrets.DL_BUCKET }}/dl/idf-eclipse-plugin/updates/"
aws s3 cp --acl=public-read "Espressif-IDE-Offline-Update-v$VERSION.zip" "s3://${{ secrets.DL_BUCKET }}/dl/idf-eclipse-plugin/updates/"
aws s3 cp --acl=public-read --recursive artifacts/linux/ "s3://${{ secrets.DL_BUCKET }}/dl/idf-eclipse-plugin/ide/"
aws s3 cp --acl=public-read --recursive artifacts/linux_arm64/ "s3://${{ secrets.DL_BUCKET }}/dl/idf-eclipse-plugin/ide/"
aws s3 cp --acl=public-read "artifacts/macos_x86/Espressif-IDE-macosx-cocoa-x86_64-v$VERSION.dmg" "s3://${{ secrets.DL_BUCKET }}/dl/idf-eclipse-plugin/ide/"
Expand Down
61 changes: 43 additions & 18 deletions docs/en/marketplaceupdate.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,11 @@ The Espressif-IDE Eclipse Plugin can be installed using the following three meth
- :ref:`install_idf_eclipse_plugin_marketplace`
- :ref:`install_idf_eclipse_plugin_local_archive`

Release builds publish two kinds of update sites:

- **Online update site** — contains the ESP-IDF Eclipse Plugin feature only. Dependencies (Eclipse Platform, Embed CDT, LSP4E, and others) are resolved from referenced Eclipse update sites during installation. An internet connection is required.
- **Offline update site** — bundles the ESP-IDF Eclipse Plugin and its dependencies for installation without network access. Use this archive in air-gapped or restricted environments.

.. _installUpdateSiteURL:

Installing IDF Plugin Using the Update Site URL
Expand All @@ -25,7 +30,11 @@ You can install the IDF Eclipse plugin into an existing Eclipse CDT/Espressif-ID
* Enter ``Location`` of the repository. (`Stable release <https://dl.espressif.com/dl/idf-eclipse-plugin/updates/latest/>`_)
* Click ``Add``.

3. Select all items from the list and proceed with the installation.
3. Select ``ESP-IDF Eclipse Plugin`` from the list and proceed with the installation. p2 resolves required dependencies from the Eclipse release train and other referenced update sites.

.. note::

The online update site requires an internet connection. Dependencies are not bundled in the site itself; they are fetched from Eclipse Platform, Nebula, and SWTChart repositories during installation.

For adding beta and nightly builds, you can use the following update site URLs:

Expand Down Expand Up @@ -57,15 +66,24 @@ To install the ESP-IDF Eclipse Plugin from the Eclipse Marketplace, follow these
Installing IDF Eclipse Plugin from Local Archive
------------------------------------------------

To install the ESP-IDF Eclipse Plugin from a local archive, follow these steps:
Download update site archives from `GitHub Releases <https://github.com/espressif/idf-eclipse-plugin/releases>`_ or from `dl.espressif.com <https://dl.espressif.com/dl/idf-eclipse-plugin/updates/>`_.

Choose the archive that matches your environment:

1. Download the latest update site archive for the IDF Eclipse Plugin from `here <https://github.com/espressif/idf-eclipse-plugin/releases>`_.
2. In Eclipse, go to ``Help`` > ``Install New Software``.
3. Click the ``Add`` button.
4. In the ``Add Repository`` dialog, select ``Archive`` and choose the file ``com.espressif.idf.update-vxxxxxxx.zip``.
5. Click ``Add``.
6. Select ``Espressif IDF`` from the list and continue with the installation.
7. After the installation is complete, restart Eclipse.
Online update site archive (``com.espressif.idf.update-vX.Y.Z.zip``)
Same content as the online update site URL. Requires an internet connection to resolve dependencies during installation.

Offline update site archive (``Espressif-IDE-Offline-Update-vX.Y.Z.zip``)
Self-contained archive for environments without network access. Includes the ESP-IDF Eclipse Plugin and its bundled dependencies.

To install from either archive:

1. In Eclipse, go to ``Help`` > ``Install New Software``.
2. Click the ``Add`` button.
3. In the ``Add Repository`` dialog, select ``Archive`` and choose the downloaded ``.zip`` file.
4. Click ``Add``.
5. Select ``ESP-IDF Eclipse Plugin`` from the list and continue with the installation.
6. After the installation is complete, restart Eclipse.

.. _upgradePlugins:

Expand All @@ -76,7 +94,7 @@ If you are installing the IDF Eclipse Plugin for the first time, follow these st

1. Go to ``Window`` > ``Preferences`` > ``Install/Update`` > ``Available Software Sites``.
2. Click ``Add``.
3. Enter the `URL <https://dl.espressif.com/dl/idf-eclipse-plugin/updates/latest/>`_ of the new repository: .
3. Enter the `URL <https://dl.espressif.com/dl/idf-eclipse-plugin/updates/latest/>`_ of the new repository.
4. Click ``Ok``.

If you have already installed the IDF Eclipse Plugin using the update site URL, you can upgrade to the latest version with the following steps:
Expand Down Expand Up @@ -118,19 +136,26 @@ This ensures that the installer can update or replace any conflicting components
Troubleshooting
---------------

If you encounter the error ``Cannot complete the install because one or more required items could not be found.`` during installation, it usually means that the Eclipse Platform update site is not enabled.
If you encounter the error ``Cannot complete the install because one or more required items could not be found.`` during installation, try the following:

To resolve this issue:
**Online update site URL or online archive (``com.espressif.idf.update-vX.Y.Z.zip``)**

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Suggested change
**Online update site URL or online archive (``com.espressif.idf.update-vX.Y.Z.zip``)**
**Online update site URL or online archive** (``com.espressif.idf.update-vX.Y.Z.zip``)


1. Go to ``Help`` > ``Install New Software``.
2. Click ``Manage``.
3. Make sure the option for the ``Eclipse Platform - Latest Release Update Site`` is enabled.
This usually means that a required dependency update site is not enabled or the IDE cannot reach it over the network.

1. Confirm that the IDE has internet access.
2. Go to ``Help`` > ``Install New Software``.
3. Click ``Manage``.
4. Make sure the option for the ``Eclipse Platform - Latest Release Update Site`` is enabled.

.. image:: ../../media/Resolve_update_error_2.png

4. Apply the changes and close the dialog.
5. Then go to ``Help`` > ``Check for Updates`` and proceed with updating the IDE and its dependencies.
5. Apply the changes and close the dialog.
6. Then go to ``Help`` > ``Check for Updates`` and proceed with updating the IDE and its dependencies.

.. note::

Enabling the Eclipse Platform update site ensures that all required dependencies are properly resolved during installation or upgrade.
Enabling the Eclipse Platform update site ensures that all required dependencies are properly resolved during installation or upgrade from the online update site.

**Offline archive** (``Espressif-IDE-Offline-Update-vX.Y.Z.zip``)

If installation from the offline archive still fails, verify that you downloaded the matching offline archive for your Espressif-IDE or Eclipse version and that the archive was not corrupted during download.
Loading
Loading