Skip to content

Commit

Permalink
chore: Remove pact-web
Browse files Browse the repository at this point in the history
  • Loading branch information
TimothyJones committed Mar 12, 2021
1 parent f3f2f10 commit a1a78ae
Show file tree
Hide file tree
Showing 10 changed files with 6 additions and 137 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ coverage
# Compiled binary addons (http://nodejs.org/api/addons.html)
build/Release
dist
dist-web

# Dependency directory
node_modules
Expand Down
55 changes: 0 additions & 55 deletions config/webpack.web.config.js

This file was deleted.

1 change: 0 additions & 1 deletion examples/karma/jasmine/karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ module.exports = function (config) {
// list of files / patterns to load in the browser
files: [
// Local development
// '../../dist-web/pact-web.js',
"../node_modules/@pact-foundation/pact-web/pact-web.js",
"client.js",
"client-spec.js",
Expand Down
2 changes: 0 additions & 2 deletions examples/karma/mocha/karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ module.exports = function (config) {

// list of files / patterns to load in the browser
files: [
// During development
// '../../dist-web/pact-web.js',
// Example Using NPM package
"../node_modules/@pact-foundation/pact-web/pact-web.js",
"client.js",
Expand Down
2 changes: 1 addition & 1 deletion examples/nestjs-provider/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
"rootDir": ".",
"testRegex": ".*\\.spec\\.ts$",
"transform": {
"^.+\\.(t|j)s$": "ts-jest"
"^.+\\.ts$": "ts-jest"
},
"collectCoverageFrom": [
"**/*.(t|j)s"
Expand Down
14 changes: 3 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@
"build:v2": "npm run dist",
"build:v3": "neon build --release",
"compile": "rimraf dist && tsc",
"clean": "rimraf docs dist dist-web coverage .nyc_output logs pacts",
"clean": "rimraf docs dist coverage .nyc_output logs pacts",
"clean:native": "rimraf native/target",
"coverage": "nyc report --reporter=lcov",
"dist": "tsc && webpack --config ./config/webpack.web.config.js && copyfiles package.json ./dist",
"dist": "tsc && copyfiles package.json ./dist",
"lint": "eslint --config .eslintrc.json '{src,test}/**/*.ts'",
"lint:fix": "npm run lint -- --fix",
"format:base": "prettier \"{src,test,examples}/**/*.{ts,js}\"",
Expand Down Expand Up @@ -153,9 +153,7 @@
"@types/underscore": "^1.8.5",
"@typescript-eslint/eslint-plugin": "^4.9.1",
"@typescript-eslint/parser": "^4.9.1",
"awesome-typescript-loader": "^5.2.0",
"babel-eslint": "~10.0.3",
"babel-loader": "^8.0.6",
"chai": "~4.1.2",
"chai-as-promised": "^7.1.1",
"copyfiles": "^2.4.1",
Expand All @@ -166,11 +164,8 @@
"eslint-import-resolver-typescript": "^2.3.0",
"eslint-plugin-import": "^2.22.1",
"eslint-plugin-prettier": "^3.2.0",
"imports-loader": "~0.7.1",
"istanbul": "~0.4.5",
"jasmine-core": "~2.9.1",
"json-loader": "~0.5.7",
"loader-utils": "^1.1.0",
"lodash.clone": "^4.5.0",
"mocha": "^7.2.0",
"mocha-lcov-reporter": "^1.3.0",
Expand All @@ -184,15 +179,12 @@
"sha256-file": "^1.0.0",
"sinon": "^7.2.4",
"sinon-chai": "^3.3.0",
"source-map-loader": "^0.2.1",
"source-map-support": "^0.4.18",
"standard-version": "^9.1.0",
"superagent": "^3.8.2",
"ts-mock-imports": "^1.2.6",
"ts-node": "^3.3.0",
"typescript": "^3.8.3",
"webpack": "^4.45.0",
"webpack-cli": "^4.3.1"
"typescript": "^3.8.3"
},
"binary": {
"module_name": "index",
Expand Down
41 changes: 0 additions & 41 deletions package.json.web

This file was deleted.

17 changes: 1 addition & 16 deletions scripts/ci/lib/prepare-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,29 +6,14 @@ require_binary grep
require_binary sed
require_binary find

mkdir -p dist-web
VERSION="$("$SCRIPT_DIR/get-version.sh")"

echo "--> Preparing release version ${VERSION}"

echo "--> Copy key artifacts into pact and pact-web distributions"
echo "--> Copy key artifacts into pact distribution"
artifacts=(LICENSE *md package.json)

for artifact in "${artifacts[@]}"; do
echo " Copying ${artifact} => ./dist/${artifact}"
cp "${artifact}" "./dist/${artifact}"
echo " Copying ${artifact} => ./dist-web/${artifact}"
cp "${artifact}" "./dist-web/${artifact}"
done

echo "--> Creating pact-web package"
sed "s/VERSION/${VERSION}/g" < package.json.web > dist-web/package.json

# Copy TS types across
types=( $(find dist -name "*.d.ts" | grep -v node_modules | sed 's/dist\///') )
for type in "${types[@]}"; do
echo " Copying ${type} => ./dist-web/${type}"
echo "creating dir: $(dirname "./dist-web/${type}")"
mkdir -p "$(dirname "./dist-web/${type}")"
cp -r "dist/${type}" "./dist-web/${type}"
done
6 changes: 1 addition & 5 deletions scripts/ci/lib/publish-beta.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,4 @@ echo "--> Releasing version ${VERSION}"
echo "--> Releasing artifacts"
echo " Publishing pact@${VERSION}..."
npm publish dist --access public --tag beta
echo " done!"

echo " Publishing pact-web@${VERSION}..."
npm publish dist-web --access public --tag beta
echo " done!"
echo " done!"
4 changes: 0 additions & 4 deletions scripts/ci/lib/publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,3 @@ echo "--> Releasing artifacts"
echo " Publishing pact@${VERSION}..."
npm publish dist --access public --tag latest
echo " done!"

echo " Publishing pact-web@${VERSION}..."
npm publish dist-web --access public --tag latest
echo " done!"

0 comments on commit a1a78ae

Please sign in to comment.