Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
bridgecontract
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
movabridge
bridgecontract
Commits
6a2ff743
Commit
6a2ff743
authored
Nov 14, 2025
by
vicotor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update add token
parent
2a13fa70
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
+7
-2
addtokens.js
scripts/addtokens.js
+7
-2
No files found.
scripts/addtokens.js
View file @
6a2ff743
...
...
@@ -35,13 +35,17 @@ async function getDeploy(chainId) {
}
async
function
setOutConfig
(
bridge
,
tokenPair
)
{
const
tokenContract
=
await
hre
.
ethers
.
getContractAt
(
"
TestToken
"
,
tokenPair
.
token
);
var
decimals
=
await
tokenContract
.
decimals
();
const
outConfig
=
{
receiveToken
:
tokenPair
.
targetToken
,
fee
:
hre
.
ethers
.
parse
Ether
(
tokenPair
.
fee
),
limit
:
hre
.
ethers
.
parse
Ether
(
tokenPair
.
limit
),
fee
:
hre
.
ethers
.
parse
Units
(
tokenPair
.
fee
,
decimals
),
limit
:
hre
.
ethers
.
parse
Units
(
tokenPair
.
limit
,
decimals
),
isBurn
:
tokenPair
.
isBurn
,
enabled
:
true
,
};
console
.
log
(
"
set out config for token
"
,
tokenPair
.
token
,
"
-
"
,
outConfig
);
var
tx
=
await
bridge
.
changeOutConfig
(
tokenPair
.
token
,
...
...
@@ -61,6 +65,7 @@ async function main() {
for
(
var
i
=
0
;
i
<
tokenPairs
.
length
;
i
++
)
{
await
setOutConfig
(
curChainDeploy
.
bridge
,
tokenPairs
[
i
]);
}
console
.
log
(
"
all token pairs processed.
"
);
}
// Run the script
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment