@el-j/google-sheet-translations 1.0.1 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/utils/auth.d.ts.map +1 -1
- package/dist/utils/auth.js +5 -1
- package/dist/utils/auth.js.map +1 -1
- package/package.json +1 -1
package/dist/utils/auth.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../src/utils/auth.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,qBAAqB,CAAC;AAG1C;;;GAGG;AACH,wBAAgB,gBAAgB,IAAI,GAAG,
|
|
1
|
+
{"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../src/utils/auth.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,qBAAqB,CAAC;AAG1C;;;GAGG;AACH,wBAAgB,gBAAgB,IAAI,GAAG,CAatC;AAED,eAAe,gBAAgB,CAAC"}
|
package/dist/utils/auth.js
CHANGED
|
@@ -9,9 +9,13 @@ const validateEnv_1 = require("./validateEnv");
|
|
|
9
9
|
*/
|
|
10
10
|
function createAuthClient() {
|
|
11
11
|
const { GOOGLE_CLIENT_EMAIL, GOOGLE_PRIVATE_KEY } = (0, validateEnv_1.validateEnv)();
|
|
12
|
+
// GitHub Actions (and many CI systems) store secrets with literal `\n`
|
|
13
|
+
// instead of real newlines. The PEM key must have actual newlines for
|
|
14
|
+
// OpenSSL to parse it; replace any escaped sequences before use.
|
|
15
|
+
const normalizedKey = GOOGLE_PRIVATE_KEY.replace(/\\n/g, "\n");
|
|
12
16
|
return new google_auth_library_1.JWT({
|
|
13
17
|
email: GOOGLE_CLIENT_EMAIL,
|
|
14
|
-
key:
|
|
18
|
+
key: normalizedKey,
|
|
15
19
|
scopes: ["https://www.googleapis.com/auth/spreadsheets"],
|
|
16
20
|
});
|
|
17
21
|
}
|
package/dist/utils/auth.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth.js","sourceRoot":"","sources":["../../src/utils/auth.ts"],"names":[],"mappings":";;AAOA,
|
|
1
|
+
{"version":3,"file":"auth.js","sourceRoot":"","sources":["../../src/utils/auth.ts"],"names":[],"mappings":";;AAOA,4CAaC;AApBD,6DAA0C;AAC1C,+CAA4C;AAE5C;;;GAGG;AACH,SAAgB,gBAAgB;IAC/B,MAAM,EAAE,mBAAmB,EAAE,kBAAkB,EAAE,GAAG,IAAA,yBAAW,GAAE,CAAC;IAElE,uEAAuE;IACvE,sEAAsE;IACtE,iEAAiE;IACjE,MAAM,aAAa,GAAG,kBAAkB,CAAC,OAAO,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;IAE/D,OAAO,IAAI,yBAAG,CAAC;QACd,KAAK,EAAE,mBAAmB;QAC1B,GAAG,EAAE,aAAa;QAClB,MAAM,EAAE,CAAC,8CAA8C,CAAC;KACxD,CAAC,CAAC;AACJ,CAAC;AAED,kBAAe,gBAAgB,CAAC"}
|