Rename package

This commit is contained in:
Sparticuz 2022-09-26 15:10:35 -04:00
parent d44fbde653
commit 3257813560
2 changed files with 14 additions and 12 deletions

View File

@ -1,10 +1,11 @@
.PHONY: clean .PHONY: clean
clean: clean:
rm -rf chrome_aws_lambda.zip _/amazon/code/nodejs rm -rf chromium.zip _/amazon/code/nodejs
pretest: pretest:
unzip chrome_aws_lambda.zip -d _/amazon/code unzip chromium.zip -d _/amazon/code
npm install --prefix _/amazon/handlers puppeteer-core --bin-links=false --fund=false --omit=optional --omit=dev --package-lock=false --save=false
test: test:
sam local invoke --template _/amazon/template.yml --event _/amazon/events/example.com.json node16 sam local invoke --template _/amazon/template.yml --event _/amazon/events/example.com.json node16
@ -17,11 +18,11 @@ test:
mkdir -p nodejs mkdir -p nodejs
npm install --prefix nodejs/ tar-fs@2.1.1 --bin-links=false --fund=false --omit=optional --omit=dev --package-lock=false --save=false npm install --prefix nodejs/ tar-fs@2.1.1 --bin-links=false --fund=false --omit=optional --omit=dev --package-lock=false --save=false
npm pack npm pack
mkdir -p nodejs/node_modules/@sparticuz/chrome-aws-lambda/ mkdir -p nodejs/node_modules/@sparticuz/chromium/
tar --directory nodejs/node_modules/@sparticuz/chrome-aws-lambda/ --extract --file sparticuz-chrome-aws-lambda-*.tgz --strip-components=1 tar --directory nodejs/node_modules/@sparticuz/chromium/ --extract --file sparticuz-chromium-*.tgz --strip-components=1
npx clean-modules --directory nodejs --include "**/*.d.ts" "**/@types/**" "**/*.@(yaml|yml)" --yes npx clean-modules --directory nodejs --include "**/*.d.ts" "**/@types/**" "**/*.@(yaml|yml)" --yes
rm sparticuz-chrome-aws-lambda-*.tgz rm sparticuz-chromium-*.tgz
mkdir -p $(dir $@) mkdir -p $(dir $@)
zip -9 --filesync --move --recurse-paths $@ nodejs zip -9 --filesync --move --recurse-paths $@ nodejs
.DEFAULT_GOAL := chrome_aws_lambda.zip .DEFAULT_GOAL := chromium.zip

View File

@ -1,11 +1,11 @@
{ {
"name": "@sparticuz/chrome-aws-lambda", "name": "@sparticuz/chromium",
"version": "17.1.3", "version": "1.0.0",
"author": { "author": {
"name": "Kyle McNally" "name": "Kyle McNally"
}, },
"license": "MIT", "license": "MIT",
"description": "Chromium Binary for AWS Lambda and Google Cloud Functions, forked from @alixaxel/chrome-aws-lambda", "description": "Chromium Binary for Serverless Platforms",
"main": "build/index.js", "main": "build/index.js",
"types": "build/index.d.ts", "types": "build/index.d.ts",
"files": [ "files": [
@ -29,12 +29,12 @@
"typescript": "^4.6.4" "typescript": "^4.6.4"
}, },
"bugs": { "bugs": {
"url": "https://github.com/Sparticuz/chrome-aws-lambda/issues" "url": "https://github.com/Sparticuz/chromium/issues"
}, },
"homepage": "https://github.com/Sparticuz/chrome-aws-lambda", "homepage": "https://github.com/Sparticuz/chromium",
"repository": { "repository": {
"type": "git", "type": "git",
"url": "git://github.com/Sparticuz/chrome-aws-lambda.git" "url": "git://github.com/Sparticuz/chromium.git"
}, },
"keywords": [ "keywords": [
"aws", "aws",
@ -43,6 +43,7 @@
"chromium", "chromium",
"lambda", "lambda",
"puppeteer", "puppeteer",
"playwright",
"serverless" "serverless"
], ],
"prettier": { "prettier": {