Skip to content

Commit

Permalink
refactor: update platform name and arch to display
Browse files Browse the repository at this point in the history
  • Loading branch information
azat-io committed Nov 4, 2024
1 parent 5e3762a commit 3a2be2a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions scripts/create-packages.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,15 @@ for (let platform of platforms) {
})

let name = `@todoctor/${platform.name}-${arch}`
let displayName = platform.name[0].toUpperCase() + platform.name.slice(1)
let displayArch = arch.toUpperCase()

fs.writeFile(
path.join(packageDir, 'package.json'),
JSON.stringify(
{
name,
description: `Platform-specific binary for Todoctor (${platform.name}, ${arch})`,
description: `Platform-specific binary for Todoctor (${displayName}, ${displayArch})`,
version: rootPackageJson.version,
repository: rootPackageJson.repository,
author: rootPackageJson.author,
Expand All @@ -41,7 +43,7 @@ for (let platform of platforms) {
fs.writeFile(
path.join(packageDir, 'readme.md'),
[
`# Todoctor (${platform.name[0].toUpperCase() + platform.name.slice(1)}, ${arch.toUpperCase()})`,
`# Todoctor (${displayName}, ${displayArch})`,
'',
'<img',
' src="https://raw.githubusercontent.com/azat-io/todoctor/main/assets/logo-light.webp"',
Expand Down

0 comments on commit 3a2be2a

Please sign in to comment.