Skip to content

Commit ae887d1

Browse files
authored
Merge pull request #4 from MatiasOS/remove-network-name-restriction
Remove network name restriction
2 parents 602ba56 + 95f57a4 commit ae887d1

4 files changed

Lines changed: 12 additions & 4 deletions

File tree

.github/workflows/npm-publish.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,14 @@ jobs:
1111
steps:
1212
- uses: actions/checkout@v6
1313
- uses: pnpm/action-setup@v4
14+
with:
15+
version: 10
1416
- uses: actions/setup-node@v6
1517
with:
1618
node-version: "24"
1719
registry-url: "https://registry.npmjs.org"
1820
cache: "pnpm"
1921
- run: pnpm install --frozen-lockfile
2022
- run: pnpm run build
21-
- run: pnpm publish --provenance
23+
- run: pnpm --filter @openscan/hardhat-plugin publish --provenance
2224

packages/example-project/hardhat.config.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,13 @@ export default defineConfig({
66
plugins: [hardhatIgnitionViemPlugin, openScanPlugin],
77
solidity: "0.8.29",
88
networks: {
9+
hardhatBlocks: {
10+
type: "edr-simulated",
11+
mining: {
12+
auto: false,
13+
interval: 5000,
14+
}
15+
},
916
localhost: {
1017
type: "http",
1118
url: "http://127.0.0.1:8545",

packages/plugin/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@openscan/hardhat-plugin",
3-
"version": "1.0.0",
3+
"version": "1.0.1",
44
"description": "Hardhat 3 plugin to use openscan explorer",
55
"license": "MIT",
66
"type": "module",

packages/plugin/src/hooks/network.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,7 @@ export default async (): Promise<Partial<NetworkHooks>> => {
6060
const connection = await next(context);
6161

6262
// Start webapp on first connection (when Hardhat node starts)
63-
// The network name is "default" for the built-in Hardhat network
64-
if (!webappStarted && connection.networkName === "default") {
63+
if (!webappStarted) {
6564
webappStarted = true;
6665
await startWebapp();
6766
}

0 commit comments

Comments
 (0)