Skip to content

Commit eb664b0

Browse files
author
ci-bot
committed
log and fix ui
1 parent 373016a commit eb664b0

File tree

4 files changed

+8
-3
lines changed

4 files changed

+8
-3
lines changed

apps/remixdesktop/src/plugins/foundryPlugin.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,9 @@ class FoundryPluginClient extends ElectronBasePluginRemixdClient {
7878
}
7979

8080
compile() {
81-
return new Promise((resolve, reject) => {
81+
return new Promise((resolve, reject) => {
8282
const cmd = `forge build`
83+
this.call('terminal', 'log', { type: 'log', value: `running ${cmd}` })
8384
const options = { cwd: this.currentSharedFolder, shell: true }
8485
const child = spawn(cmd, options)
8586
let error = ''
@@ -119,7 +120,6 @@ class FoundryPluginClient extends ElectronBasePluginRemixdClient {
119120
compilationTarget: null
120121
}
121122
compilationResult.inputSources.target = file
122-
console.log('Foundry compilation detected, emitting contract', file, path)
123123
if (!fs.existsSync(path)) return
124124
await this.readContract(path, compilationResult, cache)
125125
this.emit('compilationFinished', compilationResult.compilationTarget, { sources: compilationResult.input }, 'soljson', compilationResult.output, compilationResult.solcVersion)

apps/remixdesktop/src/plugins/hardhatPlugin.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ class HardhatPluginClient extends ElectronBasePluginRemixdClient {
7575
compile() {
7676
return new Promise((resolve, reject) => {
7777
const cmd = `npx hardhat compile`
78+
this.call('terminal', 'log', { type: 'log', value: `running ${cmd}` })
7879
const options = { cwd: this.currentSharedFolder, shell: true }
7980
const child = spawn(cmd, options)
8081
let error = ''

libs/remix-ui/solidity-compiler/src/lib/compiler-container.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -456,6 +456,8 @@ export const CompilerContainer = (props: CompilerContainerProps) => {
456456
props.setCompileErrors({ [currentFile]: { error: error.message } })
457457
// @ts-ignore
458458
props.setBadgeStatus({ [currentFile]: { key: 1, title: error.message, type: 'error' } })
459+
}).then(() => {
460+
compileIcon.current.classList.remove('remixui_bouncingIcon')
459461
})
460462
}
461463

@@ -480,6 +482,8 @@ export const CompilerContainer = (props: CompilerContainerProps) => {
480482
props.setCompileErrors({ [currentFile]: { error: error.message } })
481483
// @ts-ignore
482484
props.setBadgeStatus({ [currentFile]: { key: 1, title: error.message, type: 'error' } })
485+
}).then(() => {
486+
compileIcon.current.classList.remove('remixui_bouncingIcon')
483487
})
484488
}
485489

libs/remix-ui/solidity-compiler/src/lib/logic/compileTabLogic.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ export class CompileTabLogic {
179179
} else return false
180180
}
181181

182-
runCompiler (externalCompType) {
182+
async runCompiler (externalCompType) {
183183
try {
184184
this.api.saveCurrentFile()
185185
if (this.api.getFileManagerMode() === 'localhost' || this.api.isDesktop()) {

0 commit comments

Comments
 (0)