Skip to content

Commit

Permalink
Use workspace:^ for internal devDependencies (#8818)
Browse files Browse the repository at this point in the history
  • Loading branch information
dcousens authored Sep 19, 2023
1 parent f6c8f9f commit aa18279
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 50 deletions.
2 changes: 1 addition & 1 deletion packages/auth/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"graphql": "^16.6.0"
},
"devDependencies": {
"@keystone-6/core": "^5.4.0",
"@keystone-6/core": "workspace:^",
"react": "^18.2.0"
},
"peerDependencies": {
Expand Down
6 changes: 2 additions & 4 deletions packages/cloudinary/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,10 @@
"@keystone-6/core": "^5.0.0"
},
"devDependencies": {
"@keystone-6/core": "^5.4.0",
"@keystone-6/core": "workspace:^",
"@types/express": "^4.17.14",
"@types/mime": "^3.0.0",
"graphql": "^16.6.0",
"graphql-upload": "^15.0.2",
"mime": "^3.0.0"
"graphql-upload": "^15.0.2"
},
"preconstruct": {
"entrypoints": [
Expand Down
19 changes: 8 additions & 11 deletions packages/cloudinary/src/test-fixtures.skip.ts
Original file line number Diff line number Diff line change
@@ -1,30 +1,27 @@
import fs from 'fs';
import mime from 'mime';
import { createReadStream } from 'node:fs';
import { resolve, basename } from 'node:path';
// @ts-ignore
import Upload from 'graphql-upload/Upload.js';
import cloudinary from 'cloudinary';
import { cloudinaryImage } from './index';

const path = require('path');

cloudinary.v2.config({
cloud_name: process.env.CLOUDINARY_CLOUD_NAME || 'cloudinary_cloud_name',
api_key: process.env.CLOUDINARY_KEY || 'cloudinary_key',
api_secret: process.env.CLOUDINARY_SECRET || 'cloudinary_secret',
});

const prepareFile = (_filePath: string) => {
const filePath = path.resolve(`packages/cloudinary/src/test-files/${_filePath}`);
function prepareFile(path_: string) {
const path = resolve(`packages/cloudinary/src/test-files/${path_}`);
const upload = new Upload();
upload.resolve({
createReadStream: () => fs.createReadStream(filePath),
filename: path.basename(filePath),
// @ts-ignore
mimetype: mime.getType(filePath),
createReadStream: () => createReadStream(path),
filename: basename(path),
mimetype: 'image/jpeg',
encoding: 'utf-8',
});
return upload;
};
}

// Configurations
export const name = 'CloudinaryImage';
Expand Down
11 changes: 5 additions & 6 deletions packages/fields-document/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,7 @@
"structure-views.tsx"
]
},
"peerDependencies": {
"@keystone-6/core": "^5.0.0"
},
"repository": "https://github.com/keystonejs/keystone/tree/main/packages/fields-document",
"dependencies": {
"@babel/runtime": "^7.16.3",
"@braintree/sanitize-url": "^6.0.1",
Expand Down Expand Up @@ -81,14 +79,15 @@
"slate-history": "^0.93.0",
"slate-react": "^0.97.1"
},
"repository": "https://github.com/keystonejs/keystone/tree/main/packages/fields-document",
"devDependencies": {
"@keystone-6/core": "*",
"@keystone-6/core": "workspace:^",
"@testing-library/react": "^14.0.0",
"@types/is-hotkey": "^0.1.7",
"array.prototype.flat": "^1.2.5",
"jest-diff": "^29.0.0",
"pretty-format": "^29.0.0",
"slate-hyperscript": "^0.81.3"
},
"peerDependencies": {
"@keystone-6/core": "^5.0.0"
}
}
3 changes: 0 additions & 3 deletions packages/fields-document/src/DocumentEditor/tests/jsx/impl.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
// slate-hyperscript depends on Array.prototype.flat
import 'array.prototype.flat/auto';
import { createHyperscript } from 'slate-hyperscript';

import { editorSchema } from '../../index';

const blockTypes: Record<string, { type: string }> = {};
Expand Down
28 changes: 3 additions & 25 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit aa18279

Please sign in to comment.