-
Notifications
You must be signed in to change notification settings - Fork 58
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #158 from ensdomains/feat/new-dnssec-oracle-updated
feat: new dnssec oracle updated
- Loading branch information
Showing
18 changed files
with
280 additions
and
368 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import { execSync } from 'child_process' | ||
import fs from 'fs-extra' | ||
import path from 'path' | ||
import * as url from 'url' | ||
|
||
// get branch name from local git command | ||
const branchName = execSync('git rev-parse --abbrev-ref HEAD') | ||
.toString('utf-8') | ||
.replace(/\//g, '-') | ||
.trim() | ||
|
||
// timestamp | ||
const timestamp = new Date().toISOString().replace(/[-:.]/g, '').slice(0, -1) | ||
|
||
const newVersion = `0.0.0-${branchName}.${timestamp}` | ||
|
||
// // change version in package.json | ||
execSync(`pnpm version --no-workspaces-update ${newVersion}`, { | ||
stdio: 'inherit', | ||
}) | ||
|
||
const __dirname = url.fileURLToPath(new URL('.', import.meta.url)) | ||
|
||
// // Writes the new version to `./src/errors/version.ts`. | ||
const versionFilePath = path.join(__dirname, '../src/errors/version.ts') | ||
|
||
fs.writeFileSync(versionFilePath, `export const version = '${newVersion}'\n`) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.