According to the electron-builder docs, executableName defaults to the
productName when not specified. However, in reality it was actually
using the app name as default for the linux build, which is a bug that
got patched recently, see:
https://github.com/electron-userland/electron-builder/issues/8766
Because we relied on this bug and on executableName defaulting to app
name for the linux build, we explicitly set it to appName for all
builds, see: f81fddd, but this caused an executableName change on MacOS.
Close#9389
Fix more generic x64ArchFiles that covers the actual path after building
the app, something like
Contents/Resources/app.asar.unpacked/desktop/node-mimimi.darwin-arm64.node
It isn't invoked automatically anywhere but the editors should pick it
up and it can also be run manually.
It also fixes few little issues, e.g. getPrebuiltNativeModuleForWindows
was getting called with the right arguments.
Added a new flag `-a` which allows the developer to set the architecture
of the built client. It causes an error when an unsupported combination
of platform & architecture is used. By default, it uses the architecture
the installed node binary uses.
two ways this can happen:
* starting on old domain
* starting on new domain
in each case, the starting tab opens the other domain in a new
tab to then use window.postMessage to transfer the credentials.
* according to rollups type definitions, the output option property is
ignored by rollup.rollup, so it moved to bundle.write
* we don't use commonjs deps in the desktop bundle anymore, so the
commonjs plugin can go away from DesktopBuilder
[build] remove some unnecessary rollup plugins
[build] unify the native plugins
[build] vendor keytar
[build] vendor better-sqlite3 deps and restrict module resolution
it's now checked in and can be updated with buildSrc/updateLibs.js
close#4213
5.3.0 couldn't handle windows machines with a restricted powershell.
6.0.0 fixed that, but the alpha that's currently available does not
work on linux because it's opening the child process wrong.
node-forge is a pure JS crypto library that was used during the build
process to sign the clients and at runtime to verify the signature
before downloading the updated client:
* check the update manifest on the server, if the version is higher
than installed:
* get the sha512 digest and signature from the manifest and verify the
signature (node-forge only requires the digest, not the data)
if it matches:
* download the update and let electron-updater do its thing
with this change, we have to download the update first because node
crypto requires the data to verify the signature (digest is calculated
internally). In case the signature doesn't match, we delete the
downloaded file and stop polling for updates for this run.
forge was also used to get a private key for signing out of a
self-signed cert in development environments. from now on, this is done
by providing PEM encoded private and public keys.
close#3832
mainly making the OfflineIndicatorViewModel init more async because
it's running into an uninitialized locator when initialized during
header construction.
#3815
1. Change getVersion() in nativeLibraryProvider to handle curious
`npm list` behavior.
2. Reorganize rollup plugins so that admin client can import our helper
plugins without importing rollup plugins from node_modules. This makes
it more resilient when we link against local tutanota-3 (libs hoisted
to upper level will not be found across the symlink).
3. Change LaunchHtml to not rely on mithril for the same reason.
This commit not only sets up the build for windows on jenkins,
it also consolidates how we get prebuilt binaries for native modules i.e. keytar and better-sqlite3
and generally has some refactorings
Compiling keytar in postinstall is problematic because we need node-gyp
to successfully finish installation. Because of that it is hard to
depend on tutanota-3 (e.g. in admin client).
Doing this on demand avoids the issue.
adds spell check & correction capabilities to the context menu,
including the ability to change the checked language.
dictionaries are pulled from <updateUrl>/../dictionaries/ except
for custom builds. in that case, the downloader is pointed to
mail.tutanota.com/desktop/dictionaries/
the dist.js build script gained a --get-dicts flag, which will
result in the dictionaries released with the used electron version being
downloaded from
https://github.com/electron/electron/releases/
download/v${version}/hunspell_dictionaries.zip
and extracted into a directory next to the given --out-dir
or build/dist/dictionaries during the build.
should the build not create .deb packages, the dicts
will end up next to the desktop installers since the
local tutadb will serve them from there.
to create these signatures, run the dist script with the environment
variable DEBUG_SIGN set to a directory containing a self-signed code
signing cert file test.p12
close#2918
The preload script required some access to the window object of the renderer
thread to implement browser functionality that's missing in a BrowserWindow.
This prevented use of the contextI isolation option.
This commit moves that functionality from the preload script to either the main
thread or the web app so we can enable context isolation.
* mouse wheel zoom was moved to the main thread, listening to the new
zoom-changed event on WebContents (ApplicationWindow.js)
* url reveal on hover was split into a main part listening on update-target-url
on WebContent (ApplicationWindow.js) and a new NativeWrapperCommand to fill in
the url element
* the fix for MacOS navigation history when trying to navigate a text box with
cmd+arrows moved to WindowFacade.js
* the SearchPageOverlay now fixes the non-detection of focus change itself
* unregistering the window on unload moved to ApplicationWindow.js, detecting
a reload in the did-start-navigation handler
* the fix for the nonfunctional window focus was removed since it works in current
electron versions
all windows now use the same ipc channel, the IPC component uses the Event sender
to route responses back to the correct window, removing the need to set up
the channel with the window id