Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
nebula
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
exchain
nebula
Commits
d0747b7c
Commit
d0747b7c
authored
Dec 30, 2021
by
Indeavr
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(lint)
parent
cf0d19ac
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
4 deletions
+8
-4
generate-artifacts.ts
packages/contracts/scripts/generate-artifacts.ts
+4
-2
generate-deployed-artifacts.ts
packages/contracts/scripts/generate-deployed-artifacts.ts
+4
-2
No files found.
packages/contracts/scripts/generate-artifacts.ts
View file @
d0747b7c
...
@@ -31,8 +31,10 @@ const main = async () => {
...
@@ -31,8 +31,10 @@ const main = async () => {
// eslint-disable-next-line @typescript-eslint/no-var-requires
// eslint-disable-next-line @typescript-eslint/no-var-requires
const
artifact
=
require
(
artifactPath
)
const
artifact
=
require
(
artifactPath
)
// handles the case - '\u' (\utils folder) is considered as an unicode encoded char
// handles the case - '\u' (\utils folder) is considered as an unicode encoded char
const
pattern
=
/
\\
/g
;
const
pattern
=
/
\\
/g
const
relPath
=
path
.
relative
(
__dirname
,
artifactPath
).
replace
(
pattern
,
"
/
"
)
const
relPath
=
path
.
relative
(
__dirname
,
artifactPath
)
.
replace
(
pattern
,
'
/
'
)
return
`
return
`
let
${
artifact
.
contractName
}
let
${
artifact
.
contractName
}
try {
try {
...
...
packages/contracts/scripts/generate-deployed-artifacts.ts
View file @
d0747b7c
...
@@ -27,7 +27,7 @@ const main = async () => {
...
@@ -27,7 +27,7 @@ const main = async () => {
})
})
const
artifactNames
=
[]
const
artifactNames
=
[]
const
pattern
=
/
\\
/g
;
const
pattern
=
/
\\
/g
for
(
const
deploymentName
of
deploymentNames
)
{
for
(
const
deploymentName
of
deploymentNames
)
{
const
deploymentArtifacts
=
glob
.
sync
(
const
deploymentArtifacts
=
glob
.
sync
(
...
@@ -39,7 +39,9 @@ const main = async () => {
...
@@ -39,7 +39,9 @@ const main = async () => {
)
)
for
(
const
artifactPath
of
deploymentArtifacts
)
{
for
(
const
artifactPath
of
deploymentArtifacts
)
{
const
relPath
=
path
.
relative
(
__dirname
,
artifactPath
).
replace
(
pattern
,
"
/
"
)
const
relPath
=
path
.
relative
(
__dirname
,
artifactPath
)
.
replace
(
pattern
,
'
/
'
)
const
contractName
=
path
.
basename
(
artifactPath
,
'
.json
'
)
const
contractName
=
path
.
basename
(
artifactPath
,
'
.json
'
)
const
artifactName
=
`
${
deploymentName
}
__
${
contractName
}
`
.
replace
(
const
artifactName
=
`
${
deploymentName
}
__
${
contractName
}
`
.
replace
(
/-/g
,
/-/g
,
...
...
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