Skip to content

Conversation

dariushar
Copy link
Contributor

@dariushar dariushar commented Jun 9, 2023

Using correct readme links in Akamai SDKs
Updated doc script to include package description and package version

Note

  • I couldn't get the package.json variable ${npm_package_version} to work correctly so I just added the description manually

@dariushar dariushar changed the title Fix readme links for Akamai projects, add package name and version to… fix: Update readme links Jun 9, 2023
@dariushar dariushar changed the title fix: Update readme links fix: Update readme links for Akamai SDKs Jun 9, 2023
@dariushar dariushar marked this pull request as ready for review June 9, 2023 21:10
@dariushar dariushar requested a review from ctawiah June 9, 2023 21:10
],
"scripts": {
"doc": "npx typedoc --entryPointStrategy resolve src/index.ts",
"doc": "npx typedoc --name \"Akamai LaunchDarkly EdgeWorker SDK ${npm_package_version}\" --readme none --entryPointStrategy resolve src/index.ts",
Copy link
Contributor Author

@dariushar dariushar Jun 9, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if anyone has a better way to bring in the description here.

${npm_package_description} doesn't seem to be a supported feature anymore.

**Note: ** The version works correctly and uses the version from the package.json

Copy link
Contributor

@ctawiah ctawiah Jun 9, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think it should be '$npm_package_description' and then run npm run doc

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

doc-name.sh

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Which contains
node -p "let pj = require('./$1/package.json');\${pj.description} (${pj.version})`";`

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Basically uses node to load the package.json, then makes an interpolated string with the description and version.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"doc": "npx typedoc --name \"$(../../../scripts/doc-name.sh .)\" --readme none --entryPointStrategy resolve src/index.ts"

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Produced:
image

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! I tried that command and I still got the same error but I trust you when you say that it ran haha. Updating the code now

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm on linux, so maybe a mac thing?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Possibly. I've been seeing this error for a while now and I think it might be specific to silicon based macs.

@dariushar dariushar merged commit 8a138c1 into main Jun 12, 2023
@dariushar dariushar deleted the dariusharrison/fix-readme-link branch June 12, 2023 14:12
@github-actions github-actions bot mentioned this pull request Jun 12, 2023
dariushar added a commit that referenced this pull request Jun 13, 2023
🤖 I have created a release *beep* *boop*
---


<details><summary>akamai-server-base-sdk: 0.3.1</summary>

##
[0.3.1](akamai-server-base-sdk-v0.3.0...akamai-server-base-sdk-v0.3.1)
(2023-06-12)


### Bug Fixes

* Update readme links for Akamai SDKs
([#157](#157))
([8a138c1](8a138c1))
</details>

<details><summary>akamai-server-edgekv-sdk: 0.3.1</summary>

##
[0.3.1](akamai-server-edgekv-sdk-v0.3.0...akamai-server-edgekv-sdk-v0.3.1)
(2023-06-12)


### Bug Fixes

* Update readme links for Akamai SDKs
([#157](#157))
([8a138c1](8a138c1))
</details>

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants