License configuration¶
If not already done, please request a license key from useblocks. The process for this is not yet automated, so please contact our support directly via e-mail.
To configure the license for ubCode, place a file named ubcode.toml
in the following location:
For Linux:
~/.config/ubcode/ubcode.toml
For Windows:
C:\Users\<username>\AppData\Local\useblocks\ubcode\ubcode.toml
For MacOS:
~/Library/Application Support/ubcode/ubcode.toml
The file should have the following content:
[license]
key = "AAAAA-BBBBB-CCCCC-DDDDD"
user = "mail@example.com"
If you add or change the key, to let it take effect in the VS Code extension,
you need to restart the server, with the command Ctrl+Shift+P
and then
ubCode: Restart language server
.
Proxies¶
License activation requires an active Internet connection. System proxies are automatically detected and used by ubCode.
If that fails or cannot be done on system level,
the proxy server can also be configured in a dedicated section of ubcode.toml
:
[proxy]
https = "<proxy-domain-or-ip>"
Note
ubCode only supports HTTP CONNECT proxies.
Environmental variables¶
In the CLI, environmental variables can also set, to override the configuration in the ubcode.toml
file:
UBCODE_LICENSE_KEY
: The license key.UBCODE_LICENSE_USER
: The user e-mail.UBCODE_HTTPS_PROXY
: The proxy server.
License handling¶
License keys supplied by useblocks are commonly user based, which means a valid user e-mail must be provided with the license key.
For data protection, the e-mail is irreversibly obfuscated on the local user’s machine, before being sent to the license server for activation.
Caching¶
Online license requests are cached locally for 3 days to avoid unnecessary network traffic, faster startup times and to be able to work offline for a limited time.
Offline licenses¶
If agreed upon, useblocks can also provide offline licenses. The provided license file is configured as follows:
[license]
file = "ActivationFile.skm"
user = "mail@example.com"
If the license file is placed in the same directory as the ubcode.toml
file and named “ActivationFile.skm”,
it will be picked up automatically.
A user is still required for offline licenses, but the property key
is not needed.