-
Notifications
You must be signed in to change notification settings - Fork 4
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 #14 from Code-Hex/fix/issues
fixed some issues for cookie
- Loading branch information
Showing
6 changed files
with
27 additions
and
3 deletions.
There are no files selected for viewing
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,7 @@ | ||
{ | ||
"deno.codeLens.references": true, | ||
"deno.enablePaths": [ | ||
"./scripts" | ||
], | ||
"deno.enable": true | ||
} |
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,16 @@ | ||
const decoder = new TextDecoder('utf-8'); | ||
const encoder = new TextEncoder(); | ||
|
||
async function updateVersion() { | ||
const packageJsonText = decoder.decode(await Deno.readFile('./package.json')); | ||
const packageJson = JSON.parse(packageJsonText); | ||
const version = packageJson.version; | ||
|
||
const versionTsContent = `export const version = '${version}';\n`; | ||
await Deno.writeFile('src/version.ts', encoder.encode(versionTsContent)); | ||
} | ||
|
||
updateVersion().catch(error => { | ||
console.error('failed to update version.ts:', error); | ||
Deno.exit(1); | ||
}); |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export const version = '1.2.0'; |