Skip to content

Commit

Permalink
Merge pull request #96 from drashland/pre-release-changes-dmm
Browse files Browse the repository at this point in the history
chore: Make necessary pre-release changes
  • Loading branch information
ebebbington authored Nov 22, 2020
2 parents 2d4a25a + 0fc48d6 commit b463221
Show file tree
Hide file tree
Showing 13 changed files with 30 additions and 31 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ There are two ways you can use this module:
--allow-net='cdn.deno.land,api.deno.land,x.nest.land,raw.githubusercontent.com,github.com,api.github.com' \
--allow-read='.' \
--allow-write='deps.ts' \
https://deno.land/x/dmm@v1.2.0/mod.ts
https://deno.land/x/dmm@v1.3.0/mod.ts

$ dmm help
````
Expand All @@ -68,7 +68,7 @@ There are two ways you can use this module:
--allow-net='cdn.deno.land,api.deno.land,x.nest.land,raw.githubusercontent.com,github.com,api.github.com' \
--allow-read='.' \
--allow-write='deps.ts' \
https://deno.land/x/dmm@v1.2.0/mod.ts \
https://deno.land/x/dmm@v1.3.0/mod.ts \
help
```

Expand Down
10 changes: 6 additions & 4 deletions console/bumper_ci_service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,10 @@ if (b.isForPreRelease()) {
b.bump(preReleaseFiles);
} else {
b.bump(bumperFiles);
Deno.copyFileSync(
"./tests/integration/up-to-date-deps/original_deps.ts",
"./tests/integration/up-to-date-deps/deps.ts",
);
}

// As dmm was used to update the deps, coy the file over so we dont need to include this in bumper files
Deno.copyFileSync(
"./tests/integration/up-to-date-deps/deps.ts",
"./tests/integration/up-to-date-deps/original_deps.ts",
);
10 changes: 0 additions & 10 deletions console/bumper_ci_service_files.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,6 @@ export const preReleaseFiles = [
replaceTheRegex: regexes.deps_drash,
replaceWith: "drash@v{{ latestDrashVersion }}",
},
{
filename: "./tests/integration/up-to-date-deps/original_deps.ts",
replaceTheRegex: regexes.dmm_raw_github,
replaceWith: "dmm/v{{ thisModulesLatestVersion }}",
},
];

export const bumperFiles = [
Expand All @@ -76,9 +71,4 @@ export const bumperFiles = [
replaceTheRegex: regexes.deps_drash,
replaceWith: "drash@v{{ latestDrashVersion }}",
},
{
filename: "./tests/integration/up-to-date-deps/deps.ts",
replaceTheRegex: regexes.dmm_raw_github,
replaceWith: `dmm/v${version}`,
},
];
2 changes: 1 addition & 1 deletion egg.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "dmm",
"description": "Lightweight Deno Module Manager",
"homepage": "https://github.com/drashland/dmm",
"version": "1.2.0",
"version": "1.3.0",
"stable": true,
"files": [
"./mod.ts",
Expand Down
2 changes: 1 addition & 1 deletion src/commands/version.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
export const version = "1.2.0";
export const version = "1.3.0";
export const versionMessage = `dmm ${version}`;
10 changes: 6 additions & 4 deletions tests/integration/check_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { assertEquals, colours } from "../../deps.ts";
import DenoService from "../../src/services/deno_service.ts";
import NestService from "../../src/services/nest_service.ts";
import { outOfDateDepsDir, upToDateDepsDir } from "./test_constants.ts";
import { version } from "../../src/commands/version.ts";
import GitHubService from "../../src/services/github_service.ts";

const latestDrashRelease = await DenoService.getLatestModuleRelease(
"drash",
Expand All @@ -11,7 +11,9 @@ const latestCliffyRelease = await NestService.getLatestModuleRelease(
"cliffy",
);
const latestStdRelease = await DenoService.getLatestModuleRelease("std");

const latestWocketRelease = await GitHubService.getLatestModuleRelease(
"https://github.com/drashland/wocket",
);
// Check a specific dep that can be updated
Deno.test({
name: "Check | Single | Modules to Update Exist - deno.land/x",
Expand Down Expand Up @@ -305,9 +307,9 @@ Deno.test({
colours.blue("INFO") +
` uuid can be updated from 0.61.0 to ${latestStdRelease}\n` +
colours.blue("INFO") +
` dmm can be updated from v1.0.0 to v${version}\n` +
` wocket can be updated from v0.4.0 to ${latestWocketRelease}\n` +
colours.blue("INFO") + " To update, run: \n" +
" dmm update drash fs fmt cliffy log uuid dmm" +
" dmm update drash fs fmt cliffy log uuid wocket" +
"\n",
);
assertEquals(status.code, 0);
Expand Down
4 changes: 2 additions & 2 deletions tests/integration/error_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ A module manager for Deno.
USAGE
deno install --allow-net='x.nest.land,cdn.deno.land,api.deno.land,raw.githubusercontent.com,github.com,api.github.com' --allow-read='.' --allow-write='deps.ts' https://deno.land/x/dmm@v1.2.0/mod.ts
deno install --allow-net='x.nest.land,cdn.deno.land,api.deno.land,raw.githubusercontent.com,github.com,api.github.com' --allow-read='.' --allow-write='deps.ts' https://deno.land/x/dmm@v1.3.0/mod.ts
dmm [SUBCOMMAND]
SUBCOMMANDS
Expand All @@ -50,7 +50,7 @@ SUBCOMMANDS
EXAMPLE USAGE
Install dmm
deno install --allow-net='x.nest.land,cdn.deno.land,api.deno.land,raw.githubusercontent.com,github.com,api.github.com' --allow-read='.' --allow-write='deps.ts' https://deno.land/x/dmm@v1.2.0/mod.ts
deno install --allow-net='x.nest.land,cdn.deno.land,api.deno.land,raw.githubusercontent.com,github.com,api.github.com' --allow-read='.' --allow-write='deps.ts' https://deno.land/x/dmm@v1.3.0/mod.ts
Check a single module
dmm check fs
Expand Down
4 changes: 2 additions & 2 deletions tests/integration/help_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ A module manager for Deno.
USAGE
deno install --allow-net='x.nest.land,cdn.deno.land,api.deno.land,raw.githubusercontent.com,github.com,api.github.com' --allow-read='.' --allow-write='deps.ts' https://deno.land/x/dmm@v1.2.0/mod.ts
deno install --allow-net='x.nest.land,cdn.deno.land,api.deno.land,raw.githubusercontent.com,github.com,api.github.com' --allow-read='.' --allow-write='deps.ts' https://deno.land/x/dmm@v1.3.0/mod.ts
dmm [SUBCOMMAND]
SUBCOMMANDS
Expand All @@ -52,7 +52,7 @@ SUBCOMMANDS
EXAMPLE USAGE
Install dmm
deno install --allow-net='x.nest.land,cdn.deno.land,api.deno.land,raw.githubusercontent.com,github.com,api.github.com' --allow-read='.' --allow-write='deps.ts' https://deno.land/x/dmm@v1.2.0/mod.ts
deno install --allow-net='x.nest.land,cdn.deno.land,api.deno.land,raw.githubusercontent.com,github.com,api.github.com' --allow-read='.' --allow-write='deps.ts' https://deno.land/x/dmm@v1.3.0/mod.ts
Check a single module
dmm check fs
Expand Down
2 changes: 1 addition & 1 deletion tests/integration/out-of-date-deps/deps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ export { v4 } from "https://deno.land/[email protected]/uuid/mod.ts"; //out of date

export { Cliffy, colors, Drash, fs, log };

export { Something } from "https://raw.githubusercontent.com/drashland/dmm/v1.0.0/mod.ts";
export { Something } from "https://raw.githubusercontent.com/drashland/wocket/v0.4.0/mod.ts";
2 changes: 1 addition & 1 deletion tests/integration/out-of-date-deps/original_deps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ export { v4 } from "https://deno.land/[email protected]/uuid/mod.ts"; //out of date

export { Cliffy, colors, Drash, fs, log };

export { Something } from "https://raw.githubusercontent.com/drashland/dmm/v1.0.0/mod.ts";
export { Something } from "https://raw.githubusercontent.com/drashland/wocket/v0.4.0/mod.ts";
2 changes: 1 addition & 1 deletion tests/integration/up-to-date-deps/deps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ export { v4 } from "https://deno.land/[email protected]/uuid/mod.ts"; //up to date

export { Cliffy, colors, Drash, fs, log };

export { Something } from "https://raw.githubusercontent.com/drashland/dmm/v1.2.0/mod.ts";
export { Something } from "https://raw.githubusercontent.com/drashland/wocket/v0.5.0/mod.ts";
2 changes: 1 addition & 1 deletion tests/integration/up-to-date-deps/original_deps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ export { v4 } from "https://deno.land/[email protected]/uuid/mod.ts"; //up to date

export { Cliffy, colors, Drash, fs, log };

export { Something } from "https://raw.githubusercontent.com/drashland/dmm/v1.2.0/mod.ts";
export { Something } from "https://raw.githubusercontent.com/drashland/wocket/v0.5.0/mod.ts";
7 changes: 6 additions & 1 deletion tests/integration/update_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import {
upToDateOriginalDepsFile,
} from "./test_constants.ts";
import { version } from "../../src/commands/version.ts";
import GitHubService from "../../src/services/github_service.ts";

const latestDrashRelease = await DenoService.getLatestModuleRelease(
"drash",
Expand All @@ -20,6 +21,10 @@ const latestCliffyRelease = await NestService.getLatestModuleRelease(
);
const latestStdRelease = await DenoService.getLatestModuleRelease("std");

const latestWocketRelease = await GitHubService.getLatestModuleRelease(
"https://github.com/drashland/wocket",
);

/**
* @param dir eg "out-of-date-deps"
*/
Expand Down Expand Up @@ -297,7 +302,7 @@ Deno.test({
colours.blue("INFO") +
` uuid was updated from 0.61.0 to ${latestStdRelease}\n` +
colours.blue("INFO") +
` dmm was updated from v1.0.0 to v${version}\n`;
` wocket was updated from v0.4.0 to ${latestWocketRelease}\n`;
assertEquals(stdout, assertedOutput);
assertEquals(stderr, "");
assertEquals(status.code, 0);
Expand Down

0 comments on commit b463221

Please sign in to comment.