Skip to content

Commit

Permalink
Rename utils file to helpers (#19)
Browse files Browse the repository at this point in the history
  • Loading branch information
Hrom131 authored Dec 18, 2024
1 parent e0a1774 commit ba61018
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 11 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## [v0.4.3]

* Renamed `utils` file to `helpers` because of a path bug on Windows.

## [v0.4.2]

* Fixed redundant protocol type generation in the `hardhat.config.ts`.
Expand Down
12 changes: 6 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@solarity/zktype",
"version": "0.4.2",
"version": "0.4.3",
"description": "Unleash TypeScript bindings for Circom circuits",
"main": "dist/index.js",
"types": "dist/index.d.ts",
Expand Down Expand Up @@ -45,7 +45,7 @@
"homepage": "https://github.com/dl-solarity/zktype#readme",
"dependencies": {
"ejs": "3.1.10",
"prettier": "3.3.3",
"prettier": "3.4.2",
"typescript": "5.5.4"
},
"peerDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions src/core/CircuitTypesGenerator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,10 +118,10 @@ export class CircuitTypesGenerator extends ZkitTSGenerator {
await this._saveMainIndexFile(circuitSet);
await this._saveHardhatZkitTypeExtensionFile(circuitSet);

// copy utils to types output dir
// copy helpers to types output dir
const utilsDirPath = this.getOutputTypesDir();
fs.mkdirSync(utilsDirPath, { recursive: true });
fs.copyFileSync(path.join(__dirname, "templates", "utils.ts"), path.join(utilsDirPath, "utils.ts"));
fs.copyFileSync(path.join(__dirname, "templates", "helpers.ts"), path.join(utilsDirPath, "helpers.ts"));
}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/core/ZkitTSGenerator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ export default class ZkitTSGenerator extends BaseTSGenerator {
calldataPubSignalsCount += this._getPublicSignalsCount(signal);
}

const pathToUtils = path.join(this.getOutputTypesDir(), "utils");
const pathToUtils = path.join(this.getOutputTypesDir(), "helpers");
const circuitClassName = this._getCircuitName(circuitArtifact) + (isPrefixed ? this._getPrefix(protocolType) : "");

const templateParams: WrapperTemplateParams = {
Expand Down
File renamed without changes.

0 comments on commit ba61018

Please sign in to comment.