@dovocode/workstation 0.1.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/README.md ADDED
@@ -0,0 +1,75 @@
1
+ # @dovocode/workstation
2
+
3
+ Declare your workstation in TypeScript. Install packages through mise,
4
+ Homebrew, or APT; generate configuration and shell files; manage services;
5
+ build custom tools; and run named tasks.
6
+
7
+ The package is `@dovocode/workstation`. The executable is **`workstation`**.
8
+
9
+ ## Build from source
10
+
11
+ ```sh
12
+ git clone https://github.com/dovocode/workstation.git
13
+ cd workstation
14
+ corepack pnpm install --frozen-lockfile
15
+ corepack pnpm build
16
+ node dist/cli.js --help
17
+ ```
18
+
19
+ This repository contains the reusable package only. It does not contain a
20
+ personal workstation configuration. Create `workstation.config.ts` in your
21
+ own setup project and make this package available there (for local development,
22
+ use a pnpm link or a tarball produced by `pnpm pack`). No npm release is implied
23
+ by the GitHub repository.
24
+
25
+ Run `workstation init` in your setup project to create a typed starter with
26
+ empty resources, machine sections, and an example task and alias. It never
27
+ overwrites an existing file or applies your setup. Use
28
+ `workstation init --config setup/workstation.config.ts` for another location.
29
+
30
+ ```ts
31
+ import { defineConfig, files, jsonc, task, tools } from "@dovocode/workstation";
32
+
33
+ export default defineConfig({
34
+ resources: [
35
+ tools.mise({ node: "lts" }),
36
+ files.jsonc("~/.config/example/settings.jsonc", jsonc.object([
37
+ jsonc.comment("Shared preferences"),
38
+ jsonc.property("theme", "dark"),
39
+ ])),
40
+ ],
41
+ tasks: { test: task("pnpm", ["test"], { description: "Run tests" }) },
42
+ aliases: { t: "test" },
43
+ });
44
+ ```
45
+
46
+ ```sh
47
+ workstation # Execute the declared setup
48
+ workstation --list-tasks
49
+ workstation t -- --watch # Run only the named task
50
+ ```
51
+
52
+ Generated files overwrite by default, retaining originals in private state
53
+ for restoration. Existing matching resources are adopted rather than owned.
54
+ The committed `workstation.lock` records package versions per machine.
55
+
56
+ ## Documentation
57
+
58
+ - [Full usage guide](docs/README.md)
59
+ - [Tasks and aliases](docs/tasks.md)
60
+ - [Configuration and machines](docs/configuration.md)
61
+ - [Locks and recovery](docs/operations.md)
62
+
63
+ Run `corepack pnpm run docs` and open `dist/docs/index.html` for the generated
64
+ API reference and guides. `corepack pnpm check` and `corepack pnpm test` validate
65
+ the package without applying a workstation configuration.
66
+
67
+ ## Native binaries
68
+
69
+ GitHub Actions builds Linux and macOS executables for x64 and arm64. Download
70
+ the artifact for your platform from a successful build, extract it, and make
71
+ the executable available as `workstation` on PATH. Artifact archives may need
72
+ `chmod +x` after extraction. macOS builds are ad-hoc signed, not notarized.
73
+ The config's package import must still resolve in its project.
74
+
75
+ To build locally: `corepack pnpm build:native`. Outputs are under `dist/bin/`.