|
|
@ -5,9 +5,11 @@ import {PluginClient} from '@remixproject/plugin' |
|
|
|
import {Contract, compileContract} from './compiler' |
|
|
|
import {Contract, compileContract} from './compiler' |
|
|
|
import {ExampleContract} from '../components/VyperResult' |
|
|
|
import {ExampleContract} from '../components/VyperResult' |
|
|
|
import EventEmitter from 'events' |
|
|
|
import EventEmitter from 'events' |
|
|
|
|
|
|
|
import { Plugin } from "@remixproject/engine"; |
|
|
|
|
|
|
|
import { CustomRemixApi } from '@remix-api' |
|
|
|
|
|
|
|
|
|
|
|
export type VyperComplierAddress = 'https://vyper2.remixproject.org/' | 'http://localhost:8000/' |
|
|
|
export type VyperComplierAddress = 'https://vyper2.remixproject.org/' | 'http://localhost:8000/' |
|
|
|
export class RemixClient extends PluginClient { |
|
|
|
export class RemixClient extends PluginClient<any, CustomRemixApi> { |
|
|
|
private client = createClient<Api, Readonly<RemixApi>>(this) |
|
|
|
private client = createClient<Api, Readonly<RemixApi>>(this) |
|
|
|
compilerUrl: VyperComplierAddress = 'https://vyper2.remixproject.org/' |
|
|
|
compilerUrl: VyperComplierAddress = 'https://vyper2.remixproject.org/' |
|
|
|
compilerOutput: any |
|
|
|
compilerOutput: any |
|
|
@ -81,17 +83,14 @@ export class RemixClient extends PluginClient { |
|
|
|
try { |
|
|
|
try { |
|
|
|
// @ts-ignore
|
|
|
|
// @ts-ignore
|
|
|
|
this.call('notification', 'toast', 'cloning Snekmate Vyper repository...') |
|
|
|
this.call('notification', 'toast', 'cloning Snekmate Vyper repository...') |
|
|
|
|
|
|
|
|
|
|
|
await this.call('manager', 'activatePlugin', 'dgitApi') |
|
|
|
|
|
|
|
/* |
|
|
|
|
|
|
|
await this.call( |
|
|
|
await this.call( |
|
|
|
'dgitApi', |
|
|
|
'dgitApi', |
|
|
|
'clone', |
|
|
|
'clone', |
|
|
|
{url: 'https://github.com/pcaversaccio/snekmate', token: null, branch: 'v0.0.5'}, |
|
|
|
{url: 'https://github.com/pcaversaccio/snekmate', token: null, branch: 'v0.0.5', workspaceName: 'snekmate'}, |
|
|
|
// @ts-ignore
|
|
|
|
|
|
|
|
'snekmate' |
|
|
|
|
|
|
|
) |
|
|
|
) |
|
|
|
*/ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.call( |
|
|
|
this.call( |
|
|
|
// @ts-ignore
|
|
|
|
// @ts-ignore
|
|
|
|
'notification', |
|
|
|
'notification', |
|
|
|