( file: string, replacer: (content: string) => string, )
| 87 | ) as DenoJson; |
| 88 | |
| 89 | async function replaceInFile( |
| 90 | file: string, |
| 91 | replacer: (content: string) => string, |
| 92 | ) { |
| 93 | const raw = await Deno.readTextFile(file); |
| 94 | const replaced = replacer(raw); |
| 95 | await Deno.writeTextFile(file, replaced); |
| 96 | } |
| 97 | |
| 98 | const nextVersion = semver.format(next); |
| 99 |