Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pacstall/pacup
Help maintainers update pacscripts (next-gen Perl rewrite)
https://github.com/pacstall/pacup
pacscript pacstall pacstall-programs python python3 utility
Last synced: 3 months ago
JSON representation
Help maintainers update pacscripts (next-gen Perl rewrite)
- Host: GitHub
- URL: https://github.com/pacstall/pacup
- Owner: pacstall
- License: gpl-3.0
- Created: 2024-04-14T06:02:11.000Z (10 months ago)
- Default Branch: master
- Last Pushed: 2024-10-08T06:13:51.000Z (4 months ago)
- Last Synced: 2024-10-29T14:22:19.851Z (3 months ago)
- Language: Shell
- Homepage:
- Size: 179 KB
- Stars: 6
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Pacup
## What is this?
Pacup (**Pac**script **Up**dater) is a maintainer helper tool to help
maintainers update their pacscripts. It semi-automates the tedious task of
updating pacscripts, and aims to make it a fun process for the maintainer!
Originally written in Python, now in Perl.## Installation
To install the latest release run:
```bash
$ pacstall -I pacup
```To install the latest development build run:
```bash
$ pacstall -I pacup-git
```or
```bash
$ git clone https://github.com/pacstall/pacup.pl
$ cd pacup.pl
$ perl Makefile.PL
$ sudo make install
```To develop in a `nix` shell run:
```console
$ nix-shell
````$PATH` in the `nix-shell` includes `./pacup`.
Use [cached-nix-shell](https://github.com/xzfc/cached-nix-shell) for faster startup time.## Usage
```bash
USAGE: pacup [OPTIONS] PACSCRIPT...OPTIONS:
-v, --version
Print version information and exit.-h, -?, --help
Print this help message and exit.-r, --show-repology
Print the parsed repology data and exit.-s, --ship
Create a new branch and push the changes to git.-o, --origin-remote
Specify the remote repository. Default is 'origin'.-c, --custom-version
Set a custom version for the package to fetch, instead of querying
Repology.-p, --push-force
Force push to the branch, overwriting any existing one.
```You can get this help text by running `pacup --help`.
You should visit our [wiki](https://github.com/pacstall/pacup/wiki/Wiki), for
more information on how to use the `repology` key.## How does it work?
Suppose `foo.pacscript` is outdated.
On running `pacup foo.pacscript` Pacup will parse the pacscript's variables,
then it compiles a list of filters specified in the `repology` variable in the
pacscript. Then it queries the [Repology API](https://repology.org/api) to get
all the repositories which have packaged that package. After which it applies
the filter to the response, and from the filtrate it considers the most common
version to be the latest.Then it replaces all occurrences of the previous `version`'s value in the `url`
with the latest one placeholder's value with the latest version, and downloads
the new package, and generates it's hash.Then writes the edited pacscript and installs it with
[Pacstall](https://github.com/pacstall/pacstall), after installation it asks
the user to confirm that the installed package works. On approval the pacscript
is considered successfully upgraded and the program ends.## Caveats
* Does not work with `-git` pacscripts as those pacscripts are auto updating.
* Doesn't work if a pacscript doesn't have an equivalent
[Repology](https://repology.org/) package.## Stats
## License
```monospace
____ __ __
/ __ \____ ______/ / / /___
/ /_/ / __ `/ ___/ / / / __ \
/ ____/ /_/ / /__/ /_/ / /_/ /
/_/ \__,_/\___/\____/ .___/
/_/Copyright (C) 2022-present
This file is part of PacUp
PacUp is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.PacUp is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.You should have received a copy of the GNU General Public License
along with PacUp. If not, see .
```