diff --git a/CHANGELOG.md b/CHANGELOG.md index ce4a310be1d2..a16bb9380908 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -22,6 +22,28 @@ Code v99.99.999 ## Unreleased +Code v1.101.1 + +### Fixed + +- Fix web views not loading due to 401 when requesting the service worker. + +## [4.101.1](https://github.com/coder/code-server/releases/tag/v4.101.1) - 2025-06-20 + +Code v1.101.1 + +### Changed + +- Update to Code 1.101.1. + +## [4.101.0](https://github.com/coder/code-server/releases/tag/v4.101.0) - 2025-06-20 + +Code v1.101.0 + +### Changed + +- Update to Code 1.101.0. + ## [4.100.3](https://github.com/coder/code-server/releases/tag/v4.100.3) - 2025-06-03 Code v1.100.3 diff --git a/ci/dev/gen_icons.sh b/ci/dev/gen_icons.sh index 9d27486dcc57..049e9eef0864 100755 --- a/ci/dev/gen_icons.sh +++ b/ci/dev/gen_icons.sh @@ -1,44 +1,40 @@ #!/bin/sh set -eu +# Generate icons from a single favicon.svg. favicon.svg should have no fill +# colors set. main() { cd src/browser/media - # We need .ico for backwards compatibility. - # The other two are the only icon sizes required by Chrome and - # we use them for stuff like apple-touch-icon as well. - # https://web.dev/add-manifest/ + # We need .ico for backwards compatibility. The other two are the only icon + # sizes required by Chrome and we use them for stuff like apple-touch-icon as + # well. https://web.dev/add-manifest/ # # This should be enough and we can always add more if there are problems. - + # + # -quiet to avoid https://github.com/ImageMagick/ImageMagick/issues/884 # -background defaults to white but we want it transparent. + # -density somehow makes the image both sharper and smaller in file size. + # # https://imagemagick.org/script/command-line-options.php#background - convert -quiet -background transparent -resize 256x256 favicon.svg favicon.ico - # We do not generate the pwa-icon from the favicon as they are slightly different - # designs and sizes. - # See favicon.afdesign and #2401 for details on the differences. - convert -quiet -background transparent -resize 192x192 pwa-icon.png pwa-icon-192.png - convert -quiet -background transparent -resize 512x512 pwa-icon.png pwa-icon-512.png + convert -quiet -background transparent \ + -resize 256x256 -density 256x256 \ + favicon.svg favicon.ico - # We use -quiet above to avoid https://github.com/ImageMagick/ImageMagick/issues/884 + # Generate PWA icons. There should be enough padding to support masking. + convert -quiet -border 60x60 -bordercolor white -background white \ + -resize 192x192 -density 192x192 \ + favicon.svg pwa-icon-192.png + convert -quiet -border 160x160 -bordercolor white -background white \ + -resize 512x512 -density 512x512 \ + favicon.svg pwa-icon-512.png - # The following adds dark mode support for the favicon as favicon-dark-support.svg - # There is no similar capability for pwas or .ico so we can only add support to the svg. - favicon_dark_style="" - # See https://stackoverflow.com/a/22901380/4283659 - # This escapes all newlines so that sed will accept them. - favicon_dark_style="$(printf "%s\n" "$favicon_dark_style" | sed -e ':a' -e 'N' -e '$!ba' -e 's/\n/\\n/g')" - sed "$( - cat -n << EOF -s% favicon-dark-support.svg + # The following adds dark mode support for the favicon as + # favicon-dark-support.svg There is no similar capability for pwas or .ico so + # we can only add support to the svg. + favicon_dark_style="" + cp favicon.svg favicon-dark-support.svg + sed "s% favicon-dark-support.svg } main "$@" diff --git a/ci/helm-chart/Chart.yaml b/ci/helm-chart/Chart.yaml index e916ee26a2a6..2d03e966d2a0 100644 --- a/ci/helm-chart/Chart.yaml +++ b/ci/helm-chart/Chart.yaml @@ -15,9 +15,9 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 3.27.3 +version: 3.28.0 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to # follow Semantic Versioning. They should reflect the version the application is using. -appVersion: 4.100.3 +appVersion: 4.101.1 diff --git a/ci/helm-chart/values.yaml b/ci/helm-chart/values.yaml index 429292634612..2785e1bbc4f2 100644 --- a/ci/helm-chart/values.yaml +++ b/ci/helm-chart/values.yaml @@ -6,7 +6,7 @@ replicaCount: 1 image: repository: codercom/code-server - tag: '4.100.3' + tag: '4.101.1' pullPolicy: Always # Specifies one or more secrets to be used when pulling images from a diff --git a/flake.nix b/flake.nix index ea28a93b7dac..3a1f7efbc122 100644 --- a/flake.nix +++ b/flake.nix @@ -14,6 +14,7 @@ in { devShells.default = pkgs.mkShell { nativeBuildInputs = with pkgs; [ + imagemagick nodejs python3 pkg-config diff --git a/lib/vscode b/lib/vscode index 18e3a1ec544e..2901c5ac6db8 160000 --- a/lib/vscode +++ b/lib/vscode @@ -1 +1 @@ -Subproject commit 18e3a1ec544e6907be1e944a94c496e302073435 +Subproject commit 2901c5ac6db8a986a5666c3af51ff804d05af0d4 diff --git a/patches/webview.diff b/patches/webview.diff index 7ed4c32ff8f2..d6002fa017ab 100644 --- a/patches/webview.diff +++ b/patches/webview.diff @@ -71,10 +71,19 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/webview/browser/pre/index -+ content="default-src 'none'; script-src 'sha256-1qYtPnTQa4VwKNJO61EOhs2agF9TvuQSYIJ27OgzZqI=' 'self'; frame-src 'self'; style-src 'unsafe-inline';"> ++ content="default-src 'none'; script-src 'sha256-Oi71Tq4Buohx0KDH3yEbVJUzABnqYv9iVLo420HZXqI=' 'self'; frame-src 'self'; style-src 'unsafe-inline';"> { + /** + * @param {MessageEvent} event @@ -351,6 +351,12 @@ const hostname = location.hostname; diff --git a/src/browser/media/favicon-dark-support.svg b/src/browser/media/favicon-dark-support.svg index 06f1fa00d62c..d64bf32ed96e 100644 --- a/src/browser/media/favicon-dark-support.svg +++ b/src/browser/media/favicon-dark-support.svg @@ -1,7 +1,4 @@ - \ No newline at end of file + + + + diff --git a/src/browser/media/favicon.ico b/src/browser/media/favicon.ico index e721447bd9d1..56078ead6697 100644 Binary files a/src/browser/media/favicon.ico and b/src/browser/media/favicon.ico differ diff --git a/src/browser/media/favicon.svg b/src/browser/media/favicon.svg index 45388729b6b4..01a01541ec75 100644 --- a/src/browser/media/favicon.svg +++ b/src/browser/media/favicon.svg @@ -1 +1,3 @@ - \ No newline at end of file + + + diff --git a/src/browser/media/pwa-icon-192.png b/src/browser/media/pwa-icon-192.png index a6ee503115d8..3f28593b3aee 100644 Binary files a/src/browser/media/pwa-icon-192.png and b/src/browser/media/pwa-icon-192.png differ diff --git a/src/browser/media/pwa-icon-512.png b/src/browser/media/pwa-icon-512.png index ff42978ce9a5..7df85f7665ac 100644 Binary files a/src/browser/media/pwa-icon-512.png and b/src/browser/media/pwa-icon-512.png differ diff --git a/src/browser/media/pwa-icon.png b/src/browser/media/pwa-icon.png deleted file mode 100644 index d4f5188ffc0c..000000000000 Binary files a/src/browser/media/pwa-icon.png and /dev/null differ diff --git a/src/node/main.ts b/src/node/main.ts index 470ddeb25cc7..0d5c40928dfd 100644 --- a/src/node/main.ts +++ b/src/node/main.ts @@ -144,6 +144,8 @@ export const runCodeServer = async ( logger.info(" - Using password from $PASSWORD") } else if (args.usingEnvHashedPassword) { logger.info(" - Using password from $HASHED_PASSWORD") + } else if (args["hashed-password"]) { + logger.info(` - Using hashed-password from ${args.config}`) } else { logger.info(` - Using password from ${args.config}`) } diff --git a/src/node/routes/vscode.ts b/src/node/routes/vscode.ts index ed0bfa606ec3..62d7c80c4ba0 100644 --- a/src/node/routes/vscode.ts +++ b/src/node/routes/vscode.ts @@ -190,6 +190,7 @@ router.get("/manifest.json", async (req, res) => { src: `{{BASE}}/_static/src/browser/media/pwa-icon-${size}.png`, type: "image/png", sizes: `${size}x${size}`, + purpose: "maskable", })), }, null,