afterpack 1.1.0 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +19 -0
- package/dist/cli.js +4 -2
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,25 @@
|
|
|
2
2
|
|
|
3
3
|
The full changelog, including cloud and dashboard changes, is at https://www.afterpack.dev/changelog.
|
|
4
4
|
|
|
5
|
+
## 1.2.0 - 2026-11-28
|
|
6
|
+
|
|
7
|
+
A file list for every build, and excluded files stay local
|
|
8
|
+
|
|
9
|
+
### Added
|
|
10
|
+
|
|
11
|
+
- **Dashboard:** Every Pro cloud build's page lists the files it was made of, each with its size before and after protection, its inflation and its status. Coverage, inflation and complexity show on every build, with or without a Protection Map. ([Builds](https://www.afterpack.dev/docs/dashboard/builds))
|
|
12
|
+
- **Dashboard:** A build's page names the bundle it built, such as `vite.landing.config.ts`, and shows whether it ran in CI, with a link to the run, or locally. The builds list groups the builds of one commit by bundle. The bundle name and the CI details come from the 1.2.0 CLI and plugins.
|
|
13
|
+
- **Plugins:** A Pro cloud build reports the bundle it built, the CI provider and a link to the CI run, for the build's page.
|
|
14
|
+
- **Engine:** The build context in `@afterpack/core` accepts `bundle`, `environment`, `ciProvider` and `ciRunUrl`.
|
|
15
|
+
|
|
16
|
+
### Changed
|
|
17
|
+
|
|
18
|
+
- **Plugins:** On a Pro cloud build, files matched by `paths.exclude` are no longer uploaded or billed. They ship unchanged, as before, and still appear in the build's file list. ([paths.exclude](https://www.afterpack.dev/docs/config#paths-exclude))
|
|
19
|
+
|
|
20
|
+
### Fixed
|
|
21
|
+
|
|
22
|
+
- **Cloud:** A Pro cloud build no longer hangs when an upload stalls: the stalled part is sent again, and it is not billed twice.
|
|
23
|
+
|
|
5
24
|
## 1.1.0 - 2026-11-28
|
|
6
25
|
|
|
7
26
|
Cloud builds of any size, all-caps variables and empty values that reset
|
package/dist/cli.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { closeSync, existsSync, mkdirSync, openSync, readFileSync, readdirSync, realpathSync, renameSync, rmSync, rmdirSync, statSync, writeFileSync, writeSync } from "node:fs";
|
|
3
3
|
import { processBatch, version } from "@afterpack/core";
|
|
4
|
-
import { AFTERPACK_DIR, AfterpackFilesError, AlreadyObfuscatedError, CLOUD_REFUSAL_SUMMARY, CONFIG_KEYS, CORE_FLOOR_SUMMARY, CloudApiError, CoreVersionError, DIAG_ALREADY_OBFUSCATED, NEXT_CHUNKS_PREFIX, PROTECTION_RECEIPTS_DIR, UnreadableReceiptError, afterpackHome, angularHashToken, angularServerManifestRefusal, buildDirKey, collectJsFiles, createTelemetryReporter, detectNextBundler, ensureAfterpackGitignore, findHashTokenReference, getPath, installedRequiredLine, isWithinDir, loadConfigFile, locateProtectionReceipt, mergeLayers, nextChunkToken, npxAlternative, parseCliOptions, parseEnvOptions, planAngularIntegrity, protectionReceiptPath, resolveClientIdentity, resolvePluginConfig, runObfuscationPass, serverAddsInfo, sha256Hex, skipNextInternals, stagedPath, unreferencedHashedFiles, verifyProtectionReceipt, writeFileAtomic } from "@afterpack/integration-utils";
|
|
4
|
+
import { AFTERPACK_DIR, AfterpackFilesError, AlreadyObfuscatedError, CLOUD_REFUSAL_SUMMARY, CONFIG_KEYS, CORE_FLOOR_SUMMARY, CloudApiError, CoreVersionError, DIAG_ALREADY_OBFUSCATED, NEXT_CHUNKS_PREFIX, PROTECTION_RECEIPTS_DIR, UnreadableReceiptError, afterpackHome, angularHashToken, angularServerManifestRefusal, buildDirKey, collectJsFiles, createTelemetryReporter, detectNextBundler, ensureAfterpackGitignore, findHashTokenReference, getPath, installedRequiredLine, isWithinDir, loadConfigFile, locateProtectionReceipt, mergeLayers, nextChunkToken, npxAlternative, parseCliOptions, parseEnvOptions, pathBundleLabel, planAngularIntegrity, protectionReceiptPath, resolveClientIdentity, resolvePluginConfig, runObfuscationPass, serverAddsInfo, sha256Hex, skipNextInternals, stagedPath, unreferencedHashedFiles, verifyProtectionReceipt, writeFileAtomic } from "@afterpack/integration-utils";
|
|
5
5
|
import { basename, dirname, isAbsolute, join, posix, relative, resolve, sep } from "node:path";
|
|
6
6
|
import { createHash, generateKeyPairSync, randomUUID } from "node:crypto";
|
|
7
7
|
import { hostname } from "node:os";
|
|
@@ -2760,6 +2760,7 @@ async function runObfuscationAndBackup(input) {
|
|
|
2760
2760
|
telemetry: createTelemetryReporter({ logger: input.notice }),
|
|
2761
2761
|
clientVersion: input.version,
|
|
2762
2762
|
client: input.client,
|
|
2763
|
+
bundle: input.bundle,
|
|
2763
2764
|
seed: input.parsed.seed,
|
|
2764
2765
|
seedFallback: input.parsed.seedFallback,
|
|
2765
2766
|
key: input.parsed.key,
|
|
@@ -3163,7 +3164,8 @@ async function runHolding(deps, locks) {
|
|
|
3163
3164
|
backupEnabled,
|
|
3164
3165
|
slot,
|
|
3165
3166
|
layout: layoutDecision.status === "rename" ? layoutDecision.layout : null,
|
|
3166
|
-
client: deps.client ?? null
|
|
3167
|
+
client: deps.client ?? null,
|
|
3168
|
+
bundle: pathBundleLabel(target, projectRoot)
|
|
3167
3169
|
});
|
|
3168
3170
|
if (failure !== null && undoFailure !== null) return refuseHere(EXIT.failure, "UNDO_FAILED", failure, backupEnabled ? "AfterPack could not undo its partial writes. Run `afterpack restore` to put the build output back as your bundler wrote it." : "AfterPack could not undo its partial writes. Rebuild from source before running afterpack again.", [undoFailure]);
|
|
3169
3171
|
if (failureError instanceof AlreadyObfuscatedError) return refuseAlreadyObfuscated(logger, cwd, mode, version$1, failureError);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "afterpack",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.0",
|
|
4
4
|
"description": "AfterPack CLI: obfuscate the JavaScript in any build output, verify a build before deploy, and scan a live site",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -15,8 +15,8 @@
|
|
|
15
15
|
"dist"
|
|
16
16
|
],
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@afterpack/core": "~1.
|
|
19
|
-
"@afterpack/integration-utils": "1.
|
|
18
|
+
"@afterpack/core": "~1.2.0",
|
|
19
|
+
"@afterpack/integration-utils": "1.2.0"
|
|
20
20
|
},
|
|
21
21
|
"devDependencies": {
|
|
22
22
|
"@biomejs/biome": "2.4.4",
|