Skip to content

Commit e68c7c6

Browse files
committed
Added add script
1 parent d84ada6 commit e68c7c6

File tree

4 files changed

+9
-13
lines changed

4 files changed

+9
-13
lines changed

.husky/.gitignore

Lines changed: 0 additions & 1 deletion
This file was deleted.

.husky/pre-commit

Lines changed: 0 additions & 4 deletions
This file was deleted.

dist/index.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16701,11 +16701,11 @@ async function main() {
1670116701
]
1670216702
},
1670316703
{
16704-
token: process.env.NOTION_TOKEN_V2
16704+
token: secrets.NOTION_TOKEN_V2
1670516705
}
1670616706
);
1670716707

16708-
core.info('Successfully fetched database');
16708+
core.info('Fetched database');
1670916709

1671016710
// If a database with the passed id doesn't exist
1671116711
if (!collectionViewData.recordMap.block[databaseId].value) {
@@ -16727,11 +16727,11 @@ async function main() {
1672716727
]
1672816728
},
1672916729
{
16730-
token: process.env.NOTION_TOKEN_V2
16730+
token: secrets.NOTION_TOKEN_V2
1673116731
}
1673216732
);
1673316733

16734-
core.info('Successfully fetched collection');
16734+
core.info('Fetched collection');
1673516735

1673616736
const { recordMap } = await NotionEndpoints.Queries.queryCollection(
1673716737
{
@@ -16746,11 +16746,11 @@ async function main() {
1674616746
}
1674716747
},
1674816748
{
16749-
token: process.env.NOTION_TOKEN_V2
16749+
token: secrets.NOTION_TOKEN_V2
1675016750
}
1675116751
);
1675216752

16753-
core.info('Successfully fetched rows');
16753+
core.info('Fetched rows');
1675416754

1675516755
const collection = collectionData.recordMap.collection[collection_id].value;
1675616756
const { schema } = collection;

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@
66
"scripts": {
77
"build": "npx ncc build ./src/index.js -o dist",
88
"prepare": "husky install",
9-
"format": "npx prettier --write src/*.js"
9+
"format": "npx prettier --write src/*.js",
10+
"add": "npm run format && npm run build && git add ."
1011
},
1112
"repository": {
1213
"type": "git",
@@ -27,4 +28,4 @@
2728
"@zeit/ncc": "^0.22.3",
2829
"prettier": "^2.2.1"
2930
}
30-
}
31+
}

0 commit comments

Comments
 (0)