Skip to content

Commit 591aa2e

Browse files
authored
Merge pull request #11 from rust-lang/remove-todo-item
hardcode package version
2 parents 93d3ac1 + d77e6ce commit 591aa2e

File tree

3 files changed

+6
-11
lines changed

3 files changed

+6
-11
lines changed

dist/main.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27314,9 +27314,8 @@ function getTokensEndpoint(registryUrl) {
2731427314
return `${registryUrl}/api/v1/trusted_publishing/tokens`;
2731527315
}
2731627316
function userAgentValue() {
27317-
const version = "v1";
27318-
// TODO: read the package name and version from package.json
27319-
return `crates-io-auth-action/${version}`;
27317+
const packageVersion = "1.0.0";
27318+
return `crates-io-auth-action/${packageVersion}`;
2732027319
}
2732127320
function getUserAgent() {
2732227321
const userAgent = userAgentValue();

dist/post.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27297,9 +27297,8 @@ function getTokensEndpoint(registryUrl) {
2729727297
return `${registryUrl}/api/v1/trusted_publishing/tokens`;
2729827298
}
2729927299
function userAgentValue() {
27300-
const version = "v1";
27301-
// TODO: read the package name and version from package.json
27302-
return `crates-io-auth-action/${version}`;
27300+
const packageVersion = "1.0.0";
27301+
return `crates-io-auth-action/${packageVersion}`;
2730327302
}
2730427303
function getUserAgent() {
2730527304
const userAgent = userAgentValue();

src/utils.ts

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -77,11 +77,8 @@ export function getTokensEndpoint(registryUrl: string): string {
7777
}
7878

7979
function userAgentValue(): string {
80-
const version = "v1";
81-
82-
// TODO: read the package name and version from package.json
83-
84-
return `crates-io-auth-action/${version}`;
80+
const packageVersion = "1.0.0";
81+
return `crates-io-auth-action/${packageVersion}`;
8582
}
8683

8784
export function getUserAgent(): UserAgent {

0 commit comments

Comments
 (0)