Skip to content

Commit

Permalink
use @warp-drive beta
Browse files Browse the repository at this point in the history
  • Loading branch information
AmauryD committed Jun 6, 2024
1 parent 72326e4 commit 95e3f8e
Show file tree
Hide file tree
Showing 14 changed files with 2,235 additions and 1,580 deletions.
69 changes: 36 additions & 33 deletions .husky/_/pre-push
Original file line number Diff line number Diff line change
Expand Up @@ -10,46 +10,49 @@ fi

call_lefthook()
{
dir="$(git rev-parse --show-toplevel)"
osArch=$(uname | tr '[:upper:]' '[:lower:]')
cpuArch=$(uname -m | sed 's/aarch64/arm64/')

if test -n "$LEFTHOOK_BIN"
then
"$LEFTHOOK_BIN" "$@"
elif lefthook -h >/dev/null 2>&1
then
lefthook "$@"
elif test -f "$dir/node_modules/lefthook/bin/index.js"
then
"$dir/node_modules/lefthook/bin/index.js" "$@"
elif test -f "$dir/node_modules/@evilmartians/lefthook/bin/lefthook_${osArch}_${cpuArch}/lefthook"
then
"$dir/node_modules/@evilmartians/lefthook/bin/lefthook_${osArch}_${cpuArch}/lefthook" "$@"
elif test -f "$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook_${osArch}_${cpuArch}/lefthook"
then
"$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook_${osArch}_${cpuArch}/lefthook" "$@"

elif bundle exec lefthook -h >/dev/null 2>&1
then
bundle exec lefthook "$@"
elif yarn lefthook -h >/dev/null 2>&1
then
yarn lefthook "$@"
elif pnpm lefthook -h >/dev/null 2>&1
then
pnpm lefthook "$@"
elif swift package plugin lefthook >/dev/null 2>&1
then
swift package --disable-sandbox plugin lefthook "$@"
elif command -v mint >/dev/null 2>&1
then
mint run csjones/lefthook-plugin "$@"
elif command -v npx >/dev/null 2>&1
then
npx lefthook "$@"
else
echo "Can't find lefthook in PATH"
dir="$(git rev-parse --show-toplevel)"
if test -f "$dir/node_modules/lefthook/bin/index.js"
then
"$dir/node_modules/lefthook/bin/index.js" "$@"
else
osArch=$(uname | tr '[:upper:]' '[:lower:]')
cpuArch=$(uname -m | sed 's/aarch64/arm64/')
if test -f "$dir/node_modules/@evilmartians/lefthook/bin/lefthook_${osArch}_${cpuArch}/lefthook"
then
"$dir/node_modules/@evilmartians/lefthook/bin/lefthook_${osArch}_${cpuArch}/lefthook" "$@"
elif test -f "$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook_${osArch}_${cpuArch}/lefthook"
then
"$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook_${osArch}_${cpuArch}/lefthook" "$@"

elif bundle exec lefthook -h >/dev/null 2>&1
then
bundle exec lefthook "$@"
elif yarn lefthook -h >/dev/null 2>&1
then
yarn lefthook "$@"
elif pnpm lefthook -h >/dev/null 2>&1
then
pnpm lefthook "$@"
elif swift package plugin lefthook >/dev/null 2>&1
then
swift package --disable-sandbox plugin lefthook "$@"
elif command -v mint >/dev/null 2>&1
then
mint run csjones/lefthook-plugin "$@"
elif command -v npx >/dev/null 2>&1
then
npx lefthook "$@"
else
echo "Can't find lefthook in PATH"
fi
fi
fi
}

Expand Down
69 changes: 36 additions & 33 deletions .husky/_/prepare-commit-msg
Original file line number Diff line number Diff line change
Expand Up @@ -10,46 +10,49 @@ fi

call_lefthook()
{
dir="$(git rev-parse --show-toplevel)"
osArch=$(uname | tr '[:upper:]' '[:lower:]')
cpuArch=$(uname -m | sed 's/aarch64/arm64/')

if test -n "$LEFTHOOK_BIN"
then
"$LEFTHOOK_BIN" "$@"
elif lefthook -h >/dev/null 2>&1
then
lefthook "$@"
elif test -f "$dir/node_modules/lefthook/bin/index.js"
then
"$dir/node_modules/lefthook/bin/index.js" "$@"
elif test -f "$dir/node_modules/@evilmartians/lefthook/bin/lefthook_${osArch}_${cpuArch}/lefthook"
then
"$dir/node_modules/@evilmartians/lefthook/bin/lefthook_${osArch}_${cpuArch}/lefthook" "$@"
elif test -f "$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook_${osArch}_${cpuArch}/lefthook"
then
"$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook_${osArch}_${cpuArch}/lefthook" "$@"

elif bundle exec lefthook -h >/dev/null 2>&1
then
bundle exec lefthook "$@"
elif yarn lefthook -h >/dev/null 2>&1
then
yarn lefthook "$@"
elif pnpm lefthook -h >/dev/null 2>&1
then
pnpm lefthook "$@"
elif swift package plugin lefthook >/dev/null 2>&1
then
swift package --disable-sandbox plugin lefthook "$@"
elif command -v mint >/dev/null 2>&1
then
mint run csjones/lefthook-plugin "$@"
elif command -v npx >/dev/null 2>&1
then
npx lefthook "$@"
else
echo "Can't find lefthook in PATH"
dir="$(git rev-parse --show-toplevel)"
if test -f "$dir/node_modules/lefthook/bin/index.js"
then
"$dir/node_modules/lefthook/bin/index.js" "$@"
else
osArch=$(uname | tr '[:upper:]' '[:lower:]')
cpuArch=$(uname -m | sed 's/aarch64/arm64/')
if test -f "$dir/node_modules/@evilmartians/lefthook/bin/lefthook_${osArch}_${cpuArch}/lefthook"
then
"$dir/node_modules/@evilmartians/lefthook/bin/lefthook_${osArch}_${cpuArch}/lefthook" "$@"
elif test -f "$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook_${osArch}_${cpuArch}/lefthook"
then
"$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook_${osArch}_${cpuArch}/lefthook" "$@"

elif bundle exec lefthook -h >/dev/null 2>&1
then
bundle exec lefthook "$@"
elif yarn lefthook -h >/dev/null 2>&1
then
yarn lefthook "$@"
elif pnpm lefthook -h >/dev/null 2>&1
then
pnpm lefthook "$@"
elif swift package plugin lefthook >/dev/null 2>&1
then
swift package --disable-sandbox plugin lefthook "$@"
elif command -v mint >/dev/null 2>&1
then
mint run csjones/lefthook-plugin "$@"
elif command -v npx >/dev/null 2>&1
then
npx lefthook "$@"
else
echo "Can't find lefthook in PATH"
fi
fi
fi
}

Expand Down
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
auto-install-peers=false
10 changes: 9 additions & 1 deletion ember-cli-build.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
'use strict';

const EmberApp = require('ember-cli/lib/broccoli/ember-app');
const { join } = require('path');

module.exports = async function (defaults) {
const { setConfig } = await import('@warp-drive/build-config');
const { macros } = await import('@warp-drive/build-config/babel-macros');

module.exports = function (defaults) {
process.on('uncaughtException', (err) => {
// eslint-disable-next-line no-console
console.error(err.stack);
Expand Down Expand Up @@ -53,6 +57,10 @@ module.exports = function (defaults) {

const { Webpack } = require('@embroider/webpack');

setConfig(app, __dirname, {
compatWith: process.env.EMBER_DATA_FULL_COMPAT ? '99.0' : null,
});

return require('@embroider/compat').compatBuild(app, Webpack, {
packagerOptions: {
webpackConfig: {
Expand Down
88 changes: 47 additions & 41 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,37 +26,38 @@
"test:ember": "ember test"
},
"devDependencies": {
"@babel/core": "^7.24.4",
"@babel/eslint-parser": "^7.24.5",
"@babel/plugin-proposal-decorators": "^7.24.1",
"@ember-data-types/adapter": "5.4.0-alpha.64",
"@ember-data-types/graph": "5.4.0-alpha.64",
"@ember-data-types/json-api": "5.4.0-alpha.64",
"@ember-data-types/legacy-compat": "5.4.0-alpha.64",
"@ember-data-types/model": "5.4.0-alpha.64",
"@ember-data-types/request": "5.4.0-alpha.64",
"@ember-data-types/request-utils": "5.4.0-alpha.64",
"@ember-data-types/serializer": "5.4.0-alpha.64",
"@ember-data-types/store": "5.4.0-alpha.64",
"@ember-data-types/tracking": "5.4.0-alpha.64",
"@ember-data/adapter": "5.4.0-alpha.64",
"@ember-data/graph": "5.4.0-alpha.64",
"@ember-data/json-api": "5.4.0-alpha.64",
"@ember-data/legacy-compat": "5.4.0-alpha.64",
"@ember-data/model": "5.4.0-alpha.64",
"@ember-data/request": "5.4.0-alpha.64",
"@ember-data/request-utils": "5.4.0-alpha.64",
"@ember-data/rest": "5.4.0-alpha.64",
"@ember-data/serializer": "5.4.0-alpha.64",
"@ember-data/store": "5.4.0-alpha.64",
"@ember-data/tracking": "5.4.0-alpha.64",
"@babel/core": "^7.24.7",
"@babel/eslint-parser": "^7.24.7",
"@babel/plugin-proposal-decorators": "^7.24.7",
"@ember-data-types/adapter": "5.4.0-beta.5",
"@ember-data-types/graph": "5.4.0-beta.5",
"@ember-data-types/json-api": "5.4.0-beta.5",
"@ember-data-types/legacy-compat": "5.4.0-beta.5",
"@ember-data-types/model": "5.4.0-beta.5",
"@ember-data-types/request": "5.4.0-beta.5",
"@ember-data-types/request-utils": "5.4.0-beta.5",
"@ember-data-types/serializer": "5.4.0-beta.5",
"@ember-data-types/store": "5.4.0-beta.5",
"@ember-data-types/tracking": "5.4.0-beta.5",
"@ember-data/adapter": "5.4.0-beta.5",
"@ember-data/graph": "5.4.0-beta.5",
"@ember-data/json-api": "5.4.0-beta.5",
"@ember-data/legacy-compat": "5.4.0-beta.5",
"@ember-data/model": "5.4.0-beta.5",
"@ember-data/request": "5.4.0-beta.5",
"@ember-data/request-utils": "5.4.0-beta.5",
"@ember-data/rest": "5.4.0-beta.5",
"@ember-data/serializer": "5.4.0-beta.5",
"@ember-data/store": "5.4.0-beta.5",
"@ember-data/tracking": "5.4.0-beta.5",
"@ember/optional-features": "~2.1.0",
"@ember/render-modifiers": "~2.1.0",
"@ember/string": "^3.1.1",
"@ember/test-helpers": "^3.3.0",
"@ember/test-waiters": "~3.1.0",
"@embroider/compat": "~3.5.1",
"@embroider/core": "~3.4.10",
"@embroider/macros": "^1.16.2",
"@embroider/router": "2.1.8",
"@embroider/test-setup": "~4.0.0",
"@embroider/webpack": "^4.0.1",
Expand All @@ -73,22 +74,24 @@
"@triptyk/ember-simple-auth-token": "6.0.0-beta.1",
"@triptyk/ember-ui": "2.1.0-beta.1",
"@tsconfig/ember": "~3.0.6",
"@types/node": "^20.12.14",
"@types/node": "^20.14.2",
"@types/qunit": "~2.19.10",
"@types/rsvp": "~4.0.9",
"@typescript-eslint/eslint-plugin": "~7.11.0",
"@typescript-eslint/parser": "~7.11.0",
"@warp-drive-types/core-types": "0.0.0-alpha.50",
"@warp-drive/core-types": "0.0.0-alpha.50",
"@warp-drive/schema-record": "0.0.0-alpha.50",
"@typescript-eslint/eslint-plugin": "~7.12.0",
"@typescript-eslint/parser": "~7.12.0",
"@warp-drive-types/core-types": "0.0.0-beta.5",
"@warp-drive/build-config": "0.0.0-beta.0",
"@warp-drive/core-types": "0.0.0-beta.5",
"@warp-drive/ember": "0.0.0-beta.0",
"@warp-drive/schema-record": "0.0.0-beta.5",
"autoprefixer": "~10.4.19",
"broccoli-asset-rev": "~3.0.0",
"concurrently": "^8.2.2",
"date-fns": "~3.6.0",
"els-intl-addon": "^1.0.6",
"ember-auto-import": "~2.7.3",
"ember-can": "git@github.com:minutebase/ember-can.git#dist",
"ember-cli": "~5.8.1",
"ember-cli": "~5.9.0",
"ember-cli-app-version": "~6.0.1",
"ember-cli-babel": "~8.2.0",
"ember-cli-clean-css": "^3.0.0",
Expand All @@ -103,21 +106,22 @@
"ember-cli-postcss": "~8.2.0",
"ember-cli-terser": "~4.0.2",
"ember-concurrency": "~4.0.2",
"ember-data": "5.4.0-alpha.64",
"ember-data-types": "^5.4.0-alpha.64",
"ember-data": "5.4.0-beta.5",
"ember-data-types": "^5.4.0-beta.5",
"ember-exam": "^9.0.0",
"ember-fetch": "~8.1.2",
"ember-flatpickr": "~8.0.0",
"ember-immer-changeset": "~1.0.2",
"ember-intl": "^6.5.4",
"ember-inflector": "^4.0.2",
"ember-intl": "^7.0.1",
"ember-lifeline": "^7.0.0",
"ember-modifier": "~4.1.0",
"ember-page-title": "~8.2.3",
"ember-qunit": "~8.0.2",
"ember-resolver": "~11.0.1",
"ember-route-template": "^1.0.3",
"ember-simple-auth": "~6.0.0",
"ember-source": "~5.8.0",
"ember-source": "~5.9.0",
"ember-template-imports": "^4.1.0",
"ember-template-lint": "~6.0.0",
"ember-template-lint-plugin-prettier": "~5.0.0",
Expand All @@ -127,28 +131,30 @@
"eslint": "^8.7.0",
"eslint-config-prettier": "~9.1.0",
"eslint-plugin-ember": "~12.1.1",
"eslint-plugin-n": "^17.5.1",
"eslint-plugin-n": "^17.8.1",
"eslint-plugin-prettier": "~5.1.3",
"eslint-plugin-qunit": "~8.1.1",
"eslint-plugin-unicorn": "~53.0.0",
"eslint-plugin-unused-imports": "~4.0.0",
"eslint-plugin-yml": "^1.14.0",
"lefthook": "~1.6.14",
"flatpickr": "^4.6.13",
"lefthook": "~1.6.15",
"loader.js": "~4.7.0",
"msw": "^2.2.14",
"msw": "^2.3.1",
"postcss": "~8.4.38",
"postcss-import": "~16.1.0",
"prettier": "~3.2.5",
"prettier": "~3.3.1",
"prettier-plugin-ember-template-tag": "^2.0.2",
"qunit": "~2.21.0",
"qunit-dom": "~3.1.2",
"rsvp": "^4.8.5",
"stylelint": "^16.6.1",
"stylelint-config-standard": "^36.0.0",
"stylelint-prettier": "^5.0.0",
"tailwindcss": "~3.4.3",
"tailwindcss": "~3.4.4",
"tracked-built-ins": "~3.3.0",
"true-myth": "^7.3.0",
"type-fest": "^4.18.2",
"type-fest": "^4.19.0",
"typescript": "~5.4.5",
"webpack": "^5.91.0",
"yup": "^1.4.0"
Expand Down
Loading

0 comments on commit 95e3f8e

Please sign in to comment.