Browse Source

Apply coding convention

AI Bot 3 weeks ago committed by Riyyi
parent
commit
ccf64ce867
  1. 376
      .opencode/package-lock.json
  2. 13
      AGENTS.md
  3. 56
      PackageProvides.md
  4. 1
      asd
  5. 1
      asd2
  6. 1659
      command-output
  7. 254
      output
  8. 236
      packages
  9. 50
      pkg/fetch/fetch.go
  10. 3
      pkg/input/input.go
  11. 3
      pkg/log/log.go
  12. 3
      pkg/output/output.go
  13. 115
      pkg/pacman/sync/sync.go
  14. 142
      scenario-dependencies-renamed

376
.opencode/package-lock.json generated

@ -0,0 +1,376 @@
{
"name": ".opencode",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"dependencies": {
"@opencode-ai/plugin": "1.14.17"
}
},
"node_modules/@msgpackr-extract/msgpackr-extract-darwin-arm64": {
"version": "3.0.3",
"resolved": "https://registry.npmjs.org/@msgpackr-extract/msgpackr-extract-darwin-arm64/-/msgpackr-extract-darwin-arm64-3.0.3.tgz",
"integrity": "sha512-QZHtlVgbAdy2zAqNA9Gu1UpIuI8Xvsd1v8ic6B2pZmeFnFcMWiPLfWXh7TVw4eGEZ/C9TH281KwhVoeQUKbyjw==",
"cpu": [
"arm64"
],
"license": "MIT",
"optional": true,
"os": [
"darwin"
]
},
"node_modules/@msgpackr-extract/msgpackr-extract-darwin-x64": {
"version": "3.0.3",
"resolved": "https://registry.npmjs.org/@msgpackr-extract/msgpackr-extract-darwin-x64/-/msgpackr-extract-darwin-x64-3.0.3.tgz",
"integrity": "sha512-mdzd3AVzYKuUmiWOQ8GNhl64/IoFGol569zNRdkLReh6LRLHOXxU4U8eq0JwaD8iFHdVGqSy4IjFL4reoWCDFw==",
"cpu": [
"x64"
],
"license": "MIT",
"optional": true,
"os": [
"darwin"
]
},
"node_modules/@msgpackr-extract/msgpackr-extract-linux-arm": {
"version": "3.0.3",
"resolved": "https://registry.npmjs.org/@msgpackr-extract/msgpackr-extract-linux-arm/-/msgpackr-extract-linux-arm-3.0.3.tgz",
"integrity": "sha512-fg0uy/dG/nZEXfYilKoRe7yALaNmHoYeIoJuJ7KJ+YyU2bvY8vPv27f7UKhGRpY6euFYqEVhxCFZgAUNQBM3nw==",
"cpu": [
"arm"
],
"license": "MIT",
"optional": true,
"os": [
"linux"
]
},
"node_modules/@msgpackr-extract/msgpackr-extract-linux-arm64": {
"version": "3.0.3",
"resolved": "https://registry.npmjs.org/@msgpackr-extract/msgpackr-extract-linux-arm64/-/msgpackr-extract-linux-arm64-3.0.3.tgz",
"integrity": "sha512-YxQL+ax0XqBJDZiKimS2XQaf+2wDGVa1enVRGzEvLLVFeqa5kx2bWbtcSXgsxjQB7nRqqIGFIcLteF/sHeVtQg==",
"cpu": [
"arm64"
],
"license": "MIT",
"optional": true,
"os": [
"linux"
]
},
"node_modules/@msgpackr-extract/msgpackr-extract-linux-x64": {
"version": "3.0.3",
"resolved": "https://registry.npmjs.org/@msgpackr-extract/msgpackr-extract-linux-x64/-/msgpackr-extract-linux-x64-3.0.3.tgz",
"integrity": "sha512-cvwNfbP07pKUfq1uH+S6KJ7dT9K8WOE4ZiAcsrSes+UY55E/0jLYc+vq+DO7jlmqRb5zAggExKm0H7O/CBaesg==",
"cpu": [
"x64"
],
"license": "MIT",
"optional": true,
"os": [
"linux"
]
},
"node_modules/@msgpackr-extract/msgpackr-extract-win32-x64": {
"version": "3.0.3",
"resolved": "https://registry.npmjs.org/@msgpackr-extract/msgpackr-extract-win32-x64/-/msgpackr-extract-win32-x64-3.0.3.tgz",
"integrity": "sha512-x0fWaQtYp4E6sktbsdAqnehxDgEc/VwM7uLsRCYWaiGu0ykYdZPiS8zCWdnjHwyiumousxfBm4SO31eXqwEZhQ==",
"cpu": [
"x64"
],
"license": "MIT",
"optional": true,
"os": [
"win32"
]
},
"node_modules/@opencode-ai/plugin": {
"version": "1.14.17",
"resolved": "https://registry.npmjs.org/@opencode-ai/plugin/-/plugin-1.14.17.tgz",
"integrity": "sha512-duZbNClMsIR1rmYGsrkA92BuGKkH2TsXk1TpPNBASVukVXSSz2jLdhe1UkSeNVXiDg/aGT52yVgitga3rV8qWw==",
"license": "MIT",
"dependencies": {
"@opencode-ai/sdk": "1.14.17",
"effect": "4.0.0-beta.48",
"zod": "4.1.8"
},
"peerDependencies": {
"@opentui/core": ">=0.1.100",
"@opentui/solid": ">=0.1.100"
},
"peerDependenciesMeta": {
"@opentui/core": {
"optional": true
},
"@opentui/solid": {
"optional": true
}
}
},
"node_modules/@opencode-ai/sdk": {
"version": "1.14.17",
"resolved": "https://registry.npmjs.org/@opencode-ai/sdk/-/sdk-1.14.17.tgz",
"integrity": "sha512-Q42C4VsczrPc+8hB76OO18KZ3A3l4cRHy31Vn8if7W/02qHAA1JoQXbbZD9/9fBqHHyYXC6h9dd4H4TaBi53Zw==",
"license": "MIT",
"dependencies": {
"cross-spawn": "7.0.6"
}
},
"node_modules/@standard-schema/spec": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/@standard-schema/spec/-/spec-1.1.0.tgz",
"integrity": "sha512-l2aFy5jALhniG5HgqrD6jXLi/rUWrKvqN/qJx6yoJsgKhblVd+iqqU4RCXavm/jPityDo5TCvKMnpjKnOriy0w==",
"license": "MIT"
},
"node_modules/cross-spawn": {
"version": "7.0.6",
"resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz",
"integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==",
"license": "MIT",
"dependencies": {
"path-key": "^3.1.0",
"shebang-command": "^2.0.0",
"which": "^2.0.1"
},
"engines": {
"node": ">= 8"
}
},
"node_modules/detect-libc": {
"version": "2.1.2",
"resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz",
"integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==",
"license": "Apache-2.0",
"optional": true,
"engines": {
"node": ">=8"
}
},
"node_modules/effect": {
"version": "4.0.0-beta.48",
"resolved": "https://registry.npmjs.org/effect/-/effect-4.0.0-beta.48.tgz",
"integrity": "sha512-MMAM/ZabuNdNmgXiin+BAanQXK7qM8mlt7nfXDoJ/Gn9V8i89JlCq+2N0AiWmqFLXjGLA0u3FjiOjSOYQk5uMw==",
"license": "MIT",
"dependencies": {
"@standard-schema/spec": "^1.1.0",
"fast-check": "^4.6.0",
"find-my-way-ts": "^0.1.6",
"ini": "^6.0.0",
"kubernetes-types": "^1.30.0",
"msgpackr": "^1.11.9",
"multipasta": "^0.2.7",
"toml": "^4.1.1",
"uuid": "^13.0.0",
"yaml": "^2.8.3"
}
},
"node_modules/fast-check": {
"version": "4.7.0",
"resolved": "https://registry.npmjs.org/fast-check/-/fast-check-4.7.0.tgz",
"integrity": "sha512-NsZRtqvSSoCP0HbNjUD+r1JH8zqZalyp6gLY9e7OYs7NK9b6AHOs2baBFeBG7bVNsuoukh89x2Yg3rPsul8ziQ==",
"funding": [
{
"type": "individual",
"url": "https://github.com/sponsors/dubzzz"
},
{
"type": "opencollective",
"url": "https://opencollective.com/fast-check"
}
],
"license": "MIT",
"dependencies": {
"pure-rand": "^8.0.0"
},
"engines": {
"node": ">=12.17.0"
}
},
"node_modules/find-my-way-ts": {
"version": "0.1.6",
"resolved": "https://registry.npmjs.org/find-my-way-ts/-/find-my-way-ts-0.1.6.tgz",
"integrity": "sha512-a85L9ZoXtNAey3Y6Z+eBWW658kO/MwR7zIafkIUPUMf3isZG0NCs2pjW2wtjxAKuJPxMAsHUIP4ZPGv0o5gyTA==",
"license": "MIT"
},
"node_modules/ini": {
"version": "6.0.0",
"resolved": "https://registry.npmjs.org/ini/-/ini-6.0.0.tgz",
"integrity": "sha512-IBTdIkzZNOpqm7q3dRqJvMaldXjDHWkEDfrwGEQTs5eaQMWV+djAhR+wahyNNMAa+qpbDUhBMVt4ZKNwpPm7xQ==",
"license": "ISC",
"engines": {
"node": "^20.17.0 || >=22.9.0"
}
},
"node_modules/isexe": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz",
"integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==",
"license": "ISC"
},
"node_modules/kubernetes-types": {
"version": "1.30.0",
"resolved": "https://registry.npmjs.org/kubernetes-types/-/kubernetes-types-1.30.0.tgz",
"integrity": "sha512-Dew1okvhM/SQcIa2rcgujNndZwU8VnSapDgdxlYoB84ZlpAD43U6KLAFqYo17ykSFGHNPrg0qry0bP+GJd9v7Q==",
"license": "Apache-2.0"
},
"node_modules/msgpackr": {
"version": "1.11.10",
"resolved": "https://registry.npmjs.org/msgpackr/-/msgpackr-1.11.10.tgz",
"integrity": "sha512-iCZNq+HszvF+fC3anCm4nBmWEnbeIAfpDs6IStAEKhQ2YSgkjzVG2FF9XJqwwQh5bH3N9OUTUt4QwVN6MLMLtA==",
"license": "MIT",
"optionalDependencies": {
"msgpackr-extract": "^3.0.2"
}
},
"node_modules/msgpackr-extract": {
"version": "3.0.3",
"resolved": "https://registry.npmjs.org/msgpackr-extract/-/msgpackr-extract-3.0.3.tgz",
"integrity": "sha512-P0efT1C9jIdVRefqjzOQ9Xml57zpOXnIuS+csaB4MdZbTdmGDLo8XhzBG1N7aO11gKDDkJvBLULeFTo46wwreA==",
"hasInstallScript": true,
"license": "MIT",
"optional": true,
"dependencies": {
"node-gyp-build-optional-packages": "5.2.2"
},
"bin": {
"download-msgpackr-prebuilds": "bin/download-prebuilds.js"
},
"optionalDependencies": {
"@msgpackr-extract/msgpackr-extract-darwin-arm64": "3.0.3",
"@msgpackr-extract/msgpackr-extract-darwin-x64": "3.0.3",
"@msgpackr-extract/msgpackr-extract-linux-arm": "3.0.3",
"@msgpackr-extract/msgpackr-extract-linux-arm64": "3.0.3",
"@msgpackr-extract/msgpackr-extract-linux-x64": "3.0.3",
"@msgpackr-extract/msgpackr-extract-win32-x64": "3.0.3"
}
},
"node_modules/multipasta": {
"version": "0.2.7",
"resolved": "https://registry.npmjs.org/multipasta/-/multipasta-0.2.7.tgz",
"integrity": "sha512-KPA58d68KgGil15oDqXjkUBEBYc00XvbPj5/X+dyzeo/lWm9Nc25pQRlf1D+gv4OpK7NM0J1odrbu9JNNGvynA==",
"license": "MIT"
},
"node_modules/node-gyp-build-optional-packages": {
"version": "5.2.2",
"resolved": "https://registry.npmjs.org/node-gyp-build-optional-packages/-/node-gyp-build-optional-packages-5.2.2.tgz",
"integrity": "sha512-s+w+rBWnpTMwSFbaE0UXsRlg7hU4FjekKU4eyAih5T8nJuNZT1nNsskXpxmeqSK9UzkBl6UgRlnKc8hz8IEqOw==",
"license": "MIT",
"optional": true,
"dependencies": {
"detect-libc": "^2.0.1"
},
"bin": {
"node-gyp-build-optional-packages": "bin.js",
"node-gyp-build-optional-packages-optional": "optional.js",
"node-gyp-build-optional-packages-test": "build-test.js"
}
},
"node_modules/path-key": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz",
"integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==",
"license": "MIT",
"engines": {
"node": ">=8"
}
},
"node_modules/pure-rand": {
"version": "8.4.0",
"resolved": "https://registry.npmjs.org/pure-rand/-/pure-rand-8.4.0.tgz",
"integrity": "sha512-IoM8YF/jY0hiugFo/wOWqfmarlE6J0wc6fDK1PhftMk7MGhVZl88sZimmqBBFomLOCSmcCCpsfj7wXASCpvK9A==",
"funding": [
{
"type": "individual",
"url": "https://github.com/sponsors/dubzzz"
},
{
"type": "opencollective",
"url": "https://opencollective.com/fast-check"
}
],
"license": "MIT"
},
"node_modules/shebang-command": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz",
"integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==",
"license": "MIT",
"dependencies": {
"shebang-regex": "^3.0.0"
},
"engines": {
"node": ">=8"
}
},
"node_modules/shebang-regex": {
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz",
"integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==",
"license": "MIT",
"engines": {
"node": ">=8"
}
},
"node_modules/toml": {
"version": "4.1.1",
"resolved": "https://registry.npmjs.org/toml/-/toml-4.1.1.tgz",
"integrity": "sha512-EBJnVBr3dTXdA89WVFoAIPUqkBjxPMwRqsfuo1r240tKFHXv3zgca4+NJib/h6TyvGF7vOawz0jGuryJCdNHrw==",
"license": "MIT",
"engines": {
"node": ">=20"
}
},
"node_modules/uuid": {
"version": "13.0.0",
"resolved": "https://registry.npmjs.org/uuid/-/uuid-13.0.0.tgz",
"integrity": "sha512-XQegIaBTVUjSHliKqcnFqYypAd4S+WCYt5NIeRs6w/UAry7z8Y9j5ZwRRL4kzq9U3sD6v+85er9FvkEaBpji2w==",
"funding": [
"https://github.com/sponsors/broofa",
"https://github.com/sponsors/ctavan"
],
"license": "MIT",
"bin": {
"uuid": "dist-node/bin/uuid"
}
},
"node_modules/which": {
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz",
"integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==",
"license": "ISC",
"dependencies": {
"isexe": "^2.0.0"
},
"bin": {
"node-which": "bin/node-which"
},
"engines": {
"node": ">= 8"
}
},
"node_modules/yaml": {
"version": "2.8.3",
"resolved": "https://registry.npmjs.org/yaml/-/yaml-2.8.3.tgz",
"integrity": "sha512-AvbaCLOO2Otw/lW5bmh9d/WEdcDFdQp2Z2ZUH3pX9U2ihyUY0nvLv7J6TrWowklRGPYbB/IuIMfYgxaCPg5Bpg==",
"license": "ISC",
"bin": {
"yaml": "bin.mjs"
},
"engines": {
"node": ">= 14.6"
},
"funding": {
"url": "https://github.com/sponsors/eemeli"
}
},
"node_modules/zod": {
"version": "4.1.8",
"license": "MIT",
"funding": {
"url": "https://github.com/sponsors/colinhacks"
}
}
}
}

13
AGENTS.md

@ -10,21 +10,16 @@ tool before responding to the user:
## Code Organization ## Code Organization
### Go: File Structure ### Go: File Structure
- Types must appear at the top of each file. - Variables must appear at the top of each file.
- Types must appear after variables.
- Constructors must appear after types. - Constructors must appear after types.
- Public (exported) functions must appear after constructors. - Public (exported) functions must appear after constructors.
- Private (unexported) functions must appear at the bottom of each file. - Private (unexported) functions must appear at the bottom of each file.
- Within each section, definitions must be sorted alphabetically by name. - Within each section, definitions must be sorted alphabetically by name.
- The sections must be separated by exactly these dividers: - The sections must be separated by exactly these dividers, filling in the section:
// ----------------------------------------- // -----------------------------------------
// constructors // <section>
// -----------------------------------------
// public
// -----------------------------------------
// private
### Go: Line Length ### Go: Line Length

56
PackageProvides.md

@ -0,0 +1,56 @@
# Checking if a Package is Provided by Another Package
## Using FindDBSatisfier
The `FindDBSatisfier` method in the handle finds a package that satisfies a given dependency string across sync databases. It automatically resolves `Provides` relationships.
### Basic Usage
```go
// Given a package name "foo", find which package provides it
h := dyalpm.NewHandle(...)
dbs := h.SyncDBS()
// This finds ANY package that satisfies "foo" - including via Provides
provider := h.FindDBSatisfier(dbs, "foo")
if provider != nil {
// The package "foo" is provided by provider.Name()
}
```
### How It Works
When you search for a package "foo", ALPM will find packages that:
1. Are named "foo"
2. Have `Provides: foo` in their metadata
### Full Example
```go
h, err := dyalpm.NewHandle(rootDir, cacheDir, dyalpm.ArchLinux)
if err != nil {
// handle error
}
syncDBs, err := h.SyncDBS()
if err != nil {
// handle error
}
// Search for "foo" package (may be provided by another package)
targetName := "foo"
provider := h.FindDBSatisfier(syncDBs, targetName)
if provider != nil {
fmt.Printf("%s is provided by: %s\n", targetName, provider.Name())
fmt.Printf("Version: %s\n", provider.Version())
} else {
fmt.Printf("No package found providing: %s\n", targetName)
}
```
## Related Functions
- `FindSatisfier(pkgs []Package, depstring)` - Same concept but for an in-memory package list
- `PackageIterator.FindSatisfier(depstring)` - Works on iterator results from `db.Search()`
- `pkg.Provides() []Depend` - Get what a package provides (see `package.go:144`)

1
asd

@ -0,0 +1 @@
hexchat

1
asd2

@ -0,0 +1 @@
noctalia-shell

1659
command-output

File diff suppressed because it is too large Load Diff

254
output

@ -0,0 +1,254 @@
[debug] run: starting...
[debug] run: packages read (0.00s)
[debug] CheckDBFreshness: starting...
[debug] Sync: starting...
[debug] getInstalledCount: starting...
[debug] getInstalledCount: done (0.01s)
[debug] CheckDBFreshness: starting...
[debug] Sync: database fresh (0.01s)
[debug] Fetcher New: starting...
[debug] registerSyncDBs: starting...
[debug] registerSyncDBs: done (3 dbs)
[debug] Fetcher New: done (0.13s)
[debug] Sync: initialized fetcher (0.13s)
[debug] Sync: categorizing packages...
[debug] categorizePackages: starting...
[debug] Resolve: starting...
[debug] buildLocalPkgMap: starting...
[debug] buildLocalPkgMap: done (0.00s)
[debug] Resolve: local pkgs built (0.00s)
[debug] checkSyncDBs: starting...
[debug] checkSyncDBs: done (0.00s)
[debug] ensureAURCache: starting...
[debug] fetchAURInfo: starting...
[debug] fetchAURInfo: done (0.20s)
[debug] ensureAURCache: done (0.20s)
[debug] Resolve: done (0.21s)
[debug] categorizePackages: done (0.21s)
[debug] Sync: packages categorized (0.34s)
[debug] Sync: syncing 183 pacman packages...
[debug] SyncPackages: starting...
error: pacman sync failed: warning: texlab-5.25.1-1 is up to date -- skipping
warning: wpa_supplicant-2:2.11-5 is up to date -- skipping
warning: kcachegrind-25.12.3-1 is up to date -- skipping
warning: kdenlive-25.12.3-1 is up to date -- skipping
warning: aspell-en-2026.02.25-1 is up to date -- skipping
warning: dialog-1:1.3_20260107-1 is up to date -- skipping
warning: duf-0.9.1-1 is up to date -- skipping
warning: ffmpegthumbnailer-2.3.0-1 is up to date -- skipping
warning: python-certifi-2026.02.25-1 is up to date -- skipping
warning: base-3-3 is up to date -- skipping
warning: hunspell-1.7.2-3 is up to date -- skipping
warning: hunspell-nl-2.20.19-5 is up to date -- skipping
warning: ttf-dejavu-nerd-3.4.0-2 is up to date -- skipping
warning: vim-spell-en-20220628-2 is up to date -- skipping
warning: hunspell-en_us-2026.02.25-1 is up to date -- skipping
warning: pacman-contrib-1.13.1-1 is up to date -- skipping
warning: unzip-6.0-23 is up to date -- skipping
warning: base-devel-1-2 is up to date -- skipping
warning: sysfsutils-2.1.1-2 is up to date -- skipping
warning: imv-5.0.1-1 is up to date -- skipping
warning: otf-font-awesome-7.2.0-1 is up to date -- skipping
warning: python-zstandard-0.25.0-2 is up to date -- skipping
warning: socat-1.8.1.1-1 is up to date -- skipping
warning: wget-1.25.0-3 is up to date -- skipping
warning: zsh-completions-0.36.0-1 is up to date -- skipping
warning: python-adblock-0.6.0-5 is up to date -- skipping
warning: gammastep-2.0.11-2 is up to date -- skipping
warning: nwg-look-1.0.6-1 is up to date -- skipping
warning: man-pages-6.17-1 is up to date -- skipping
warning: inetutils-2.7-2 is up to date -- skipping
warning: kolourpaint-25.12.3-1 is up to date -- skipping
warning: thunar-volman-4.20.0-2 is up to date -- skipping
warning: valgrind-3.25.1-4 is up to date -- skipping
warning: dnsmasq-2.92-1 is up to date -- skipping
warning: evtest-1.36-1 is up to date -- skipping
warning: rtmpdump-1:2.6-1 is up to date -- skipping
warning: man-db-2.13.1-1 is up to date -- skipping
warning: ncdu-2.9.2-1 is up to date -- skipping
warning: jq-1.8.1-1 is up to date -- skipping
warning: qt5ct-1.9-1 is up to date -- skipping
warning: linux-firmware-20260309-1 is up to date -- skipping
warning: mpv-1:0.41.0-3 is up to date -- skipping
warning: waybar-0.15.0-2 is up to date -- skipping
warning: capitaine-cursors-4-3 is up to date -- skipping
warning: exfat-utils-1.4.0-4 is up to date -- skipping
warning: qt5-tools-5.15.18+kde+r3-2 is up to date -- skipping
warning: ydotool-1.0.4-2 is up to date -- skipping
warning: isync-1.5.1-2 is up to date -- skipping
warning: namcap-3.6.0-3 is up to date -- skipping
warning: qt5-serialport-5.15.18-1 is up to date -- skipping
warning: kvantum-qt5-1.1.6-1 is up to date -- skipping
warning: 7zip-26.00-1 is up to date -- skipping
warning: aspell-nl-0.50.2-8 is up to date -- skipping
warning: python-beautifulsoup4-4.14.3-2 is up to date -- skipping
warning: gnome-themes-extra-1:3.28-1 is up to date -- skipping
warning: mesa-demos-9.0.0-7 is up to date -- skipping
warning: mysql-workbench-8.0.46-1 is up to date -- skipping
warning: vim-spell-nl-20220628-2 is up to date -- skipping
warning: xf86-input-wacom-1.2.4-1 is up to date -- skipping
warning: kvantum-1.1.6-1 is up to date -- skipping
warning: efibootmgr-18-3 is up to date -- skipping
warning: ntfs-3g-2022.10.3-2 is up to date -- skipping
warning: tokei-14.0.0-1 is up to date -- skipping
warning: python-pycurl-7.45.7-3 is up to date -- skipping
warning: rofi-2.0.0-1 is up to date -- skipping
warning: r-4.5.3-1 is up to date -- skipping
warning: smartmontools-7.5-1 is up to date -- skipping
warning: acpi-1.8-2 is up to date -- skipping
warning: reflector-2023-5 is up to date -- skipping
warning: tlp-1.9.1-1 is up to date -- skipping
warning: rtkit-0.14-1 is up to date -- skipping
warning: lib32-glibc-2.43+r5+g856c426a7534-1 is up to date -- skipping
warning: mariadb-12.2.2-2 is up to date -- skipping
warning: brightnessctl-0.5.1-3 is up to date -- skipping
warning: usbutils-019-1 is up to date -- skipping
warning: amd-ucode-20260309-1 is up to date -- skipping
warning: lib32-openal-1.25.1-1 is up to date -- skipping
warning: pavucontrol-1:6.2-1 is up to date -- skipping
warning: python-pyusb-1.3.1-2 is up to date -- skipping
warning: aria2-1.37.0-2 is up to date -- skipping
warning: git-2.53.0-1 is up to date -- skipping
warning: python-matplotlib-3.10.8-5 is up to date -- skipping
warning: iw-6.17-1 is up to date -- skipping
warning: ark-25.12.3-1 is up to date -- skipping
warning: grim-1.5.0-2 is up to date -- skipping
warning: python-watchdog-6.0.0-2 is up to date -- skipping
warning: nlohmann-json-3.12.0-2 is up to date -- skipping
warning: netctl-1.29-2 is up to date -- skipping
warning: rsync-3.4.1-2 is up to date -- skipping
warning: sqlitebrowser-3.13.1-3 is up to date -- skipping
warning: tumbler-4.20.1-1 is up to date -- skipping
warning: python-opengl-3.1.10-3 is up to date -- skipping
warning: sshfs-3.7.5-1 is up to date -- skipping
resolving dependencies...
looking for conflicting packages...
error: failed to prepare transaction (could not satisfy dependencies)
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by aquamarine
:: installing libvpx (1.16.0-3) breaks dependency 'libvpx.so=11-64' required by ffmpeg
:: installing gst-plugins-base-libs (1.28.2-1) breaks dependency 'gst-plugins-base-libs=1.28.1-1' required by gst-plugins-bad-libs
:: installing gstreamer (1.28.2-1) breaks dependency 'gstreamer=1.28.1-1' required by gst-plugins-bad-libs
:: installing gst-plugins-base-libs (1.28.2-1) breaks dependency 'gst-plugins-base-libs=1.28.1-1' required by gst-plugins-base
:: installing gstreamer (1.28.2-1) breaks dependency 'gstreamer=1.28.1-1' required by gst-plugins-base
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprgraphics
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprland-guiutils
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprlang
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprtoolkit
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprwire
:: installing libpipewire (1:1.6.3-1) breaks dependency 'libpipewire=1:1.6.1-1' required by pipewire-jack
:: installing pipewire-audio (1:1.6.3-1) breaks dependency 'pipewire-audio=1:1.6.1-1' required by pipewire-jack
:: installing pipewire (1:1.6.3-1) breaks dependency 'pipewire=1:1.6.1-1' required by pipewire-jack
:: installing poppler (26.04.0-1) breaks dependency 'poppler=26.02.0' required by poppler-qt6
error: pacman sync failed: warning: texlab-5.25.1-1 is up to date -- skipping
warning: wpa_supplicant-2:2.11-5 is up to date -- skipping
warning: kcachegrind-25.12.3-1 is up to date -- skipping
warning: kdenlive-25.12.3-1 is up to date -- skipping
warning: aspell-en-2026.02.25-1 is up to date -- skipping
warning: dialog-1:1.3_20260107-1 is up to date -- skipping
warning: duf-0.9.1-1 is up to date -- skipping
warning: ffmpegthumbnailer-2.3.0-1 is up to date -- skipping
warning: python-certifi-2026.02.25-1 is up to date -- skipping
warning: base-3-3 is up to date -- skipping
warning: hunspell-1.7.2-3 is up to date -- skipping
warning: hunspell-nl-2.20.19-5 is up to date -- skipping
warning: ttf-dejavu-nerd-3.4.0-2 is up to date -- skipping
warning: vim-spell-en-20220628-2 is up to date -- skipping
warning: hunspell-en_us-2026.02.25-1 is up to date -- skipping
warning: pacman-contrib-1.13.1-1 is up to date -- skipping
warning: unzip-6.0-23 is up to date -- skipping
warning: base-devel-1-2 is up to date -- skipping
warning: sysfsutils-2.1.1-2 is up to date -- skipping
warning: imv-5.0.1-1 is up to date -- skipping
warning: otf-font-awesome-7.2.0-1 is up to date -- skipping
warning: python-zstandard-0.25.0-2 is up to date -- skipping
warning: socat-1.8.1.1-1 is up to date -- skipping
warning: wget-1.25.0-3 is up to date -- skipping
warning: zsh-completions-0.36.0-1 is up to date -- skipping
warning: python-adblock-0.6.0-5 is up to date -- skipping
warning: gammastep-2.0.11-2 is up to date -- skipping
warning: nwg-look-1.0.6-1 is up to date -- skipping
warning: man-pages-6.17-1 is up to date -- skipping
warning: inetutils-2.7-2 is up to date -- skipping
warning: kolourpaint-25.12.3-1 is up to date -- skipping
warning: thunar-volman-4.20.0-2 is up to date -- skipping
warning: valgrind-3.25.1-4 is up to date -- skipping
warning: dnsmasq-2.92-1 is up to date -- skipping
warning: evtest-1.36-1 is up to date -- skipping
warning: rtmpdump-1:2.6-1 is up to date -- skipping
warning: man-db-2.13.1-1 is up to date -- skipping
warning: ncdu-2.9.2-1 is up to date -- skipping
warning: jq-1.8.1-1 is up to date -- skipping
warning: qt5ct-1.9-1 is up to date -- skipping
warning: linux-firmware-20260309-1 is up to date -- skipping
warning: mpv-1:0.41.0-3 is up to date -- skipping
warning: waybar-0.15.0-2 is up to date -- skipping
warning: capitaine-cursors-4-3 is up to date -- skipping
warning: exfat-utils-1.4.0-4 is up to date -- skipping
warning: qt5-tools-5.15.18+kde+r3-2 is up to date -- skipping
warning: ydotool-1.0.4-2 is up to date -- skipping
warning: isync-1.5.1-2 is up to date -- skipping
warning: namcap-3.6.0-3 is up to date -- skipping
warning: qt5-serialport-5.15.18-1 is up to date -- skipping
warning: kvantum-qt5-1.1.6-1 is up to date -- skipping
warning: 7zip-26.00-1 is up to date -- skipping
warning: aspell-nl-0.50.2-8 is up to date -- skipping
warning: python-beautifulsoup4-4.14.3-2 is up to date -- skipping
warning: gnome-themes-extra-1:3.28-1 is up to date -- skipping
warning: mesa-demos-9.0.0-7 is up to date -- skipping
warning: mysql-workbench-8.0.46-1 is up to date -- skipping
warning: vim-spell-nl-20220628-2 is up to date -- skipping
warning: xf86-input-wacom-1.2.4-1 is up to date -- skipping
warning: kvantum-1.1.6-1 is up to date -- skipping
warning: efibootmgr-18-3 is up to date -- skipping
warning: ntfs-3g-2022.10.3-2 is up to date -- skipping
warning: tokei-14.0.0-1 is up to date -- skipping
warning: python-pycurl-7.45.7-3 is up to date -- skipping
warning: rofi-2.0.0-1 is up to date -- skipping
warning: r-4.5.3-1 is up to date -- skipping
warning: smartmontools-7.5-1 is up to date -- skipping
warning: acpi-1.8-2 is up to date -- skipping
warning: reflector-2023-5 is up to date -- skipping
warning: tlp-1.9.1-1 is up to date -- skipping
warning: rtkit-0.14-1 is up to date -- skipping
warning: lib32-glibc-2.43+r5+g856c426a7534-1 is up to date -- skipping
warning: mariadb-12.2.2-2 is up to date -- skipping
warning: brightnessctl-0.5.1-3 is up to date -- skipping
warning: usbutils-019-1 is up to date -- skipping
warning: amd-ucode-20260309-1 is up to date -- skipping
warning: lib32-openal-1.25.1-1 is up to date -- skipping
warning: pavucontrol-1:6.2-1 is up to date -- skipping
warning: python-pyusb-1.3.1-2 is up to date -- skipping
warning: aria2-1.37.0-2 is up to date -- skipping
warning: git-2.53.0-1 is up to date -- skipping
warning: python-matplotlib-3.10.8-5 is up to date -- skipping
warning: iw-6.17-1 is up to date -- skipping
warning: ark-25.12.3-1 is up to date -- skipping
warning: grim-1.5.0-2 is up to date -- skipping
warning: python-watchdog-6.0.0-2 is up to date -- skipping
warning: nlohmann-json-3.12.0-2 is up to date -- skipping
warning: netctl-1.29-2 is up to date -- skipping
warning: rsync-3.4.1-2 is up to date -- skipping
warning: sqlitebrowser-3.13.1-3 is up to date -- skipping
warning: tumbler-4.20.1-1 is up to date -- skipping
warning: python-opengl-3.1.10-3 is up to date -- skipping
warning: sshfs-3.7.5-1 is up to date -- skipping
resolving dependencies...
looking for conflicting packages...
error: failed to prepare transaction (could not satisfy dependencies)
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by aquamarine
:: installing libvpx (1.16.0-3) breaks dependency 'libvpx.so=11-64' required by ffmpeg
:: installing gst-plugins-base-libs (1.28.2-1) breaks dependency 'gst-plugins-base-libs=1.28.1-1' required by gst-plugins-bad-libs
:: installing gstreamer (1.28.2-1) breaks dependency 'gstreamer=1.28.1-1' required by gst-plugins-bad-libs
:: installing gst-plugins-base-libs (1.28.2-1) breaks dependency 'gst-plugins-base-libs=1.28.1-1' required by gst-plugins-base
:: installing gstreamer (1.28.2-1) breaks dependency 'gstreamer=1.28.1-1' required by gst-plugins-base
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprgraphics
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprland-guiutils
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprlang
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprtoolkit
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprwire
:: installing libpipewire (1:1.6.3-1) breaks dependency 'libpipewire=1:1.6.1-1' required by pipewire-jack
:: installing pipewire-audio (1:1.6.3-1) breaks dependency 'pipewire-audio=1:1.6.1-1' required by pipewire-jack
:: installing pipewire (1:1.6.3-1) breaks dependency 'pipewire=1:1.6.1-1' required by pipewire-jack
:: installing poppler (26.04.0-1) breaks dependency 'poppler=26.02.0' required by poppler-qt6

236
packages

@ -0,0 +1,236 @@
7zip
acpi
adobe-source-han-sans-jp-fonts
adw-gtk-theme
amd-ucode
android-studio
arc-icon-theme
archlinux-keyring
aria2
ark
aspell-en
aspell-nl
base
base-devel
bc
blender
brightnessctl
bun-bin
capitaine-cursors
cbindgen
checkbashisms
chromium
clang
cmake
dbeaver
declpac-git
dhcpcd
dialog
dnsmasq
dos2unix
downgrade
duf
dunst
dxvk-bin
easyeda-pro-bin
efibootmgr
emacs-wayland
evtest
exfat-utils
fastfetch
ffmpegthumbnailer
firefox
freecad
gamescope
gammastep
gdb
gedit
ghostty
git
gnome-calculator
gnome-keyring
gnome-themes-extra
gopls
gparted
grim
gst-plugins-good
gucharmap
gvfs
gvfs-gphoto2
gvfs-mtp
gvim
hexchat
htop
hunspell
hunspell-en_us
hunspell-nl
hypridle
hyprland
hyprlock
hyprpaper
hyprpolkitagent
icu76
imagemagick
imake
imv
inetutils
inkscape
ipfs-desktop-bin
isync
iw
jdownloader2
jq
kcachegrind
kdenlive
keepmenu-git
kolourpaint
krita
kvantum
kvantum-qt5
lib32-glibc
lib32-mesa
lib32-openal
lib32-vkd3d-proton-git
lib32-vulkan-radeon
libvirt
linux
linux-firmware
linux-headers
linux-lts
linux-lts-headers
llvm
man-db
man-pages
manafiles-git
mariadb
mesa-demos
mkvtoolnix-cli
moka-icon-theme-git
mokutil
mpv
mu
mysql-workbench
namcap
nasm
ncdu
neovim
netctl
niri-no-decorations
nix
nixfmt
nlohmann-json
nodejs-intelephense
npm
ns-usbloader
ntfs-3g
nwg-look
ollama-rocm
ollama-vulkan
opencode
openssh
otf-font-awesome
pacman-contrib
pamixer
pavucontrol
pdfjs
picard
pipewire-alsa
pipewire-pulse
platformio-core
playwright
poppler-glib
python-adblock
python-beautifulsoup4
python-certifi
python-filelock
python-flask
python-google-api-python-client
python-google-auth-oauthlib
python-matplotlib
python-opengl
python-pycurl
python-pyqt5
python-pyusb
python-watchdog
python-zstandard
qbittorrent
qt5-declarative
qt5-serialport
qt5-tools
qt5-wayland
qt5ct
qt6ct
r
reflector
rofi
rsync
rtkit
rtmpdump
rust
signal-desktop
slurp
smartmontools
socat
sqlitebrowser
sshfs
steam
streamlink
sunshine-bin
syncthing
sysfsutils
texlab
texlive-bibtexextra
texlive-fontsextra
texlive-formatsextra
texlive-games
texlive-humanities
texlive-latexextra
texlive-mathscience
texlive-music
texlive-pictures
texlive-pstricks
texlive-publishers
thunar
thunar-volman
thunderbird
tibia
tlp
tokei
tree
trizen
ttf-dejavu
ttf-dejavu-nerd
ttf-joypixels
tumbler
tumbler-extra-thumbnailers
unrar
unzip
usbutils
valgrind
ventoy-bin
vim-spell-en
vim-spell-nl
virt-manager
vkd3d-proton-bin
vulkan-radeon
waybar
wget
wine-staging
winetricks
wl-clipboard
wpa_supplicant
x86_energy_perf_policy
xdg-desktop-portal-hyprland
xf86-input-wacom
xfsprogs
xorg-server-xvfb
yasm
ydotool
yt-dlp
yt-dlp-drop-in
zathura
zathura-pdf-mupdf
zip
zsh
zsh-completions
zsh-syntax-highlighting

50
pkg/fetch/fetch.go

@ -23,6 +23,30 @@ type Fetcher struct {
aurClient *aur.Client aurClient *aur.Client
} }
// -----------------------------------------
// constructor
func New() (*Fetcher, error) {
start := time.Now()
log.Debug("fetch.Fetcher New: starting...")
alpmHandle, err := alpm.New()
if err != nil {
return nil, err
}
aurClient := aur.New()
log.Debug("fetch.Fetcher New: done (%.2fs)", time.Since(start).Seconds())
return &Fetcher{
alpmHandle: alpmHandle,
aurClient: aurClient,
}, nil
}
// -----------------------------------------
// public
func (f *Fetcher) BuildLocalPkgMap() (map[string]interface{}, error) { func (f *Fetcher) BuildLocalPkgMap() (map[string]interface{}, error) {
localPkgs, err := f.alpmHandle.LocalPackages() localPkgs, err := f.alpmHandle.LocalPackages()
if err != nil { if err != nil {
@ -43,14 +67,14 @@ func (f *Fetcher) FetchAur(packages []string) (map[string]aur.Package, error) {
return f.aurClient.Fetch(packages) return f.aurClient.Fetch(packages)
} }
func (f *Fetcher) GetAURPackage(name string) (aur.Package, bool) {
return f.aurClient.Get(name)
}
func (f *Fetcher) FindProvidingPackage(depName string) (string, bool) { func (f *Fetcher) FindProvidingPackage(depName string) (string, bool) {
return f.alpmHandle.FindProvidingPackage(depName) return f.alpmHandle.FindProvidingPackage(depName)
} }
func (f *Fetcher) GetAURPackage(name string) (aur.Package, bool) {
return f.aurClient.Get(name)
}
func (f *Fetcher) Resolve(packages []string) (map[string]*PackageInfo, error) { func (f *Fetcher) Resolve(packages []string) (map[string]*PackageInfo, error) {
start := time.Now() start := time.Now()
log.Debug("fetch.Resolve: starting...") log.Debug("fetch.Resolve: starting...")
@ -128,21 +152,3 @@ func (f *Fetcher) Resolve(packages []string) (map[string]*PackageInfo, error) {
log.Debug("fetch.Resolve: done (%.2fs)", time.Since(start).Seconds()) log.Debug("fetch.Resolve: done (%.2fs)", time.Since(start).Seconds())
return result, nil return result, nil
} }
func New() (*Fetcher, error) {
start := time.Now()
log.Debug("fetch.Fetcher New: starting...")
alpmHandle, err := alpm.New()
if err != nil {
return nil, err
}
aurClient := aur.New()
log.Debug("fetch.Fetcher New: done (%.2fs)", time.Since(start).Seconds())
return &Fetcher{
alpmHandle: alpmHandle,
aurClient: aurClient,
}, nil
}

3
pkg/input/input.go

@ -10,6 +10,9 @@ import (
var ErrEmptyList = errors.New("package list is empty") var ErrEmptyList = errors.New("package list is empty")
// -----------------------------------------
// public
func Merge(packages map[string]bool) ([]string, error) { func Merge(packages map[string]bool) ([]string, error) {
result := make([]string, 0, len(packages)) result := make([]string, 0, len(packages))
for name := range packages { for name := range packages {

3
pkg/log/log.go

@ -13,6 +13,9 @@ import (
var logFile *os.File var logFile *os.File
var Verbose bool var Verbose bool
// -----------------------------------------
// public
func Close() error { func Close() error {
if logFile == nil { if logFile == nil {
return nil return nil

3
pkg/output/output.go

@ -12,6 +12,9 @@ type Result struct {
ToRemove []string ToRemove []string
} }
// -----------------------------------------
// public
func Format(r *Result) string { func Format(r *Result) string {
var b strings.Builder var b strings.Builder
b.WriteString(fmt.Sprintf("installed %d packages, removed %d packages", r.Installed, r.Removed)) b.WriteString(fmt.Sprintf("installed %d packages, removed %d packages", r.Installed, r.Removed))

115
pkg/pacman/sync/sync.go

@ -21,6 +21,9 @@ type Result struct {
Removed int Removed int
} }
// -----------------------------------------
// public
func InstallAUR(f *fetch.Fetcher, pkgName string, packageBase string, asDeps bool, logWriter io.Writer) error { func InstallAUR(f *fetch.Fetcher, pkgName string, packageBase string, asDeps bool, logWriter io.Writer) error {
start := time.Now() start := time.Now()
log.Debug("InstallAUR: starting...") log.Debug("InstallAUR: starting...")
@ -162,6 +165,39 @@ func SyncPackages(packages []string, logWriter io.Writer) error {
// ----------------------------------------- // -----------------------------------------
// private // private
func buildPackage(sudoUser string, tmpDir string, asDeps bool, logWriter io.Writer) error {
makepkgArgs := []string{"makepkg", "-s", "--noconfirm"}
if asDeps {
makepkgArgs = append(makepkgArgs, "--asdeps")
}
makepkgCmd := log.Command("su", "-", sudoUser, "-c", "cd "+tmpDir+" && "+strings.Join(makepkgArgs, " "))
makepkgCmd.Stdout = logWriter
makepkgCmd.Stderr = logWriter
if err := makepkgCmd.Run(); err != nil {
return fmt.Errorf("makepkg failed to build AUR package: %w", err)
}
return nil
}
func cloneRepo(sudoUser string, packageBase string, tmpDir string, logWriter io.Writer) error {
cloneURL := "https://aur.archlinux.org/" + packageBase + ".git"
cloneCmd := log.Command("su", "-", sudoUser, "-c", "git clone "+cloneURL+" "+tmpDir)
cloneCmd.Stdout = logWriter
cloneCmd.Stderr = logWriter
if err := cloneCmd.Run(); err != nil {
return fmt.Errorf("failed to clone AUR repo: %w", err)
}
return nil
}
func createTempDir(sudoUser string, tmpDir string) error {
mkdirCmd := log.Command("su", "-", sudoUser, "-c", "rm -rf "+tmpDir+" && mkdir -p "+tmpDir)
if err := mkdirCmd.Run(); err != nil {
return fmt.Errorf("failed to create temp directory: %w", err)
}
return nil
}
func findPKGFile(pkgName string, dir string) (string, error) { func findPKGFile(pkgName string, dir string) (string, error) {
entries, err := os.ReadDir(dir) entries, err := os.ReadDir(dir)
if err != nil { if err != nil {
@ -191,6 +227,29 @@ func getAURInfo(f *fetch.Fetcher, pkgName string, packageBase string) *aur.Packa
return &info return &info
} }
func getSudoUser() string {
sudoUserOnce.Do(func() {
sudoUser = os.Getenv("SUDO_USER")
if sudoUser == "" {
sudoUser = os.Getenv("USER")
if sudoUser == "" {
sudoUser = "root"
}
}
})
return sudoUser
}
func installBuiltPackage(pkgFile string, logWriter io.Writer) error {
installCmd := log.Command("pacman", "-U", "--noconfirm", pkgFile)
installCmd.Stdout = logWriter
installCmd.Stderr = logWriter
if err := installCmd.Run(); err != nil {
return fmt.Errorf("failed to install package: %w", err)
}
return nil
}
func resolveAndInstallDeps(f *fetch.Fetcher, aurInfo *aur.Package, logWriter io.Writer) error { func resolveAndInstallDeps(f *fetch.Fetcher, aurInfo *aur.Package, logWriter io.Writer) error {
if aurInfo == nil { if aurInfo == nil {
return nil return nil
@ -240,59 +299,3 @@ func resolveAndInstallDeps(f *fetch.Fetcher, aurInfo *aur.Package, logWriter io.
return nil return nil
} }
func getSudoUser() string {
sudoUserOnce.Do(func() {
sudoUser = os.Getenv("SUDO_USER")
if sudoUser == "" {
sudoUser = os.Getenv("USER")
if sudoUser == "" {
sudoUser = "root"
}
}
})
return sudoUser
}
func createTempDir(sudoUser string, tmpDir string) error {
mkdirCmd := log.Command("su", "-", sudoUser, "-c", "rm -rf "+tmpDir+" && mkdir -p "+tmpDir)
if err := mkdirCmd.Run(); err != nil {
return fmt.Errorf("failed to create temp directory: %w", err)
}
return nil
}
func cloneRepo(sudoUser string, packageBase string, tmpDir string, logWriter io.Writer) error {
cloneURL := "https://aur.archlinux.org/" + packageBase + ".git"
cloneCmd := log.Command("su", "-", sudoUser, "-c", "git clone "+cloneURL+" "+tmpDir)
cloneCmd.Stdout = logWriter
cloneCmd.Stderr = logWriter
if err := cloneCmd.Run(); err != nil {
return fmt.Errorf("failed to clone AUR repo: %w", err)
}
return nil
}
func buildPackage(sudoUser string, tmpDir string, asDeps bool, logWriter io.Writer) error {
makepkgArgs := []string{"makepkg", "-s", "--noconfirm"}
if asDeps {
makepkgArgs = append(makepkgArgs, "--asdeps")
}
makepkgCmd := log.Command("su", "-", sudoUser, "-c", "cd "+tmpDir+" && "+strings.Join(makepkgArgs, " "))
makepkgCmd.Stdout = logWriter
makepkgCmd.Stderr = logWriter
if err := makepkgCmd.Run(); err != nil {
return fmt.Errorf("makepkg failed to build AUR package: %w", err)
}
return nil
}
func installBuiltPackage(pkgFile string, logWriter io.Writer) error {
installCmd := log.Command("pacman", "-U", "--noconfirm", pkgFile)
installCmd.Stdout = logWriter
installCmd.Stderr = logWriter
if err := installCmd.Run(); err != nil {
return fmt.Errorf("failed to install package: %w", err)
}
return nil
}

142
scenario-dependencies-renamed

@ -0,0 +1,142 @@
[debug] run: starting...
[debug] run: packages read (0.00s)
[debug] CheckDBFreshness: starting...
[debug] Sync: starting...
[debug] getInstalledCount: starting...
[debug] getInstalledCount: done (0.01s)
[debug] CheckDBFreshness: starting...
[debug] Sync: database fresh (0.01s)
[debug] Fetcher New: starting...
[debug] registerSyncDBs: starting...
[debug] registerSyncDBs: done (3 dbs)
[debug] Fetcher New: done (0.15s)
[debug] Sync: initialized fetcher (0.15s)
[debug] Sync: categorizing packages...
[debug] categorizePackages: starting...
[debug] Resolve: starting...
[debug] buildLocalPkgMap: starting...
[debug] buildLocalPkgMap: done (0.00s)
[debug] Resolve: local pkgs built (0.00s)
[debug] checkSyncDBs: starting...
[debug] checkSyncDBs: done (0.00s)
[debug] ensureAURCache: starting...
[debug] fetchAURInfo: starting...
[debug] fetchAURInfo: done (0.19s)
[debug] ensureAURCache: done (0.19s)
[debug] Resolve: done (0.20s)
[debug] categorizePackages: done (0.20s)
[debug] Sync: packages categorized (0.36s)
[debug] Sync: syncing 183 pacman packages...
[debug] SyncPackages: starting...
error: pacman sync failed: warning: imv-5.0.1-1 is up to date -- skipping
warning: jq-1.8.1-1 is up to date -- skipping
warning: ntfs-3g-2022.10.3-2 is up to date -- skipping
warning: python-pycurl-7.45.7-3 is up to date -- skipping
warning: usbutils-019-1 is up to date -- skipping
warning: smartmontools-7.5-1 is up to date -- skipping
warning: rsync-3.4.1-2 is up to date -- skipping
warning: linux-firmware-20260309-1 is up to date -- skipping
warning: wget-1.25.0-3 is up to date -- skipping
warning: kvantum-1.1.6-1 is up to date -- skipping
warning: mpv-1:0.41.0-3 is up to date -- skipping
warning: unzip-6.0-23 is up to date -- skipping
warning: ark-25.12.3-1 is up to date -- skipping
warning: brightnessctl-0.5.1-3 is up to date -- skipping
warning: gnome-themes-extra-1:3.28-1 is up to date -- skipping
warning: kolourpaint-25.12.3-1 is up to date -- skipping
warning: rtkit-0.14-1 is up to date -- skipping
warning: isync-1.5.1-2 is up to date -- skipping
warning: qt5-serialport-5.15.18-1 is up to date -- skipping
warning: tlp-1.9.1-1 is up to date -- skipping
warning: amd-ucode-20260309-1 is up to date -- skipping
warning: aria2-1.37.0-2 is up to date -- skipping
warning: lib32-glibc-2.43+r5+g856c426a7534-1 is up to date -- skipping
warning: r-4.5.3-1 is up to date -- skipping
warning: 7zip-26.00-1 is up to date -- skipping
warning: base-devel-1-2 is up to date -- skipping
warning: pacman-contrib-1.13.1-1 is up to date -- skipping
warning: ydotool-1.0.4-2 is up to date -- skipping
warning: sysfsutils-2.1.1-2 is up to date -- skipping
warning: tumbler-4.20.1-1 is up to date -- skipping
warning: efibootmgr-18-3 is up to date -- skipping
warning: exfat-utils-1.4.0-4 is up to date -- skipping
warning: mysql-workbench-8.0.46-1 is up to date -- skipping
warning: python-matplotlib-3.10.8-5 is up to date -- skipping
warning: rofi-2.0.0-1 is up to date -- skipping
warning: inetutils-2.7-2 is up to date -- skipping
warning: thunar-volman-4.20.0-2 is up to date -- skipping
warning: valgrind-3.25.1-4 is up to date -- skipping
warning: python-certifi-2026.02.25-1 is up to date -- skipping
warning: python-opengl-3.1.10-3 is up to date -- skipping
warning: qt5-tools-5.15.18+kde+r3-2 is up to date -- skipping
warning: nwg-look-1.0.6-1 is up to date -- skipping
warning: python-zstandard-0.25.0-2 is up to date -- skipping
warning: sshfs-3.7.5-1 is up to date -- skipping
warning: waybar-0.15.0-2 is up to date -- skipping
warning: base-3-3 is up to date -- skipping
warning: kdenlive-25.12.3-1 is up to date -- skipping
warning: pavucontrol-1:6.2-1 is up to date -- skipping
warning: python-adblock-0.6.0-5 is up to date -- skipping
warning: qt5ct-1.9-1 is up to date -- skipping
warning: wpa_supplicant-2:2.11-5 is up to date -- skipping
warning: aspell-en-2026.02.25-1 is up to date -- skipping
warning: aspell-nl-0.50.2-8 is up to date -- skipping
warning: lib32-openal-1.25.1-1 is up to date -- skipping
warning: ncdu-2.9.2-1 is up to date -- skipping
warning: otf-font-awesome-7.2.0-1 is up to date -- skipping
warning: hunspell-nl-2.20.19-5 is up to date -- skipping
warning: git-2.53.0-1 is up to date -- skipping
warning: nlohmann-json-3.12.0-2 is up to date -- skipping
warning: zsh-completions-0.36.0-1 is up to date -- skipping
warning: man-db-2.13.1-1 is up to date -- skipping
warning: grim-1.5.0-2 is up to date -- skipping
warning: dnsmasq-2.92-1 is up to date -- skipping
warning: kvantum-qt5-1.1.6-1 is up to date -- skipping
warning: iw-6.17-1 is up to date -- skipping
warning: man-pages-6.17-1 is up to date -- skipping
warning: namcap-3.6.0-3 is up to date -- skipping
warning: mesa-demos-9.0.0-7 is up to date -- skipping
warning: reflector-2023-5 is up to date -- skipping
warning: tokei-14.0.0-1 is up to date -- skipping
warning: gammastep-2.0.11-2 is up to date -- skipping
warning: dialog-1:1.3_20260107-1 is up to date -- skipping
warning: mariadb-12.2.2-2 is up to date -- skipping
warning: ttf-dejavu-nerd-3.4.0-2 is up to date -- skipping
warning: vim-spell-nl-20220628-2 is up to date -- skipping
warning: python-pyusb-1.3.1-2 is up to date -- skipping
warning: socat-1.8.1.1-1 is up to date -- skipping
warning: duf-0.9.1-1 is up to date -- skipping
warning: evtest-1.36-1 is up to date -- skipping
warning: rtmpdump-1:2.6-1 is up to date -- skipping
warning: hunspell-1.7.2-3 is up to date -- skipping
warning: kcachegrind-25.12.3-1 is up to date -- skipping
warning: python-watchdog-6.0.0-2 is up to date -- skipping
warning: texlab-5.25.1-1 is up to date -- skipping
warning: sqlitebrowser-3.13.1-3 is up to date -- skipping
warning: acpi-1.8-2 is up to date -- skipping
warning: netctl-1.29-2 is up to date -- skipping
warning: python-beautifulsoup4-4.14.3-2 is up to date -- skipping
warning: vim-spell-en-20220628-2 is up to date -- skipping
warning: xf86-input-wacom-1.2.4-1 is up to date -- skipping
warning: capitaine-cursors-4-3 is up to date -- skipping
warning: ffmpegthumbnailer-2.3.0-1 is up to date -- skipping
warning: hunspell-en_us-2026.02.25-1 is up to date -- skipping
resolving dependencies...
looking for conflicting packages...
error: failed to prepare transaction (could not satisfy dependencies)
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by aquamarine
:: installing libvpx (1.16.0-3) breaks dependency 'libvpx.so=11-64' required by ffmpeg
:: installing gst-plugins-base-libs (1.28.2-1) breaks dependency 'gst-plugins-base-libs=1.28.1-1' required by gst-plugins-bad-libs
:: installing gstreamer (1.28.2-1) breaks dependency 'gstreamer=1.28.1-1' required by gst-plugins-bad-libs
:: installing gst-plugins-base-libs (1.28.2-1) breaks dependency 'gst-plugins-base-libs=1.28.1-1' required by gst-plugins-base
:: installing gstreamer (1.28.2-1) breaks dependency 'gstreamer=1.28.1-1' required by gst-plugins-base
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprgraphics
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprland-guiutils
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprlang
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprtoolkit
:: installing hyprutils (0.12.0-1) breaks dependency 'libhyprutils.so=10-64' required by hyprwire
:: installing libpipewire (1:1.6.3-1) breaks dependency 'libpipewire=1:1.6.1-1' required by pipewire-jack
:: installing pipewire-audio (1:1.6.3-1) breaks dependency 'pipewire-audio=1:1.6.1-1' required by pipewire-jack
:: installing pipewire (1:1.6.3-1) breaks dependency 'pipewire=1:1.6.1-1' required by pipewire-jack
:: installing poppler (26.04.0-1) breaks dependency 'poppler=26.02.0' required by poppler-qt6
Loading…
Cancel
Save