|
1 | 1 | // SPDX-License-Identifier: CC-BY-SA-4.0 |
2 | 2 | // SPDX-FileCopyrightText: 2026 Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk> |
3 | | -// Template: QUICKSTART-USER.adoc — 5-minute path to working software |
4 | | -// Replace panic-attack, Panic Attacker — See README.adoc for details., just run, Panic Attacker started successfully. with actuals |
5 | 3 | = panic-attack — Quick Start for Users |
6 | | -:toc: |
7 | | -:toclevels: 2 |
8 | 4 |
|
9 | | -== What is panic-attack? |
| 5 | +panic-attack provides static analysis and optional stress testing. A scan result |
| 6 | +is evidence within its reported coverage, not a certificate that a project is safe. |
10 | 7 |
|
11 | | -Panic Attacker — See README.adoc for details. |
| 8 | +== Build the default CLI |
12 | 9 |
|
13 | | -== Prerequisites |
| 10 | +Install Rust and Cargo using your preferred tool manager. The default CLI's |
| 11 | +minimum Rust version is declared in `Cargo.toml` (`rust-version`, currently 1.90). |
| 12 | +Use a compatible compiler rather than updating every language toolchain. |
| 13 | +The optional GUI has additional compiler and system-library requirements. |
| 14 | +Scanning a language does not require installing that language's compiler. |
14 | 15 |
|
15 | | -Before you begin, ensure you have: |
| 16 | +The following commands assume a POSIX shell, Git, Zig configured to compile |
| 17 | +native C dependencies through `zig cc`, a working native linker, and access |
| 18 | +to the pinned dependencies. The default build compiles C sources from |
| 19 | +`tree-sitter-php`. Installing Zig alone does not select it for Cargo's native |
| 20 | +dependency build scripts; configure their C compiler before building. |
| 21 | +These commands do not require just, mise, or Guix. |
16 | 22 |
|
17 | | -* **just** — task runner (https://github.com/casey/just[install guide]) |
18 | | -* Platform-specific requirements listed below |
19 | | - |
20 | | -[cols="1,3"] |
21 | | -|=== |
22 | | -| Platform | Additional Requirements |
23 | | - |
24 | | -| Linux |
25 | | -| See README.adoc |
26 | | - |
27 | | -| macOS |
28 | | -| See README.adoc |
29 | | - |
30 | | -| Windows |
31 | | -| See README.adoc |
32 | | -|=== |
33 | | - |
34 | | -== Install |
35 | | - |
36 | | -=== Option 1: Standard Install (recommended) |
37 | | - |
38 | | -[source,bash] |
| 23 | +[source,shell] |
39 | 24 | ---- |
40 | | -# Clone and set up |
41 | 25 | git clone https://github.com/hyperpolymath/panic-attack.git |
42 | 26 | cd panic-attack |
43 | | -just setup |
44 | | ----- |
45 | | - |
46 | | -The setup script will: |
47 | | - |
48 | | -* Detect your platform and shell |
49 | | -* Install missing dependencies (with your permission) |
50 | | -* Configure the application |
51 | | -* Offer install location choices |
52 | | -* Run a self-diagnostic to verify everything works |
53 | | - |
54 | | -=== Option 2: Container (via Stapeln) |
55 | | - |
56 | | -[source,bash] |
57 | | ----- |
58 | | -just stapeln-run |
59 | | ----- |
60 | | - |
61 | | -=== Option 3: Portable (no system changes) |
62 | | - |
63 | | -[source,bash] |
64 | | ----- |
65 | | -just install --portable --prefix=./panic-attack-portable |
66 | | ----- |
67 | | - |
68 | | -== First Run |
69 | | - |
70 | | -[source,bash] |
71 | | ----- |
72 | | -just run |
73 | | ----- |
74 | | - |
75 | | -Expected output: |
76 | | - |
77 | | -[source] |
78 | | ----- |
79 | | -Panic Attacker started successfully. |
80 | | ----- |
81 | | - |
82 | | -== Self-Diagnostic |
83 | | - |
84 | | -If something isn't working: |
85 | | - |
86 | | -[source,bash] |
87 | | ----- |
88 | | -just doctor |
89 | | ----- |
90 | | - |
91 | | -This checks all dependencies, permissions, paths, and connectivity. |
92 | | -If it finds issues, it will suggest fixes. |
93 | | - |
94 | | -To attempt automatic repair: |
95 | | - |
96 | | -[source,bash] |
97 | | ----- |
98 | | -just heal |
99 | | ----- |
100 | | - |
101 | | -== Get Help |
102 | | - |
103 | | -* **In-app**: `just run --help` |
104 | | -* **Guided tour**: `just tour` |
105 | | -* **Report a problem**: `just help-me` (pre-fills diagnostic context) |
106 | | -* **Wiki**: https://github.com/hyperpolymath/panic-attack/wiki |
107 | | - |
108 | | -== Uninstall |
109 | | - |
110 | | -[source,bash] |
111 | | ----- |
112 | | -just uninstall |
113 | | ----- |
114 | | - |
115 | | -You will be asked: |
116 | | - |
117 | | -1. Which uninstall tier (Bennett reversible, parameter-based, standard, or secure) |
118 | | -2. Whether to include or exclude your data |
119 | | -3. Whether to clear caches and LLM models |
120 | | - |
121 | | -== Next Steps |
122 | | - |
123 | | -* Read the link:README.adoc[README] for full feature overview |
124 | | -* Read the link:EXPLAINME.adoc[EXPLAINME] for architecture and design decisions |
125 | | -* Try `just tour` for a guided walkthrough |
| 27 | +cargo build --locked --release |
| 28 | +./target/release/panic-attack --help |
| 29 | +./target/release/panic-attack assail . --fail-on-incomplete --output panic-report.json |
| 30 | +---- |
| 31 | + |
| 32 | +A self-scan can return findings or incomplete coverage, including from deliberate |
| 33 | +test fixtures. Do not interpret a nonzero scan exit as an installation failure; |
| 34 | +inspect `panic-report.json` for individual findings and the coverage outcome. |
| 35 | + |
| 36 | +== Optional task runner and installation |
| 37 | + |
| 38 | +With just installed, `just --list` lists the actual recipes. `just install` |
| 39 | +builds the default release CLI and copies it to `$HOME/.local/bin`, creating |
| 40 | +that directory if needed. Add that directory to PATH yourself if desired. |
| 41 | +This recipe does not install prerequisites or offer a portable/prefix option. |
| 42 | + |
| 43 | +`just doctor` checks whether Cargo, rustc, Git and just can run. It returns |
| 44 | +nonzero for a missing or broken tool. It does not check compiler compatibility, |
| 45 | +network connectivity, runtime safety, or prove a build will succeed. |
| 46 | +Use the locked build above to check compiler and dependency compatibility. |
| 47 | +The probe disables automatic toolchain installation with rustup 1.28.1 and |
| 48 | +later. Older rustup versions and external tool-manager shims may still perform |
| 49 | +their own setup; the diagnostic is not a sandbox around those programs. |
| 50 | + |
| 51 | +== Troubleshooting |
| 52 | + |
| 53 | +Record the failing command and its exit code before changing toolchains. |
| 54 | +Report problems at https://github.com/hyperpolymath/panic-attack/issues with |
| 55 | +the relevant error text. Review any local paths or sensitive details before |
| 56 | +sharing logs. Platform details are optional. |
| 57 | + |
| 58 | +The legacy `setup.sh` still installs just through platform package managers; |
| 59 | +it is not the cross-platform provisioning interface proposed for the estate. |
| 60 | +The direct build path above avoids those automatic package-manager changes. |
| 61 | +The existing `heal` recipe is not a targeted dependency repair service. |
| 62 | +Do not use it as a substitute for diagnosing a failed build. |
| 63 | + |
| 64 | +There are no `stapeln-run`, `run`, or `uninstall` recipes in this checkout. |
| 65 | +To remove a user-local installation, remove only the binary you installed. |
| 66 | +See link:README.adoc[README] for features and analysis limitations. |
0 commit comments