Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

130 1 package update #136

Merged
merged 70 commits into from
Jun 20, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
70 commits
Select commit Hold shift + click to select a range
3234d23
update tslib dependency in packages/*/package.json
brianmhunt Apr 24, 2021
c0dd8e6
add Makefile to .editorconfig
brianmhunt Apr 24, 2021
5e4aea3
update packages and lerna config
brianmhunt Apr 24, 2021
48e6f19
update base tsconfig target to ES6
brianmhunt Apr 24, 2021
c163abb
add several Makefile targets and tools/build.mk with sample esbuild c…
brianmhunt Apr 24, 2021
1a4e8cf
rough-out makefiles with peer dependency compilation
brianmhunt Apr 24, 2021
cf7cf17
change peer dependencies to newlines that seem to work better with Ma…
brianmhunt Apr 24, 2021
8482a4e
Update make targets for proper Makefile cross-package dependencies
brianmhunt Apr 25, 2021
4eacc1c
add the commonjs/esm targets
brianmhunt Apr 26, 2021
a58c7cc
add tools for the package template
brianmhunt Apr 28, 2021
d365509
remove references to config.yaml
brianmhunt Apr 28, 2021
226ea23
update Makefile for repackaging; pull package version from lerna.json…
brianmhunt Apr 28, 2021
b1f0cfc
repackage all package.json files
brianmhunt Apr 28, 2021
e9acdc0
remove `standard` from `repackage`
brianmhunt Apr 28, 2021
a058c17
improve logging and peer dependency checking
brianmhunt Apr 28, 2021
8084925
Remove numerous references to rollup
brianmhunt Apr 29, 2021
e833d23
make) update the Makefile `test` targets
brianmhunt Apr 29, 2021
5ef35fd
update repackage to export "." and "./helpers"
brianmhunt Apr 29, 2021
fffde54
repackage with dist/index.js as esm import, dist/index.cjs commonjs
brianmhunt Apr 30, 2021
20d0fdf
Fix build/peer dependencies building
brianmhunt Apr 30, 2021
df1b282
Fix karma testing config for esbuild
brianmhunt Apr 30, 2021
1306599
Fix top-level Makefile packaging
brianmhunt Apr 30, 2021
6ed2878
Fix utils.jsx imports / dependencies
brianmhunt Apr 30, 2021
6ed1bde
make) add esm dependency to testing; add watch target
brianmhunt May 1, 2021
ba417f7
change spec imports from ../src to ../dist
brianmhunt May 1, 2021
0bddb03
consolidate the karma config to tools/karma.conf.js
brianmhunt May 1, 2021
6b20562
fix builder missing karma/frameworks
brianmhunt May 2, 2021
6404e84
tools) fix broken ../{pkg}/dist/*.js
brianmhunt May 2, 2021
39b90b9
Move packages/build.knockout to builds/knockout
brianmhunt May 2, 2021
1291eb0
Move packages/build.reference to builds/reference
brianmhunt May 2, 2021
9a5f68a
Fix tests hanging b/c packages/builder had none
brianmhunt May 3, 2021
b79f91f
set global export for ko; update knockout builds
brianmhunt May 4, 2021
af76443
Add a stub for commonjs=>iife exports
brianmhunt May 4, 2021
a2744a1
Add BUILD_VERSION to the exports
brianmhunt May 4, 2021
7241d11
tools) Update & simplify our repackaging with lerna
brianmhunt May 24, 2021
9d6851d
add builds/* to the workspaces/clean target
brianmhunt May 24, 2021
7a54303
fix iife/browser build & BUILD_VERSION
brianmhunt May 25, 2021
e1b9e64
more fixes of BUILD_VERSION
brianmhunt May 25, 2021
7518bdc
build/reference) add tests of iife/root imports
brianmhunt May 25, 2021
b3346a7
root) add workspaces builds/; add lerna stream comments
brianmhunt May 25, 2021
af0e220
fix ReferenceError with globals
brianmhunt May 25, 2021
72f27b0
make/tools) remove peer_dependenicies in lieu of lerna build
brianmhunt May 26, 2021
451d1b8
ci) switch to the circleci orb for saucelabs
brianmhunt May 26, 2021
cd2c37b
Updated config.yml
brianmhunt May 26, 2021
8216b95
ci) add job
brianmhunt May 26, 2021
d9f0a47
Merge branch '130-1-package-update' of github.com:knockout/tko into 1…
brianmhunt May 26, 2021
938b78a
ci) add `make ci` target and Github workflow
brianmhunt May 27, 2021
f04a642
ci) fix make target
brianmhunt May 27, 2021
a626e59
bind) clean up some imports
brianmhunt May 27, 2021
b2fcedf
ci) remove peer devDependencies from the monorepo that are used for t…
brianmhunt May 27, 2021
511c84a
make) change lerna concurrency to a variable
brianmhunt May 27, 2021
993ec30
Merge branch '130-1-package-update' of github.com:knockout/tko into 1…
brianmhunt May 27, 2021
35a6c80
Merge branch '130-1-package-update' of github.com:knockout/tko into 1…
brianmhunt May 27, 2021
065fe26
Merge branch '130-1-package-update' of github.com:knockout/tko into 1…
brianmhunt May 27, 2021
43e55c4
Revert "ci) remove peer devDependencies from the monorepo that are us…
brianmhunt May 27, 2021
1eb9949
ci) use concurrency=1 for build/exec
brianmhunt May 29, 2021
6381563
ci) change devDependencies to dependencies or peerDependencies
brianmhunt May 29, 2021
beb0072
make) ensure that the node_modules is built
brianmhunt May 29, 2021
20027ba
workflows) switch to node 16
brianmhunt May 29, 2021
958faec
ci) add sauce env vars
brianmhunt May 30, 2021
8f618ba
ci) remove package-lock.json dupe; start to simplify SauceLabs config
brianmhunt May 30, 2021
f91df81
ci) disable startConnect by default
brianmhunt May 30, 2021
c992c89
ci) disable Safari as it always tseems to time out
brianmhunt May 30, 2021
e21b187
ci) disable SauceLabs, enable local testing
brianmhunt May 30, 2021
6acae6d
ci) disable SL on pull; set test concurrency=1
brianmhunt May 30, 2021
17164cd
ci) try xvfb-run on Github actions
brianmhunt May 30, 2021
8d6a9b0
ci) install electron / npm
brianmhunt May 30, 2021
6100608
ci) try GabrielBB/xvfb-action tests
brianmhunt May 30, 2021
63fcdcc
ci) switch back to SauceLabs w/o recording/screenshots
brianmhunt May 31, 2021
91abdbe
ci) disable CI altogether until we DD it
brianmhunt May 31, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 0 additions & 43 deletions .circleci/config.yml

This file was deleted.

6 changes: 5 additions & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,11 @@ trim_trailing_whitespace = true
charset = utf-8
indent_size = 2

[*.js]
[{Makefile,**.mk}]
indent_size = 4
indent_style = tab

[{*.js,*.ts}]
indent_style = space
indent_size = 2

Expand Down
31 changes: 31 additions & 0 deletions .github/workflows/electron.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Local Node CI

on:
push:
branches-ignore:
- '**'
# push:
# branches: [ master ]
# pull_request:
# branches: [ master ]

jobs:
test:
runs-on: ubuntu-latest

# strategy:
# matrix:
# node-version: [16.x]

steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: 16
- run: sudo apt-get install xvfb
- run: make CONCURRENCY=1 all
- run: npm i electron
- name: Run headless test
uses: GabrielBB/xvfb-action@v1
with:
run: make test
36 changes: 36 additions & 0 deletions .github/workflows/saucelabs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: SauceLabs Browser CI


on:
push:
branches-ignore:
- '**'
# push:
# branches: [ master ]
# pull_request:
# branches: [ master ]

jobs:
test:
runs-on: ubuntu-latest

# strategy:
# matrix:
# node-version: [16.x]

steps:
- uses: saucelabs/sauce-connect-action@v1
with:
username: ${{ secrets.SAUCE_USERNAME }}
accessKey: ${{ secrets.SAUCE_ACCESS_KEY }}
tunnelIdentifier: github-action-tunnel
scVersion: 4.6.4
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: 16
- run: make CONCURRENCY=1 all
- run: make ci
env:
SAUCE_USERNAME: ${{ secrets.SAUCE_USERNAME }}
SAUCE_ACCESS_KEY: ${{ secrets.SAUCE_ACCESS_KEY }}
15 changes: 2 additions & 13 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,17 +26,6 @@ coverage/
*-debug.log
*-error.log

# Rollup Visualizer
visual.html
packages/*/visual.html
/package-lock.json
/packages/tko/dist/tko.js
/packages/tko/dist/tko.js.map
/packages/tko/dist/tko.min.js
/packages/tko/dist/tko.min.js.map
/packages/tko/dist/tko.es6.js
/packages/tko/dist/tko.es6.js.map
/packages/tko/dist/tko.es6.min.js
/packages/tko/dist/tko.es6.min.js.map
/.vscode
package-lock.json
.vscode
docs
75 changes: 50 additions & 25 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,33 +1,36 @@
NODE := npx
LERNA := $(NODE) lerna
NPX := npx
NODE := node
NPM := npm
LERNA := npx lerna

default: build
# Some make settings
SHELL := bash
.ONESHELL:
MAKEFLAGS += --warn-undefined-variables
MAKEFLAGS += --no-builtin-rules
CONCURRENCY = 8

.PHONY: test
test:
$(LERNA) exec --concurrency=1 --loglevel=warn -- yarn test
default: all

.PHONY: testn
testn:
$(LERNA) exec --concurrency=6 --loglevel=warn -- yarn test
package.json:

.PHONY: build
build: node_modules
$(LERNA) exec --concurrency=6 --loglevel=warn -- yarn build
node_modules: package-lock.json

.PHONY: lint
lint:
$(NODE) standard
all:: node_modules
$(LERNA) --concurrency $(CONCURRENCY) exec --stream -- $(MAKE)

test:
$(LERNA) exec --stream -- $(MAKE) test

ci:
$(LERNA) exec --stream --concurrency=1 -- $(MAKE) test-ci

.PHONY: repackage
repackage:
$(NODE) ./tools/common-package-config.js packages/shared.package.json packages/*/package.json
lint:
$(NPX) standard

.PHONY: bootstrap
bootstrap:
$(LERNA) bootstrap
repackage: tools/repackage.mjs
$(LERNA) exec --stream -- $(MAKE) repackage

.PHONY: bump
bump:
$(LERNA) version

Expand All @@ -36,7 +39,29 @@ bump:
publish-unpublished: build
$(LERNA) publish from-package

node_modules: bootstrap
$(NODE) yarn install
package-lock.json: package.json packages/*/package.json
$(NPM) i

package.json:

install: node_modules

outdated-list:
$(NPM) outdated

outdated-upgrade:
$(NPM) upgrade-interactive --latest

install: package-lock.json

clean:
rm -f package-lock.json
rm -rf packages/*/dist/*
rm -rf packages/*/package-lock.json
rm -rf builds/*/dist/*
rm -rf builds/*/package-lock.json

all: build test
# Local linking of these packages, so they
# are available for local testing/dev.
link:
$(LERNA) exec --stream -- npm link
8 changes: 8 additions & 0 deletions builds/knockout/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@

include ../../tools/build.mk

iife-global-name := ko

default::
$(MAKE) browser

10 changes: 2 additions & 8 deletions packages/build.knockout/README.md → builds/knockout/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,9 @@ Commands for building & testing:

```
Build all:
$ yarn build
$ make

Test once.
$ yarn test

Build only ES6 (the tested version):
$ yarn build --es6

Watch with Karma server
$ yarn watch
$ make test
```

1 change: 1 addition & 0 deletions builds/knockout/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './src'
Original file line number Diff line number Diff line change
@@ -1,22 +1,17 @@
{
"version": "4.0.0-alpha9.0",
"name": "@tko/build.knockout",
"description": "Knockout makes it easier to create rich, responsive UIs with JavaScript",
"homepage": "https://tko.io",
"version": "4.0.0-alpha9.0",
"license": "MIT",
"author": "The Knockout.js team",
"main": "dist/build.knockout.js",
"scripts": {
"test": "npx karma start ../../karma.conf.js --once",
"build": "npx rollup -c ../../rollup.config.js",
"watch": "npx karma start ../../karma.conf.js",
"prepare": "npx rollup -c ../../rollup.config.js"
},
"author": "The Knockout Team",
"repository": {
"type": "git",
"url": "https://github.com/knockout/knockout.git"
"url": "git+https://github.com/knockout/tko.git"
},
"bugs": {
"url": "https://github.com/knockout/tko/issues"
},
"bugs": "https://github.com/knockout/knockout/issues",
"testling": {
"preprocess": "build/build.sh",
"html": "spec/runner.html?src=build/output/knockout-latest.js&testling=true",
Expand All @@ -39,18 +34,18 @@
"jasmine"
],
"files": [
"dist/build.knockout.es6.js",
"dist/browser.min.js",
"helpers/jasmine.extensions.js",
"spec/**/*.js"
]
},
"licenses": [
{
"type": "MIT",
"url": "http://www.opensource.org/licenses/mit-license.php"
"url": "https://opensource.org/licenses/MIT"
}
],
"devDependencies": {
"dependencies": {
"@tko/binding.component": "^4.0.0-alpha9.0",
"@tko/binding.core": "^4.0.0-alpha9.0",
"@tko/binding.foreach": "^4.0.0-alpha9.0",
Expand All @@ -67,17 +62,13 @@
"@tko/provider.virtual": "^4.0.0-alpha9.0",
"@tko/utils.component": "^4.0.0-alpha9.0",
"@tko/utils.functionrewrite": "^4.0.0-alpha8.2",
"tslib": "^1.8.0"
},
"__about__shared.package.json": "These properties are copied into all packages/*/package.json. Run `yarn repackage`",
"standard": {
"env": [
"browser",
"jasmine",
"mocha"
]
"tslib": "^2.2.0"
},
"publishConfig": {
"access": "public"
"exports": {
".": {
"require": "./dist/index.cjs",
"import": "./dist/index.js"
},
"./helpers/*": "./helpers/*"
}
}
File renamed without changes.
4 changes: 4 additions & 0 deletions builds/knockout/src/common.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/**
* Without the following the only export is `default`
*/
module.exports = require('./index').default
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,9 @@ const builder = new Builder({
}
})

const version = BUILD_VERSION
export default builder.create({
version: '{{ VERSION }}',
version,
components,
Component: components.ComponentABC,
expressionRewriting
Expand Down
5 changes: 5 additions & 0 deletions builds/reference/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@

include ../../tools/build.mk

default::
$(MAKE) browser
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 2 additions & 0 deletions builds/reference/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export {default} from './src'
export * from './src'
Loading