diff --git a/Cargo.toml b/Cargo.toml index 1a0587091..b8e1cd00c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -31,9 +31,9 @@ serde_derive = { version = "1.0" } inkwell = { version = "0.4.0", features = ["target-webassembly", "no-libffi-linking", "llvm16-0"], optional = true } blake2-rfc = "0.2.18" handlebars = "5.1" -contract-metadata = "3.2" +contract-metadata = "4.0.2" semver = { version = "1.0", features = ["serde"] } -tempfile = "3.9" +tempfile = "3.10" libc = { version = "0.2", optional = true } tower-lsp = { version = "0.20", optional = true } tokio = { version = "1.27", features = ["rt", "io-std", "macros"], optional = true } @@ -58,11 +58,11 @@ ink_env = "5.0.0" ink_metadata = "5.0.0" scale-info = "2.10" petgraph = "0.6" -wasmparser = "0.121.0" -wasm-encoder = "0.41" +wasmparser = "0.202.0" +wasm-encoder = "0.202" toml = "0.8" -wasm-opt = { version = "0.113.0", optional = true } -contract-build = { version = "3.2", optional = true } +wasm-opt = { version = "0.116.0", default-features = false, optional = true } +contract-build = { version = "4.0.2", optional = true } primitive-types = { version = "0.12", features = ["codec"] } normalize-path = "0.2.1" bitflags = "2.4" diff --git a/integration/anchor/tests/call_anchor.spec.ts b/integration/anchor/tests/call_anchor.spec.ts index af8d30277..ff9e558b4 100644 --- a/integration/anchor/tests/call_anchor.spec.ts +++ b/integration/anchor/tests/call_anchor.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { AnchorProvider, Program } from '@coral-xyz/anchor'; import { diff --git a/integration/polkadot/UniswapV2ERC20.spec.ts b/integration/polkadot/UniswapV2ERC20.spec.ts index ae98bc298..e95f1a75c 100644 --- a/integration/polkadot/UniswapV2ERC20.spec.ts +++ b/integration/polkadot/UniswapV2ERC20.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, daveKeypair, query } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/UniswapV2Factory.spec.ts b/integration/polkadot/UniswapV2Factory.spec.ts index 8afcea625..f1549282b 100644 --- a/integration/polkadot/UniswapV2Factory.spec.ts +++ b/integration/polkadot/UniswapV2Factory.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, daveKeypair, query } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/UniswapV2Pair.spec.ts b/integration/polkadot/UniswapV2Pair.spec.ts index e648baeaa..69906b6c9 100644 --- a/integration/polkadot/UniswapV2Pair.spec.ts +++ b/integration/polkadot/UniswapV2Pair.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, query, createConnection, deploy, transaction, aliceKeypair, daveKeypair } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/array_struct_mapping_storage.spec.ts b/integration/polkadot/array_struct_mapping_storage.spec.ts index cd0f23f66..b67457a1a 100644 --- a/integration/polkadot/array_struct_mapping_storage.spec.ts +++ b/integration/polkadot/array_struct_mapping_storage.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, aliceKeypair, transaction, query } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/arrays.spec.ts b/integration/polkadot/arrays.spec.ts index af516acc5..8b70e1a9c 100644 --- a/integration/polkadot/arrays.spec.ts +++ b/integration/polkadot/arrays.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import crypto from 'crypto'; import { createConnection, deploy, transaction, aliceKeypair, weight, query, } from './index'; diff --git a/integration/polkadot/asserts.spec.ts b/integration/polkadot/asserts.spec.ts index 586c168c2..ec3bc437b 100644 --- a/integration/polkadot/asserts.spec.ts +++ b/integration/polkadot/asserts.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/balances.spec.ts b/integration/polkadot/balances.spec.ts index c7b9e2be9..6e8ea3ac5 100644 --- a/integration/polkadot/balances.spec.ts +++ b/integration/polkadot/balances.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, daveKeypair, query } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/builtins.spec.ts b/integration/polkadot/builtins.spec.ts index 661c98390..a73e2dc4d 100644 --- a/integration/polkadot/builtins.spec.ts +++ b/integration/polkadot/builtins.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { createConnection, deploy, transaction, aliceKeypair, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/builtins2.spec.ts b/integration/polkadot/builtins2.spec.ts index 4c9cb9dd4..30ac09bdd 100644 --- a/integration/polkadot/builtins2.spec.ts +++ b/integration/polkadot/builtins2.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { createConnection, deploy, aliceKeypair, weight, query } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/call_flags.spec.ts b/integration/polkadot/call_flags.spec.ts index d6b5784b0..3a2c2d289 100644 --- a/integration/polkadot/call_flags.spec.ts +++ b/integration/polkadot/call_flags.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { createConnection, deploy, aliceKeypair, query, debug_buffer, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/caller_is_root.spec.ts b/integration/polkadot/caller_is_root.spec.ts index 814f22852..ea42afb1b 100644 --- a/integration/polkadot/caller_is_root.spec.ts +++ b/integration/polkadot/caller_is_root.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { createConnection, deploy, aliceKeypair, query, weight, transaction } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/chain_extension.spec.ts b/integration/polkadot/chain_extension.spec.ts index c19ae11de..542fea043 100644 --- a/integration/polkadot/chain_extension.spec.ts +++ b/integration/polkadot/chain_extension.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { createConnection, deploy, aliceKeypair, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/constructor_dispatch.spec.ts b/integration/polkadot/constructor_dispatch.spec.ts index 6851731ec..332820cf4 100644 --- a/integration/polkadot/constructor_dispatch.spec.ts +++ b/integration/polkadot/constructor_dispatch.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import { createConnection, deploy, aliceKeypair, query, debug_buffer, weight, transaction, daveKeypair, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; import { ApiPromise } from '@polkadot/api'; diff --git a/integration/polkadot/create_contract.spec.ts b/integration/polkadot/create_contract.spec.ts index 67603f497..009352e88 100644 --- a/integration/polkadot/create_contract.spec.ts +++ b/integration/polkadot/create_contract.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, query, debug_buffer, dry_run, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/debug_buffer_format.spec.ts b/integration/polkadot/debug_buffer_format.spec.ts index f336de3d0..0f5878a61 100644 --- a/integration/polkadot/debug_buffer_format.spec.ts +++ b/integration/polkadot/debug_buffer_format.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import { createConnection, deploy, aliceKeypair, debug_buffer } from "./index"; import expect from 'expect'; import { ContractPromise } from "@polkadot/api-contract"; diff --git a/integration/polkadot/delegate_call.spec.ts b/integration/polkadot/delegate_call.spec.ts index d03125611..94c6be58c 100644 --- a/integration/polkadot/delegate_call.spec.ts +++ b/integration/polkadot/delegate_call.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, daveKeypair, debug_buffer, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/destruct.spec.ts b/integration/polkadot/destruct.spec.ts index b1e956e07..0e6f4b717 100644 --- a/integration/polkadot/destruct.spec.ts +++ b/integration/polkadot/destruct.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, daveKeypair, query } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/events.spec.ts b/integration/polkadot/events.spec.ts index fde537c11..e3ba79bef 100644 --- a/integration/polkadot/events.spec.ts +++ b/integration/polkadot/events.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/external_call.spec.ts b/integration/polkadot/external_call.spec.ts index 4e4a2100a..c010b414a 100644 --- a/integration/polkadot/external_call.spec.ts +++ b/integration/polkadot/external_call.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/flipper.spec.ts b/integration/polkadot/flipper.spec.ts index 38fc2f791..fca1fb43d 100644 --- a/integration/polkadot/flipper.spec.ts +++ b/integration/polkadot/flipper.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/index.ts b/integration/polkadot/index.ts index e75acb877..d02ee613f 100644 --- a/integration/polkadot/index.ts +++ b/integration/polkadot/index.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import '@polkadot/api-augment'; import fs, { PathLike } from 'fs'; import { ApiPromise, WsProvider, Keyring } from '@polkadot/api'; diff --git a/integration/polkadot/ink_cross_calls.spec.ts b/integration/polkadot/ink_cross_calls.spec.ts index 8ce0486fa..a7c6159da 100644 --- a/integration/polkadot/ink_cross_calls.spec.ts +++ b/integration/polkadot/ink_cross_calls.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/is_contract.spec.ts b/integration/polkadot/is_contract.spec.ts index 6d18a41a3..fec01014d 100644 --- a/integration/polkadot/is_contract.spec.ts +++ b/integration/polkadot/is_contract.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { createConnection, deploy, aliceKeypair, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/issue666.spec.ts b/integration/polkadot/issue666.spec.ts index ff23ed68e..5292728e2 100644 --- a/integration/polkadot/issue666.spec.ts +++ b/integration/polkadot/issue666.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/msg_sender.spec.ts b/integration/polkadot/msg_sender.spec.ts index 7b47b01d9..c064a9f63 100644 --- a/integration/polkadot/msg_sender.spec.ts +++ b/integration/polkadot/msg_sender.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from "expect"; import { aliceKeypair, createConnection, deploy, weight, transaction, query } from "./index"; import { ContractPromise } from "@polkadot/api-contract"; diff --git a/integration/polkadot/overloading.spec.ts b/integration/polkadot/overloading.spec.ts index b812ca16f..58e9ee7c1 100644 --- a/integration/polkadot/overloading.spec.ts +++ b/integration/polkadot/overloading.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { createConnection, deploy, transaction, aliceKeypair, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/primitives.spec.ts b/integration/polkadot/primitives.spec.ts index 398b0bba8..e8c7e461b 100644 --- a/integration/polkadot/primitives.spec.ts +++ b/integration/polkadot/primitives.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { createConnection, deploy, aliceKeypair, daveKeypair, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/release_version.spec.ts b/integration/polkadot/release_version.spec.ts index e56ccbbe1..e3f4d0063 100644 --- a/integration/polkadot/release_version.spec.ts +++ b/integration/polkadot/release_version.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import { createConnection, deploy, aliceKeypair, debug_buffer } from "./index"; import expect from 'expect'; import { ContractPromise } from "@polkadot/api-contract"; diff --git a/integration/polkadot/runtime_errors.spec.ts b/integration/polkadot/runtime_errors.spec.ts index 5bdae1961..bf75d927a 100644 --- a/integration/polkadot/runtime_errors.spec.ts +++ b/integration/polkadot/runtime_errors.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import { createConnection, deploy, aliceKeypair, debug_buffer } from "./index"; import expect from 'expect'; import { ContractPromise } from "@polkadot/api-contract"; diff --git a/integration/polkadot/set_code_hash.spec.ts b/integration/polkadot/set_code_hash.spec.ts index a588405af..e1fccbe91 100644 --- a/integration/polkadot/set_code_hash.spec.ts +++ b/integration/polkadot/set_code_hash.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { createConnection, deploy, aliceKeypair, query, debug_buffer, weight, transaction, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/store.spec.ts b/integration/polkadot/store.spec.ts index 2e3f5365b..6988035c1 100644 --- a/integration/polkadot/store.spec.ts +++ b/integration/polkadot/store.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/structs.spec.ts b/integration/polkadot/structs.spec.ts index 8d005004c..afdf96d89 100644 --- a/integration/polkadot/structs.spec.ts +++ b/integration/polkadot/structs.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { createConnection, deploy, transaction, aliceKeypair, weight, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/tornado.spec.ts b/integration/polkadot/tornado.spec.ts index c3bf0e816..84028501e 100644 --- a/integration/polkadot/tornado.spec.ts +++ b/integration/polkadot/tornado.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + // Tests against the tornado cash core contracts. // The tornado contracts used here contain minor mechanical changes to work fine on Polkadot. // The ZK-SNARK setup is the same as ETH Tornado on mainnet. diff --git a/integration/polkadot/try_catch.spec.ts b/integration/polkadot/try_catch.spec.ts index f110a1528..03fbaafc6 100644 --- a/integration/polkadot/try_catch.spec.ts +++ b/integration/polkadot/try_catch.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { createConnection, deploy, aliceKeypair, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/polkadot/upgradeable_proxy.spec.ts b/integration/polkadot/upgradeable_proxy.spec.ts index be7c9de3f..e3f918986 100644 --- a/integration/polkadot/upgradeable_proxy.spec.ts +++ b/integration/polkadot/upgradeable_proxy.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { weight, createConnection, deploy, transaction, aliceKeypair, query, } from './index'; import { ContractPromise } from '@polkadot/api-contract'; diff --git a/integration/solana/simple.spec.ts b/integration/solana/simple.spec.ts index 906736b28..ed31ad2ca 100644 --- a/integration/solana/simple.spec.ts +++ b/integration/solana/simple.spec.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import expect from 'expect'; import { loadContractAndCallConstructor } from './setup'; import crypto from 'crypto'; diff --git a/src/abi/polkadot.rs b/src/abi/polkadot.rs index 5c1e5aaf6..30eb6bf8f 100644 --- a/src/abi/polkadot.rs +++ b/src/abi/polkadot.rs @@ -606,5 +606,5 @@ pub fn metadata( let project_json = serde_json::to_value(gen_project(contract_no, ns)).unwrap(); let abi = serde_json::from_value(project_json).unwrap(); - serde_json::to_value(ContractMetadata::new(source, contract, None, abi)).unwrap() + serde_json::to_value(ContractMetadata::new(source, contract, None, None, abi)).unwrap() } diff --git a/vscode/src/client/extension.ts b/vscode/src/client/extension.ts index c723760a6..bc470aaba 100644 --- a/vscode/src/client/extension.ts +++ b/vscode/src/client/extension.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + // The module 'vscode' contains the VS Code extensibility API // Import the module and reference it with the alias vscode in your code below import * as vscode from 'vscode'; diff --git a/vscode/src/server/server.ts b/vscode/src/server/server.ts index a1d81cbf1..8ea6d8b50 100644 --- a/vscode/src/server/server.ts +++ b/vscode/src/server/server.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import { createConnection, InitializeResult, DefinitionRequest } from 'vscode-languageserver'; import * as rpc from 'vscode-jsonrpc'; diff --git a/vscode/src/test/runTest.ts b/vscode/src/test/runTest.ts index 014c3a28f..c8d3f9fd2 100644 --- a/vscode/src/test/runTest.ts +++ b/vscode/src/test/runTest.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import * as path from 'path'; import { runTests } from '@vscode/test-electron'; diff --git a/vscode/src/test/suite/extension.test.ts b/vscode/src/test/suite/extension.test.ts index d7357b06f..9a891c71b 100644 --- a/vscode/src/test/suite/extension.test.ts +++ b/vscode/src/test/suite/extension.test.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import * as assert from 'assert'; import * as vscode from 'vscode'; diff --git a/vscode/src/test/suite/helper.ts b/vscode/src/test/suite/helper.ts index a5cef66df..c94347004 100644 --- a/vscode/src/test/suite/helper.ts +++ b/vscode/src/test/suite/helper.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import * as vscode from 'vscode'; import * as path from 'path'; diff --git a/vscode/src/test/suite/index.ts b/vscode/src/test/suite/index.ts index 2cc239093..25eb58cc3 100644 --- a/vscode/src/test/suite/index.ts +++ b/vscode/src/test/suite/index.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import * as path from 'path'; import * as Mocha from 'mocha'; import * as glob from 'glob'; diff --git a/vscode/src/utils/download.ts b/vscode/src/utils/download.ts index 19d13ace0..ccbd4e50e 100644 --- a/vscode/src/utils/download.ts +++ b/vscode/src/utils/download.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import * as vscode from 'vscode'; import * as path from 'path'; import * as crypto from 'crypto'; diff --git a/vscode/src/utils/downloadFile.ts b/vscode/src/utils/downloadFile.ts index 1874c22a4..de8cddff9 100644 --- a/vscode/src/utils/downloadFile.ts +++ b/vscode/src/utils/downloadFile.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import fetch from 'node-fetch'; import { PathLike, createWriteStream } from 'fs'; import * as stream from 'stream'; diff --git a/vscode/src/utils/downloadWithRetryDialog.ts b/vscode/src/utils/downloadWithRetryDialog.ts index 9e8d8ba2a..e5c758674 100644 --- a/vscode/src/utils/downloadWithRetryDialog.ts +++ b/vscode/src/utils/downloadWithRetryDialog.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import * as vscode from 'vscode'; export default async function downloadWithRetryDialog(downloadFunc: () => Promise): Promise { diff --git a/vscode/src/utils/executableVersion.ts b/vscode/src/utils/executableVersion.ts index 4cd8c14fb..b814dd389 100644 --- a/vscode/src/utils/executableVersion.ts +++ b/vscode/src/utils/executableVersion.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import { spawnSync } from 'child_process'; export default function executableVersion(path: string): string | undefined { diff --git a/vscode/src/utils/expandPathResolving.ts b/vscode/src/utils/expandPathResolving.ts index d28a22d3b..fb50ef4ef 100644 --- a/vscode/src/utils/expandPathResolving.ts +++ b/vscode/src/utils/expandPathResolving.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import { homedir } from 'os'; export default function expandPathResolving(path: string): string { diff --git a/vscode/src/utils/fetchLatestRelease.ts b/vscode/src/utils/fetchLatestRelease.ts index c85883fbe..8df10155f 100644 --- a/vscode/src/utils/fetchLatestRelease.ts +++ b/vscode/src/utils/fetchLatestRelease.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import fetch from 'node-fetch'; export default async function fetchLatestRelease() { diff --git a/vscode/src/utils/getPlatform.ts b/vscode/src/utils/getPlatform.ts index ac32b5267..0bd6d2604 100644 --- a/vscode/src/utils/getPlatform.ts +++ b/vscode/src/utils/getPlatform.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + export default function getPlatform(): string | undefined { switch (`${process.arch} ${process.platform}`) { case 'x64 win32': diff --git a/vscode/src/utils/getServer.ts b/vscode/src/utils/getServer.ts index 40245c88c..d239934ff 100644 --- a/vscode/src/utils/getServer.ts +++ b/vscode/src/utils/getServer.ts @@ -1,3 +1,5 @@ +// SPDX-License-Identifier: Apache-2.0 + import * as vscode from 'vscode'; import * as path from 'path'; import { promises as fs } from 'fs';