-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fbb4fb1
commit 954f94c
Showing
9 changed files
with
63 additions
and
97 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
56 changes: 0 additions & 56 deletions
56
packages/qwik/src/cli/migrate-v2/tools/visit-not-ignored-files.spec.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import { readPackageJson, writePackageJson } from './../utils/utils'; | ||
// import { getPackageManager } from './../utils/utils'; | ||
// import { installDeps } from '../utils/install-deps'; | ||
import { versions } from './versions'; | ||
|
||
export async function updateDependencies() { | ||
// TODO(migrate-v2): rely on workspaceRoot instead? | ||
const packageJson = await readPackageJson(process.cwd()); | ||
const devDependencies = (packageJson.devDependencies ??= {}); | ||
|
||
// TODO: this logic should be enhanced to check in both dependencies and devDependencies | ||
for (const key of Object.keys(devDependencies)) { | ||
if (Object.prototype.hasOwnProperty.call(versions, key)) { | ||
// for now only updating existing dependencies if they exist in root package.json | ||
devDependencies[key] = versions[key as unknown as keyof typeof versions]; | ||
} | ||
} | ||
|
||
await writePackageJson(process.cwd(), packageJson); | ||
// TODO(migrate-v2): not installing dependencies because we don't have correct versions set | ||
// const { install } = installDeps(getPackageManager(), process.cwd()); | ||
// const passed = await install; | ||
// if (!passed) { | ||
// throw new Error('Failed to install dependencies'); | ||
// } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
export const versions = { | ||
'@qwik.dev/qwik': '2.0.0', | ||
'@qwik.dev/city': '2.0.0', | ||
'eslint-plugin-qwik': '2.0.0', | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.