Skip to content

Commit a0e54f0

Browse files
committed
Move operating system operations under os namespace
1 parent b40556f commit a0e54f0

49 files changed

Lines changed: 2780 additions & 1503 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ Current categories:
195195
commands: local.command, remote.command
196196
filesystem: fs.*
197197
archive: archive.*
198-
packages: pkg.*
198+
packages: os.package.*
199199
systemd: systemctl.*
200200
users/groups: user.*, group.*
201201
processes: process.*

docs/TECHNICAL_DESIGN.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ Current builtins are grouped into these categories:
111111
commands: local.command, remote.command
112112
filesystem: fs.*
113113
archive: archive.*
114-
packages: pkg.*
114+
packages: os.package.*
115115
system: system.service.*, system.systemd.*, system.kernel.*, system.process.*, system.cron.*, system.journal.*, system.log.*
116116
identity: identity.user.*, identity.group.*
117117
transfer: transfer.*

docs/concepts/execution-model.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ A substep calls one plugin:
3939

4040
```yaml
4141
- id: install_nginx
42-
use: pkg.install
42+
use: os.package.install
4343
with:
4444
name: nginx
4545
sudo: true

docs/guides/creating-plugins.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ Good examples:
4242

4343
```text
4444
fs.file.template
45-
pkg.install
45+
os.package.install
4646
system.service.enable
4747
transfer.upload
4848
```

docs/guides/facts.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@ Automax gathers remote Linux facts for conditional workflows, reports and run di
2121
2222
Individual plugins are also available:
2323
24-
- `facts.os`
24+
- `os.facts`
2525
- `facts.network`
26-
- `facts.packages`
26+
- `os.package.facts`
2727
- `facts.services`
2828

2929
Package facts support Debian/Ubuntu through `dpkg-query` and Red Hat-like systems through `rpm`.

docs/guides/package-repositories.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Automax manages package repository keys and repository definitions for Debian/Ub
99

1010
```yaml
1111
- id: install_vendor_key
12-
use: pkg.key.add
12+
use: os.package.key.add
1313
with:
1414
name: vendor
1515
manager: apt
@@ -19,7 +19,7 @@ Automax manages package repository keys and repository definitions for Debian/Ub
1919
2020
```yaml
2121
- id: add_vendor_apt_repo
22-
use: pkg.repo.add
22+
use: os.package.repo.add
2323
with:
2424
name: vendor
2525
manager: apt
@@ -32,7 +32,7 @@ For RHEL-like systems, provide a `.repo` file body with `content` or `src` and `
3232

3333
```yaml
3434
- id: add_vendor_dnf_repo
35-
use: pkg.repo.add
35+
use: os.package.repo.add
3636
with:
3737
name: vendor
3838
manager: dnf

docs/plugins/alternatives.md

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,35 +3,36 @@ Copyright (C) 2026 Marco Fortina
33
SPDX-License-Identifier: AGPL-3.0-or-later
44
-->
55

6-
# Alternatives plugins
6+
# OS alternatives plugins
77

88
Use these plugins for Linux alternatives without hiding distro differences between
99
Debian-style `update-alternatives` and RHEL-style `alternatives`.
1010

1111
## Read-only inventory
1212

13-
`alternatives.list` returns the alternatives known on the target. On Debian-like
13+
`os.alternatives.list` returns the alternatives known on the target. On Debian-like
1414
systems it renders `update-alternatives --get-selections`; on RHEL-like systems it
1515
falls back to the alternatives state directories because the native tool is
1616
name-oriented.
1717

18-
`alternatives.get` reads one alternative name with `update-alternatives --query`
19-
or `alternatives --display`. It is read-only and is suitable for prechecks before
20-
changing a selected implementation.
18+
`os.alternatives.get` reads one alternative name with `update-alternatives --query`
19+
or `alternatives --display`. `os.alternatives.check` asserts that the selected
20+
implementation already points to the expected path.
2121

2222
## Mutating selection
2323

24-
`alternatives.set` selects the implementation path for one alternative name. Use
25-
`alternatives.get` first when a job needs to prove the current value before
24+
`os.alternatives.set` selects the implementation path for one alternative name. Use
25+
`os.alternatives.get` first when a job needs to prove the current value before
2626
changing it.
2727

2828
```yaml
29-
use: alternatives.get
29+
use: os.alternatives.check
3030
with:
3131
name: java
32+
path: /usr/lib/jvm/java-21/bin/java
3233

3334
---
34-
use: alternatives.set
35+
use: os.alternatives.set
3536
with:
3637
name: java
3738
path: /usr/lib/jvm/java-21/bin/java

docs/plugins/facts-cron.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ SPDX-License-Identifier: AGPL-3.0-or-later
88
## Facts
99

1010
Use `facts.gather` for a combined host snapshot, or the narrower read-only
11-
plugins `facts.os`, `facts.network`, `facts.packages` and `facts.services` when a
11+
plugins `os.facts`, `facts.network`, `os.package.facts` and `facts.services` when a
1212
job only needs one area. These plugins are precheck-friendly and do not change the
1313
target.
1414

0 commit comments

Comments
 (0)