blob: f603a7f184523af89265d620083c16ff236917ec (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
|
# Slackware Package Tools Alternative
An alternative set of Slackware's core package management tools.
The project is experimental, USE AT YOUR OWN RISK!
## Benefits
### Clear modifiable source code
These programs are written in a simple and easy to understand programming
language called Golang. Slackware's official tools are written in a
programming language (bash) which is harder to understand and customize.
### Stable
Do you run Slackware Current? Ever mess up an update? This project will allow
you to more reliably install or remove packages, making it easier to recover a
broken system.
Slackware's package tools like 'installpkg' contain dependencies on commands
like 'tar' and 'tar's library dependencies. These alternatives have no runtime
dependencies, except when running a package's install/uninstall scripts, or
ldconfig.
## Contributing
Planned improvements and known issues are listed on the project's [todo
branch](https://git.server.ky/slackcoder/pkgtools-go/tree/todo?h=todo). Please
check there before making any bug reports.
You can help improve the project through
[funding](https://funding.server.ky/project/pkgtools-go). You will be able to
influence the direction and speed of project development, while matching
other's contributions. For more information, take a look the site's
'[about](https://funding.server.ky/project/pkgtools-go/about)' page.
## Whats included?
The commands 'installpkg' and 'removepkg' are included.
These tools are planned to be included:
- explodepkg
- upgradepkg
These tools will likely not be included:
- makepkg
- pkgdiff
- pkgtool
## Verifying source code
The latest project commit will be signed by the maintainer's GPG key. You will
need to retreive the his key first. Pay extra attention to the key fingerprint
which should remain the same.
```
gpg2 --auto-key-locate=wkd --locate-keys slackcoder@server.ky
# gpg: key 0x8D147EEA19EFF029: public key "Slack Coder <slackcoder@server.ky>" imported
# [..]
# sub cv25519/0xDCA6C34C0A95B957 2022-07-17 [E] [expires: 2024-07-16]
git -c gpg.program=gpg2 verify-commit HEAD
# [..]
# gpg: Good signature from "Slack Coder <slackcoder@server.ky>" [unknown]
# [..]
# Primary key fingerprint: D0CF FD10 75CA B8DA 3299 7507 8D14 7EEA 19EF F029
```
## Install
The recommended way to build these tools is to call this command from within
the directory. The additional parameters are recommended to minimize external
dependencies.
You likely want to set the GOBIN environment variable to your preferred install
location.
```
go install \
-ldflags="-linkmode external -extldflags -static" \
-a ./cmd/...
```
## Operation Notes
### Unsupported tar attributes
These tools will exit with error in the unlikely event the package has
unsupported file attributes, like PAX. You can opt to ignore them via an
environment variable.
```
export PKGTOOLS_GO_STRICT=NO
installpkg some-cool-package.txz
```
|