Skip to content

Commit

Permalink
removes duplicated template
Browse files Browse the repository at this point in the history
  • Loading branch information
julia-script committed Feb 19, 2024
1 parent 03456b5 commit 2af3429
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 23 deletions.
23 changes: 1 addition & 22 deletions packages/dappstore-cli/src/init/get-template.ts
Original file line number Diff line number Diff line change
@@ -1,26 +1,5 @@
const TEMPLATE = `
import { createDAppStoreClient } from "@evmos/dappstore-sdk";
import { TEMPLATE } from "./templates/dappstore-client";

export const dappstore = createDAppStoreClient();
/**
* EIP-1193 provider
*/
export const provider = dappstore.provider;
`;
// const __dirname = path.dirname(fileURLToPath(import.meta.url));
export const readTemplate = () => {
// try {
// return await readFile(
// path.join(__dirname, `./templates/dappstore-client.ts`),
// "utf-8"
// );
// } catch (e) {
// console.error("Template not found");
// process.exit(1);
// }

// TODO: I was actually reading this file with a Bun macro but it's not working on github CI
// let's try again in the future
return TEMPLATE;
};
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import { createDAppStoreClient } from "@evmos/dappstore-sdk";
export const TEMPLATE = `import { createDAppStoreClient } from "@evmos/dappstore-sdk";
export const dappstore = createDAppStoreClient();
/**
* EIP-1193 provider
*/
export const provider = dappstore.provider;
`;

0 comments on commit 2af3429

Please sign in to comment.