val
val•8mo ago

update imports to latest version in `deno.json`

i defined imports as URLs with the version of the packages in my deno.json file. i would like to know if there's an automated way to update all the import URLs to the latest version within the deno.json file. thanks!
3 Replies
Deno AI Helper
Deno AI Helper•8mo ago
Yes, there is an automated way to update the import URLs to the latest version within your deno.json file. The documentation provides information about an auto updater tool that you can use to update your project dependencies, including the versions specified in your deno.json file. To run the auto updater, you should execute the following command from the root of your project:
deno run -A -r https://fresh.deno.dev/update
deno run -A -r https://fresh.deno.dev/update
When you run this command, you will be prompted to confirm the changes that will be made to your project. This tool will update your deno.json file to the latest versions of Fresh and its dependencies and may also contain code mods for your project that will update your code to the latest recommended patterns for Fresh projects. 🦕 Keep in mind that this tool is specifically mentioned in the context of the Fresh framework, so if your project is not using Fresh, you might need to manually update the dependency versions in your deno.json file by editing the URLs to point to the latest versions of the packages you are using.
Leokuma
Leokuma•8mo ago
There's nothing built-in, only userland tools like Molt. You can pass your deno.json as an import map to Molt https://github.com/hasundue/molt
GitHub
GitHub - hasundue/molt: Update dependencies the Deno way
Update dependencies the Deno way. Contribute to hasundue/molt development by creating an account on GitHub.
val
val•8mo ago
thanks a lot @Leokuma didn't know about molt!