import * as molt from "https://deno.land/x/molt@0.16.3/mod.ts";
A module to update dependencies in Deno projects using deno_graph.
Examples
To update all dependencies in a module and write the changes to files:
import { collect, writeAll } from "https://deno.land/x/molt@{VERSION}/mod.ts";
const updates = await collect("./mod.ts");
await writeAll(updates);
To update all dependencies in a module and commit the changes to local git repository:
import { collect, commitAll } from "https://deno.land/x/molt@{VERSION}/mod.ts";
const updates = await collect("./mod.ts");
await commitAll(updates, {
groupBy: (dependency) => dependency.name,
composeCommitMessage: ({ group, version }) =>
`build(deps): bump ${group} to ${version!.to}`,
});
Functions
Collect updates to files from the given updates to dependencies. The collected updates are lexically sorted by the url of the file. | |
Collect dependencies from the given module(s) or Deno configuration file(s). Local submodules are also checked recursively. | |
f exec | |
Check if the given version string represents a pre-release. | |
Parse properties of a dependency from the given URL. | |
Resolve the latest version of the given dependency. | |
Convert the given dependency to a URL string. | |
Write the given (array of) FileUpdate to file system. | |
Write the given array of DependencyUpdate to files. |
Interfaces
Properties of a dependency parsed from an import specifier. | |
Representation of an update to a dependency. | |
A collection of updates to dependencies associated with a file. | |
Properties of a dependency parsed from an updated import specifier.
The |