Compare commits

..

1 Commits

Author SHA1 Message Date
Christian Heusel
b095aeee61 wip: pkgctl rebuild-todo 2024-03-19 18:43:05 +01:00
99 changed files with 359 additions and 2531 deletions

View File

@@ -1,15 +0,0 @@
# EditorConfig configuration for devtools
# https://editorconfig.org
# Top-most EditorConfig file
root = true
# Unix-style newlines without trailing whitespaces, but with a newline
# ending every file, utf-8 charset, set indent to tabs
[*]
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
charset = utf-8
indent_style = tab
tab_width = 4

View File

@@ -12,33 +12,10 @@ build:
- make PREFIX=/usr
- make PREFIX=/usr DESTDIR=build install
lint:
check:
stage: test
needs: []
script:
- pacman -Syu --noconfirm m4 make openssh subversion rsync arch-install-scripts git bzr mercurial diffutils asciidoctor shellcheck
- make check || true
- SHELLCHECK_OPTS="-S error" make check
test:
stage: test
needs: []
script:
- pacman -Syu --noconfirm m4 make openssh subversion rsync arch-install-scripts git bzr mercurial diffutils coreutils asciidoctor shellcheck nvchecker bats
- make test BATS_EXTRA_ARGS='--formatter junit'
artifacts:
reports:
junit: build/coverage/bats-report.xml
coverage:
stage: test
needs: []
script:
- pacman -Syu --noconfirm m4 make openssh subversion rsync arch-install-scripts git bzr mercurial diffutils coreutils asciidoctor shellcheck nvchecker bats kcov jq
- make coverage
coverage: '/Percent covered\s+\d+\.\d+/'
artifacts:
reports:
coverage_report:
coverage_format: cobertura
path: build/coverage/bats.*/cobertura.xml

View File

@@ -1,6 +1,6 @@
SHELL=/bin/bash -o pipefail
SHELL=/bin/bash
V=1.2.1
V=1.1.1
BUILDTOOLVER ?= $(V)
PREFIX = /usr/local
@@ -52,13 +52,6 @@ ARCHBUILD_LINKS = \
COMPLETIONS = $(addprefix $(BUILDDIR)/,$(patsubst %.in,%,$(wildcard contrib/completion/*/*)))
CASES ?= test/case
JOBS ?= $(shell nproc)
BATS_EXTRA_ARGS ?=
BATS_ARGS ?= --jobs $(JOBS) $(BATS_EXTRA_ARGS) --verbose-run
COVERAGE_DIR ?= $(BUILDDIR)/coverage
all: binprogs library conf completion man
binprogs: $(BINPROGS)
library: $(LIBRARY)
@@ -175,17 +168,8 @@ dist:
git archive --format=tar --prefix=devtools-$(V)/ v$(V) | gzip > devtools-$(V).tar.gz
gpg --detach-sign --use-agent devtools-$(V).tar.gz
test: binprogs library conf completion man
@mkdir -p $(COVERAGE_DIR)
bats $(BATS_ARGS) $(CASES) | tee $(COVERAGE_DIR)/bats-report.xml
coverage: binprogs library conf completion man
kcov --include-path=src $(COVERAGE_DIR) bats $(BATS_ARGS) $(CASES)
jq -r '. | ["Percent covered", .percent_covered], ["Covered lines", .covered_lines], ["Total lines", .total_lines], ["Percent low", .percent_low], ["Percent high", .percent_high] | @tsv' \
$(COVERAGE_DIR)/bats.*/coverage.json
check: $(BINPROGS_SRC) $(LIBRARY_SRC) contrib/completion/bash/devtools.in config/makepkg/x86_64.conf contrib/makepkg/PKGBUILD.proto
shellcheck $^
.PHONY: all binprogs library completion conf man clean install uninstall tag dist upload test coverage check
.PHONY: all binprogs library completion conf man clean install uninstall tag dist upload check
.DELETE_ON_ERROR:

View File

@@ -71,7 +71,6 @@ Component: pkgctl db remove
- coreutils
- curl
- diffutils
- expac
- fakeroot
- findutils
- grep
@@ -92,13 +91,13 @@ Component: pkgctl db remove
- bat (pretty printing)
- nvchecker (version checking)
- pacman-contrib (--update-checksums options for pkgctl build)
### Development Dependencies
- asciidoctor
- make
- shellcheck
- bats
## License

View File

@@ -1,112 +0,0 @@
#
# /etc/pacman.conf
#
# See the pacman.conf(5) manpage for option and repository directives
#
# GENERAL OPTIONS
#
[options]
# The following paths are commented out with their default values listed.
# If you wish to use different paths, uncomment and update the paths.
#RootDir = /
#DBPath = /var/lib/pacman/
#CacheDir = /var/cache/pacman/pkg/
#LogFile = /var/log/pacman.log
#GPGDir = /etc/pacman.d/gnupg/
#HookDir = /etc/pacman.d/hooks/
HoldPkg = pacman glibc
#XferCommand = /usr/bin/curl -L -C - -f -o %o %u
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u
#CleanMethod = KeepInstalled
Architecture = auto
# Pacman won't upgrade packages listed in IgnorePkg and members of IgnoreGroup
#IgnorePkg =
#IgnoreGroup =
#NoUpgrade =
#NoExtract =
# Misc options
#UseSyslog
#Color
NoProgressBar
# We cannot check disk space from within a chroot environment
#CheckSpace
VerbosePkgLists
ParallelDownloads = 5
# By default, pacman accepts packages signed by keys that its local keyring
# trusts (see pacman-key and its man page), as well as unsigned packages.
SigLevel = Required DatabaseOptional
LocalFileSigLevel = Optional
#RemoteFileSigLevel = Required
# NOTE: You must run `pacman-key --init` before first using pacman; the local
# keyring can then be populated with the keys of all official Arch Linux
# packagers with `pacman-key --populate archlinux`.
#
# REPOSITORIES
# - can be defined here or included from another file
# - pacman will search repositories in the order defined here
# - local/custom mirrors can be added here or in separate files
# - repositories listed first will take precedence when packages
# have identical names, regardless of version number
# - URLs will have $repo replaced by the name of the current repo
# - URLs will have $arch replaced by the name of the architecture
#
# Repository entries are of the format:
# [repo-name]
# Server = ServerName
# Include = IncludePath
#
# The header [repo-name] is crucial - it must be present and
# uncommented to enable the repo.
#
# The testing repositories are disabled by default. To enable, uncomment the
# repo name header and Include lines. You can add preferred servers immediately
# after the header, and they will be used before the default mirrors.
[gnome-unstable]
Include = /etc/pacman.d/mirrorlist
[kde-unstable]
Include = /etc/pacman.d/mirrorlist
[core-staging]
Include = /etc/pacman.d/mirrorlist
[core-testing]
Include = /etc/pacman.d/mirrorlist
[core]
Include = /etc/pacman.d/mirrorlist
[extra-staging]
Include = /etc/pacman.d/mirrorlist
[extra-testing]
Include = /etc/pacman.d/mirrorlist
[extra]
Include = /etc/pacman.d/mirrorlist
# If you want to run 32 bit applications on your x86_64 system,
# enable the multilib repositories as required here.
[multilib-staging]
Include = /etc/pacman.d/mirrorlist
[multilib-testing]
Include = /etc/pacman.d/mirrorlist
[multilib]
Include = /etc/pacman.d/mirrorlist
# An example of a custom package repository. See the pacman manpage for
# tips on creating your own repositories.
#[custom]
#SigLevel = Optional TrustAll
#Server = file:///home/custompkgs

View File

@@ -1,83 +0,0 @@
#
# /etc/pacman.conf
#
# See the pacman.conf(5) manpage for option and repository directives
#
# GENERAL OPTIONS
#
[options]
# The following paths are commented out with their default values listed.
# If you wish to use different paths, uncomment and update the paths.
#RootDir = /
#DBPath = /var/lib/pacman/
#CacheDir = /var/cache/pacman/pkg/
#LogFile = /var/log/pacman.log
#GPGDir = /etc/pacman.d/gnupg/
#HookDir = /etc/pacman.d/hooks/
HoldPkg = pacman glibc
#XferCommand = /usr/bin/curl -L -C - -f -o %o %u
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u
#CleanMethod = KeepInstalled
Architecture = auto
# Pacman won't upgrade packages listed in IgnorePkg and members of IgnoreGroup
#IgnorePkg =
#IgnoreGroup =
#NoUpgrade =
#NoExtract =
# Misc options
#UseSyslog
#Color
NoProgressBar
# We cannot check disk space from within a chroot environment
#CheckSpace
VerbosePkgLists
ParallelDownloads = 5
# By default, pacman accepts packages signed by keys that its local keyring
# trusts (see pacman-key and its man page), as well as unsigned packages.
SigLevel = Required DatabaseOptional
LocalFileSigLevel = Optional
#RemoteFileSigLevel = Required
# NOTE: You must run `pacman-key --init` before first using pacman; the local
# keyring can then be populated with the keys of all official Arch Linux
# packagers with `pacman-key --populate archlinux`.
#
# REPOSITORIES
# - can be defined here or included from another file
# - pacman will search repositories in the order defined here
# - local/custom mirrors can be added here or in separate files
# - repositories listed first will take precedence when packages
# have identical names, regardless of version number
# - URLs will have $repo replaced by the name of the current repo
# - URLs will have $arch replaced by the name of the architecture
#
# Repository entries are of the format:
# [repo-name]
# Server = ServerName
# Include = IncludePath
#
# The header [repo-name] is crucial - it must be present and
# uncommented to enable the repo.
#
# The testing repositories are disabled by default. To enable, uncomment the
# repo name header and Include lines. You can add preferred servers immediately
# after the header, and they will be used before the default mirrors.
[gnome-unstable]
Include = /etc/pacman.d/mirrorlist
[kde-unstable]
Include = /etc/pacman.d/mirrorlist
# An example of a custom package repository. See the pacman manpage for
# tips on creating your own repositories.
#[custom]
#SigLevel = Optional TrustAll
#Server = file:///home/custompkgs

View File

@@ -14,6 +14,7 @@ source "${_DEVTOOLS_LIBRARY_DIR}"/lib/valid-inspect.sh
# shellcheck source=src/lib/valid-search.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/valid-search.sh
_binary_arch=${DEVTOOLS_VALID_ARCHES[*]:0:-1}
_colors=(never always auto)
@@ -27,7 +28,6 @@ _makechrootpkg_args=(
-I
-l
-n
-t
-T
-U
-x
@@ -37,7 +37,6 @@ _makechrootpkg_args_D_opts() { _filedir -d; }
_makechrootpkg_args_r_opts() { _filedir -d; }
_makechrootpkg_args_I_opts() { _filedir '*.pkg.tar.*'; }
_makechrootpkg_args_l_opts() { _filedir -d; }
_makechrootpkg_args_t_opts() { _filedir -d; }
_makechrootpkg_args_U_opts() { :; }
_makechrootpkg_args_x_opts() { _devtools_completions_inspect; }
_makechrootpkg() { __devtools_complete _makechrootpkg; }
@@ -63,14 +62,12 @@ _mkarchroot_args=(
-C
-M
-c
-f
-h
)
_mkarchroot_args_U_opts() { _filedir '*.pkg.tar.*'; }
_mkarchroot_args_C_opts() { _filedir '*.conf'; }
_mkarchroot_args_M_opts() { _filedir '*.conf'; }
_mkarchroot_args_c_opts() { _filedir -d; }
_mkarchroot_args_f_opts() { _filedir -d; }
_mkarchroot_opts() {
local args
args=$(__pkgctl_word_count_after_subcommand)
@@ -131,7 +128,7 @@ _offload_build_args=(
)
_offload_build_args__repo_opts() { _devtools_completions_build_repo; }
_offload_build_args_r_opts() { _offload_build_args__repo_opts; }
_offload_build_args__arch_opts() { _devtools_completions_binary_arch; }
_offload_build_args__arch_opts() { _devtools_completions_arch; }
_offload_build_args_a_opts() { _offload_build_args__arch_opts; }
_offload_build_args__server_opts() { :; }
_offload_build_args_s_opts() { _offload_build_args__server_opts; }
@@ -199,7 +196,7 @@ _pkgctl_build_args=(
-h --help
)
_pkgctl_build_args__arch_opts() { _devtools_completions_binary_arch; }
_pkgctl_build_args__arch_opts() { _devtools_completions_arch; }
_pkgctl_build_args__repo_opts() { _devtools_completions_repo; }
_pkgctl_build_args__worker_opts() { :; }
_pkgctl_build_args_w_opts() { _pkgctl_build_args__worker_opts; }
@@ -244,13 +241,9 @@ _pkgctl_db_move_opts() {
_pkgctl_db_remove_args=(
--partial
--noconfirm
-a --arch
-h --help
)
_pkgctl_db_remove_args__arch_opts() { _devtools_completions_binary_arch; }
_pkgctl_db_remove_args_a_opts() { _pkgctl_db_remove_args__arch_opts; }
_pkgctl_db_remove_opts() {
local subcommand args
subcommand=(db remove)
@@ -296,7 +289,6 @@ _pkgctl_aur_drop_from_repo_opts() { _filedir -d; }
_pkgctl_repo_cmds=(
clean
clone
configure
create
@@ -322,12 +314,6 @@ _pkgctl_repo_clone_args__jobs_opts() { :; }
_pkgctl_repo_clone_args_j_opts() { _pkgctl_repo_clone_args__jobs_opts; }
_pkgctl_repo_clone_opts() { _devtools_completions_all_packages; }
_pkgctl_repo_clean_args=(
-i --interactive
-n --dry-run
-h --help
)
_pkgctl_repo_clean_opts() { _filedir -d; }
_pkgctl_repo_configure_args=(
--protocol
@@ -364,7 +350,6 @@ _pkgctl_repo_switch_opts() {
_pkgctl_version_cmds=(
check
setup
upgrade
)
@@ -375,19 +360,7 @@ _pkgctl_version_check_args=(
_pkgctl_version_check_opts() { _filedir -d; }
_pkgctl_version_setup_args=(
--prefer-platform-api
--url
--no-check
-f --force
-h --help
)
_pkgctl_version_setup_opts() { _filedir -d; }
_pkgctl_version_setup_args__url_opts() { :; }
_pkgctl_version_upgrade_args=(
--no-update-checksums
-v --verbose
-h --help
)
@@ -448,9 +421,6 @@ _devtools_completions_color() {
_devtools_completions_arch() {
mapfile -t COMPREPLY < <(compgen -W "${DEVTOOLS_VALID_ARCHES[*]}" -- "$cur")
}
_devtools_completions_binary_arch() {
mapfile -t COMPREPLY < <(compgen -W "${DEVTOOLS_VALID_BINARY_ARCHES[*]}" -- "$cur")
}
_devtools_completions_repo() {
local optional=${1:-}
mapfile -t COMPREPLY < <(compgen -W "${optional} ${DEVTOOLS_VALID_REPOS[*]}" -- "$cur")

View File

@@ -14,6 +14,7 @@ source "${_DEVTOOLS_LIBRARY_DIR}"/lib/valid-inspect.sh
# shellcheck source=src/lib/valid-search.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/valid-search.sh
_binary_arch=${DEVTOOLS_VALID_ARCHES[*]:0:-1}
_colors=(never always auto)
_archbuild_args=(
@@ -40,8 +41,8 @@ _pkgctl_auth_status_args=(
)
_pkgctl_build_args=(
"--arch[Specify architectures to build for (disables auto-detection)]:arch:($DEVTOOLS_VALID_BINARY_ARCHES[*])"
"--repo[Specify a target repository (disables auto-detection)]:repo:($DEVTOOLS_VALID_REPOS[*])"
"--arch=[Specify architectures to build for (disables auto-detection)]:arch:($_arch[*])"
"--repo=[Specify a target repository (disables auto-detection)]:repo:($DEVTOOLS_VALID_REPOS[*])"
'(-s --staging)'{-s,--staging}'[Build against the staging counterpart of the auto-detected repo]'
'(-t --testing)'{-t,--testing}'[Build against the testing counterpart of the auto-detected repo]'
'(-o --offload)'{-o,--offload}'[Build on a remote server and transfer artifacts afterwards]'
@@ -78,9 +79,7 @@ _pkgctl_db_move_args=(
)
_pkgctl_db_remove_args=(
'--partial[Remove only partial pkgnames from a split package]'
'--noconfirm[Bypass any confirmation messages, should only be used with caution]'
'(-a --arch)'{-a,--arch}"[Override the architecture (disables auto-detection)]:arch:($DEVTOOLS_VALID_BINARY_ARCHES[*])"
'(-a --arch=)'{-a,--arch=}"[Override the architecture (disables auto-detection)]:arch:($_arch[*])"
'(-h --help)'{-h,--help}'[Display usage]'
"1:repo:($DEVTOOLS_VALID_REPOS[*])"
'*:pkgbase:_devtools_completions_all_packages'
@@ -114,7 +113,6 @@ _pkgctl_aur_drop_from_repo_args=(
_pkgctl_repo_cmds=(
"pkgctl repo command"
"clean[Remove untracked files from the working tree]"
"clone[Clone a package repository]"
"configure[Configure a clone according to distro specs]"
"create[Create a new GitLab package repository]"
@@ -129,13 +127,6 @@ _pkgctl_repo_switch_args=(
'*:git_dir:_files -/'
)
_pkgctl_repo_clean_args=(
'(-i --interactive)'{-i,--interactive}'[Show what would be done and clean files interactively]'
'(-n --dry-run)'{-n,--dry-run}"[Don't remove anything, just show what would be done]"
'(-h --help)'{-h,--help}'[Display usage]'
'*:git_dir:_files -/'
)
_pkgctl_repo_clone_args=(
'(-m --maintainer=)'{-m,--maintainer=}'[Clone all packages of the named maintainer]:maintainer:'
'--protocol[Clone the repository over https]:proto:(https)'
@@ -222,7 +213,6 @@ _makechrootpkg_args=(
'-c[Clean the chroot before building]'
'*-d[Bind directory into build chroot as read-write]:bind_dir_rw:_files -/'
'*-D[Bind directory into build chroot as read-only]:bind_dir_ro:_files -/'
'*-t[Mount a tmpfs at directory]:tmpfs_dir:_files -/'
'-u[Update the working copy of the chroot before building]'
'-r[The chroot dir to use]:chroot_dir:_files -/'
'*-I[Install a package into the working copy]:target:_files -g "*.pkg.tar.*(.)"'
@@ -238,7 +228,6 @@ _mkarchroot_args=(
'-C[Location of a pacman config file]:pacman_config:_files -g "*.conf(.)"'
'-M[Location of a makepkg config file]:makepkg_config:_files -g "*.conf(.)"'
'-c[Set pacman cache]:pacman_cache:_files -/'
'-f[Copy src file from the host to the chroot]:target:_files -/'
'-h[Display usage]'
'1:working_dir:_files -/'
'*:packages:_devtools_completions_all_packages'
@@ -261,7 +250,7 @@ _sogrep_args=(
_offload_build_args=(
'(-r --repo)'{-r,--repo}'[Build against a specific repository]:repo:($DEVTOOLS_VALID_BUILDREPOS[*])'
'(-a --arch)'{-a,--arch}'[Build against a specific architecture]:arch:(${DEVTOOLS_VALID_BINARY_ARCHES[*]})'
'(-a --arch)'{-a,--arch}'[Build against a specific architecture]:arch:(${_binary_arch[*]})'
'(-s --server)'{-s,--server}'[Offload to a specific Build server]:server:'
'(-h --help)'{-h,--help}'[Display usage]'
)
@@ -302,7 +291,6 @@ _pkgctl_args=(
_pkgctl_version_cmds=(
"pkgctl version command"
"check[Compares local package versions against upstream versions]"
"setup[Automatically detect and setup a basic nvchecker config]"
"upgrade[Adjust the PKGBUILD to match the latest upstream version]"
)
@@ -312,17 +300,7 @@ _pkgctl_version_check_args=(
'*:git_dir:_files -/'
)
_pkgctl_version_setup_args=(
'(-f --force)'{-f,--force}'[Do not prompt before overwriting]'
'--prefer-platform-api[Prefer platform specific GitHub/GitLab API for complex cases]'
'--url[Derive check target from URL instead of source array]:url:'
'--no-check[Do not run version check after setup]'
'(-h --help)'{-h,--help}'[Display usage]'
'*:git_dir:_files -/'
)
_pkgctl_version_upgrade_args=(
'--no-update-checksums[Disable computation and update of the checksums]'
'(-v --verbose)'{-v,--verbose}'[Display results including up-to-date versions]'
'(-h --help)'{-h,--help}'[Display usage]'
'*:git_dir:_files -/'

View File

@@ -28,9 +28,8 @@ Options
*-c* <dir>::
Set pacman cache, if no directory is specified the passed pacman.conf's cachedir is used with a fallback to '/etc/pacman.conf'
*-f* <src>[:<dst>]::
Copy file from the host to the chroot.
If 'dst' is not provided, it defaults to 'src' inside of the chroot.
*-f* <file>::
Copy file from the host to the chroot
*-s*::
Do not run setarch

View File

@@ -45,9 +45,6 @@ Options
*-D* <dir>::
Bind directory into build chroot as read-only
*-t* <dir>[:opts]::
Mount a tmpfs at 'dir'. See the '--tmpfs' argument in systemd-nspawn(1) for more details.
*-u*::
Update the working copy of the chroot before building
This is useful for rebuilds without dirtying the pristine
@@ -79,9 +76,5 @@ Options
*-x* <when>::
Inspect chroot after build, possible modes are 'never' (default), 'always' or 'failure'
See Also
--------
systemd-nspawn(1)
include::include/footer.asciidoc[]

View File

@@ -32,9 +32,8 @@ Options
*-c* <dir>::
Set pacman cache.
*-f* <src>[:<dst>]::
*-f* <file>::
Copy file from the host to the chroot.
If 'dst' is not provided, it defaults to 'src' inside of the chroot.
*-s*::
Do not run setarch.

View File

@@ -12,10 +12,7 @@ pkgctl build [OPTIONS] [PATH...]
Description
-----------
Build packages in clean chroot environment, offering various options
and functionalities to customize the package building process.
By default, chroot environments are located in '/var/lib/archbuild/'.
TODO
Build Options
-------------

View File

@@ -12,27 +12,13 @@ pkgctl db remove [OPTIONS] [REPO] [PKGBASE]...
Description
-----------
Remove packages from pacman repositories. By default passing a pkgbase removes
all split packages, debug packages as well as entries from the state repo for
all existing architectures.
Beware when using the `--partial` option, as it may most likely lead to
undesired effects by leaving debug packages behind as well as dangling entries
in the state repository.
Remove packages from pacman repositories.
Options
-------
*--partial*::
Remove only partial pkgnames from a split package. This leaves debug
packages behind and pkgbase entries in the state repo.
*-a, --arch* 'ARCH'::
Remove only one specific architecture (disables auto-detection).
By default all architectures are removed when this option is not used.
*--noconfirm*::
Bypass any confirmation messages, should only be used with caution.
Override the architecture (disables auto-detection)
*-h, --help*::
Show a help text

View File

@@ -1,43 +0,0 @@
pkgctl-db(1)
============
NAME
----
pkgctl-db - Pacman database modification utility for package updates, moves, and more.
SYNOPSIS
--------
pkgctl db [OPTIONS] [SUBCOMMAND]
DESCRIPTION
-----------
Managing the Pacman database and facilitate the modification of packages and their metadata
within the database
OPTIONS
-------
*-h, --help*::
Display usage information and available options.
Subcommands
-----------
pkgctl db update::
Update the binary repository as final release step
pkgctl db move::
Move packages between binary repositories
pkgctl db remove::
Remove packages from binary repositories
SEE ALSO
--------
pkgctl-db-update(1)
pkgctl-db-move(1)
pkgctl-db-remove(1)
include::include/footer.asciidoc[]

View File

@@ -1,40 +0,0 @@
pkgctl-repo-clean(1)
====================
Name
----
pkgctl-repo-clean - Remove untracked files from the working tree
Synopsis
--------
pkgctl repo clean [OPTION] [PATH]...
Description
-----------
Cleans the working tree by recursively removing files that are not under
version control, starting from the current directory.
Files unknown to Git as well as ignored files are removed. This can, for
example, be useful to remove all build products.
Options
-------
*-i, --interactive*::
Show what would be done and clean files interactively
*-n, --dry-run*::
Don't actually remove anything, just show what would be done
*-h, --help*::
Show a help text
See Also
--------
git-clean(1)
include::include/footer.asciidoc[]

View File

@@ -32,9 +32,6 @@ Options
Subcommands
-----------
pkgctl repo clean::
Remove untracked files from the working tree
pkgctl repo clone::
Clone a package repository
@@ -53,7 +50,6 @@ pkgctl repo web::
See Also
--------
pkgctl-repo-clean(1)
pkgctl-repo-clone(1)
pkgctl-repo-configure(1)
pkgctl-repo-create(1)

View File

@@ -1,120 +0,0 @@
pkgctl-version-setup(1)
=======================
Name
----
pkgctl-version-setup - Automatically detect and setup a basic nvchecker config
Synopsis
--------
pkgctl version setup [OPTIONS] [PKGBASE...]
Description
-----------
This subcommand automates the creation of a basic nvchecker(1) configuration
file by analyzing the source array specified in the PKGBUILD(1) file of a
package. This command intelligently detects various platforms and APIs (e.g.,
GitHub, GitLab, PyPI) used by the package sources and generates a corresponding
`.nvchecker.toml` configuration based on its best guess.
This is particularly useful for initializing nvchecker(1) settings for a
package without manually crafting the `.nvchecker.toml` file. It simplifies the
process of setting up version checks, especially when transitioning a package's
monitoring from one source platform to another or starting version checks for a
new package.
If no `PKGBASE` is specified, the command defaults to using the current working
directory.
To obtain a list of supported sources and their expected URL formats, please
consult the sources section.
Options
-------
*-f, --force*::
Overwrite existing nvchecker(1) configuration
*--prefer-platform-api*::
Prefer platform specific GitHub/GitLab API over git for complex cases
*--url* 'URL'::
Derive check target from the given URL instead of the source array entries
*--no-check*::
Do not run pkgctl-version-check(1) after setup
*-h, --help*::
Show a help text
Sources
-------
Here are the currently supported platforms and sources, along with examples of
URL formats that enable their automatic detection as specific source types:
*Git*::
* https://github.com/example/project
* https://gitlab.com/example/group/project
* git://git.foobar.org/example
* git+https://git.foobar.org/example
*GitHub*::
* https://github.com/example/project
* https://github.com/example/project/archive/v1.0/project-v1.0.tar.gz
*GitLab*::
* https://gitlab.com/example/group/project
* https://gitlab.archlinux.org/archlinux/devtools.git
* https://gitlab.archlinux.org/archlinux/devtools/-/releases/v1.1.0/downloads/devtools-v1.1.0.tar.gz
*Hackage*::
* https://hackage.haskell.org/package/xmonad
* https://hackage.haskell.org/package/xmonad-0.18.0/xmonad-0.18.0.tar.gz
* https://hackage.haskell.org/packages/archive/xmonad/0.18.0/xmonad-0.18.0.tar.gz
*NPM*::
* https://registry.npmjs.org/node-gyp/-/node-gyp-10.0.1.tgz
* https://www.npmjs.com/package/node-gyp
*PyPI*::
* https://pypi.io/packages/source/p/pyflakes
* https://pypi.org/packages/source/b/bleach
* https://files.pythonhosted.org/packages/source/p/pyflakes
* https://pypi.org/project/SQLAlchemy/
*RubyGems*::
* https://rubygems.org/downloads/diff-lcs-1.5.1.gem
* https://rubygems.org/gems/diff-lcs
*CPAN*::
* https://search.cpan.org/CPAN/authors/id/C/CO/COSIMO/Locale-PO-0.27.tar.gz
* https://cpan.metacpan.org/authors/id/C/CO/COSIMO/Locale-PO-0.27.tar.gz
*crates.io*::
* https://static.crates.io/crates/shotgun/shotgun-1.0.crate
* https://crates.io/api/v1/crates/shotgun/1.0/download
* https://crates.io/crates/git-smash
Examples
--------
*pkgctl version setup*::
Detects the source from the current directory's PKGBUILD(1) and
sets up a basic `.nvchecker.toml`.
*pkgctl version setup --url https://github.com/example/project*::
Generates an `.nvchecker.toml` for the current PKGBUILD(1) but
overrides the source URL with the specified GitHub project.
See Also
--------
pkgctl-version(1)
pkgctl-version-check(1)
nvchecker(1)
PKGBUILD(5)
include::include/footer.asciidoc[]

View File

@@ -18,7 +18,7 @@ upstream versions.
Upon execution, it automatically adjusts the PKGBUILD file, ensuring that the
pkgver field is set to match the latest version available from the upstream
source. In addition to updating the pkgver, this command also resets the pkgrel
to 1 and updates checksums.
to 1.
Outputs a summary of upgraded packages, up-to-date packages, and any check
failures.
@@ -35,9 +35,6 @@ PKGBUILD. Refer to the configuration section in pkgctl-version(1).
Options
-------
*--no-update-checksums*::
Disable computation and update of the checksums
*-v, --verbose*::
Display results including up-to-date versions

View File

@@ -26,9 +26,6 @@ package's pkgbase. The pkgbase section within the `.nvchecker.toml` file
specifies the source and method for checking the latest version of the
corresponding package.
Use pkgctl-version-setup(1) to automatically detect and setup a basic nvchecker
config based on the source array of the package PKGBUILD.
For detailed information on the various configuration options available for the
`.nvchecker.toml` file, refer to the configuration files section in
nvchecker(1). This documentation provides insights into the possible
@@ -51,9 +48,6 @@ Subcommands
pkgctl version check::
Compares local package versions against upstream
pkgctl version setup::
Automatically detect and setup a basic nvchecker config
pkgctl version upgrade::
Adjust the PKGBUILD to match the latest upstream version
@@ -61,7 +55,6 @@ See Also
--------
pkgctl-version-check(1)
pkgctl-version-setup(1)
pkgctl-version-upgrade(1)
include::include/footer.asciidoc[]

View File

@@ -12,12 +12,7 @@ pkgctl [SUBCOMMAND] [OPTIONS]
Description
-----------
Command-line utility serving as a unified interface for multiple development tools.
This tool aims to simplify and optimize interactions with devtools by offering
various subcommands for executing tasks related to package management, repository management,
version control, among others.
Utilizing pkgctl enables users to efficiently administer their development workflows.
TODO
Options
-------

View File

@@ -22,13 +22,12 @@ usage() {
echo "A wrapper around systemd-nspawn. Provides support for pacman."
echo
echo ' options:'
echo ' -C <file> Location of a pacman config file'
echo ' -M <file> Location of a makepkg config file'
echo ' -c <dir> Set pacman cache'
echo ' -f <src>[:<dst>] Copy src file from the host to the chroot.'
echo ' If dst file is not provided, it defaults to src'
echo ' -s Do not run setarch'
echo ' -h This message'
echo ' -C <file> Location of a pacman config file'
echo ' -M <file> Location of a makepkg config file'
echo ' -c <dir> Set pacman cache'
echo ' -f <file> Copy file from the host to the chroot'
echo ' -s Do not run setarch'
echo ' -h This message'
exit 1
}
@@ -64,7 +63,6 @@ nspawn_args=(
--slice="devtools-$(systemd-escape "${SUDO_USER:-$USER}")"
--machine="arch-nspawn-$$"
--as-pid2
--console=autopipe
)
if (( ${#cache_dirs[@]} == 0 )); then
@@ -73,7 +71,6 @@ fi
# shellcheck disable=2016
host_mirrors=($(pacman-conf --repo extra Server 2> /dev/null | sed -r 's#(.*/)extra/os/.*#\1$repo/os/$arch#'))
host_cachemirrors=($(pacman-conf --repo extra CacheServer 2> /dev/null | sed -r 's#(.*/)extra/os/.*#\1$repo/os/$arch#'))
for host_mirror in "${host_mirrors[@]}"; do
if [[ $host_mirror == *file://* ]]; then
@@ -108,17 +105,13 @@ copy_hostconf () {
printf 'Server = %s\n' "${host_mirrors[@]}" >"$working_dir/etc/pacman.d/mirrorlist"
[[ -n $host_cachemirrors ]] && printf 'CacheServer = %s\n' "${host_cachemirrors[@]}" >>"$working_dir/etc/pacman.d/mirrorlist"
[[ -n $pac_conf ]] && cp "$pac_conf" "$working_dir/etc/pacman.conf"
[[ -n $makepkg_conf ]] && cp "$makepkg_conf" "$working_dir/etc/makepkg.conf"
local file
for file in "${files[@]}"; do
src="${file%%:*}"
dst="${file#*:}"
mkdir -p "$(dirname "$working_dir$dst")"
cp -T "$src" "$working_dir$dst"
mkdir -p "$(dirname "$working_dir$file")"
cp -T "$file" "$working_dir$file"
done
sed -r "s|^#?\\s*CacheDir.+|CacheDir = ${cache_dirs[*]}|g" -i "$working_dir/etc/pacman.conf"

View File

@@ -140,7 +140,7 @@ for _pkgname in "${pkgname[@]}"; do
bsdtar tf "$TEMPDIR/$oldpkg" | sort > "$TEMPDIR/filelist-$_pkgname-old"
bsdtar tf "$pkgfile" | sort > "$TEMPDIR/filelist-$_pkgname"
diff --side-by-side --suppress-common-lines --width="$COLUMNS" --color=auto "$TEMPDIR/filelist-$_pkgname-old" "$TEMPDIR/filelist-$_pkgname"
sdiff -s "$TEMPDIR/filelist-$_pkgname-old" "$TEMPDIR/filelist-$_pkgname"
find-libprovides "$TEMPDIR/$oldpkg" 2>/dev/null | sort > "$TEMPDIR/libraries-$_pkgname-old"
find-libprovides "$pkgfile" 2>/dev/null | sort > "$TEMPDIR/libraries-$_pkgname"

View File

@@ -151,7 +151,7 @@ fi
server=${PACKAGING_REPO_RELEASE_HOST}
rsyncopts=("${RSYNC_OPTS[@]}" --perms --chmod='ug=rw,o=r')
rsyncopts=(-e ssh -p '--chmod=ug=rw,o=r' -c -h -L --progress --partial -y)
archreleaseopts=()
while getopts ':l:a:s:f' flag; do
case $flag in

View File

@@ -165,7 +165,7 @@ pkgctl_aur_drop_from_repo() {
warning 'Did not find %s in any repository, please delete manually' "${pkgbase}"
else
msg2 " repo: ${pkgrepo}"
pkgctl_db_remove --noconfirm "${pkgrepo}" "${pkgbase}"
pkgctl_db_remove "${pkgrepo}" "${pkgbase}"
fi
popd >/dev/null

View File

@@ -63,7 +63,7 @@ pkgctl_auth_login() {
esac
done
personal_access_token_url="https://${GITLAB_HOST}/-/user_settings/personal_access_tokens?name=pkgctl+token&scopes=api,write_repository"
personal_access_token_url="https://${GITLAB_HOST}/-/profile/personal_access_tokens?name=pkgctl+token&scopes=api,write_repository"
cat <<- _EOF_
Logging into ${BOLD}${GITLAB_HOST}${ALL_OFF}

View File

@@ -55,7 +55,6 @@ pkgctl_build_usage() {
-o, --offload Build on a remote server and transfer artifacts afterwards
-c, --clean Recreate the chroot before building
--inspect WHEN Spawn an interactive shell to inspect the chroot (never, always, failure)
--offline MODE Run a part of the build process offline (build, check)
-w, --worker SLOT Name of the worker slot, useful for concurrent builds (disables automatic names)
--nocheck Do not run the check() function in the PKGBUILD
@@ -80,8 +79,8 @@ pkgctl_build_usage() {
EXAMPLES
$ ${COMMAND}
$ ${COMMAND} --rebuild --staging --release --message 'libyay 0.42 rebuild' libfoo libbar
$ ${COMMAND} --pkgver=1.42 --release --db-update
$ ${COMMAND} --rebuild --staging --message 'libyay 0.42 rebuild' libfoo libbar
$ ${COMMAND} --pkgver 1.42 --release --db-update
_EOF_
}
@@ -199,10 +198,6 @@ pkgctl_build() {
EDIT=1
shift
;;
--offline)
MAKECHROOT_OPTIONS+=("-o" "$2")
shift 2
;;
-o|--offload)
OFFLOAD=1
shift
@@ -317,7 +312,7 @@ pkgctl_build() {
# Update pacman cache for auto-detection
if [[ -z ${REPO} ]]; then
update_pacman_repo_cache multilib
update_pacman_repo_cache
# Check valid repos if not resolved dynamically
elif ! in_array "${REPO}" "${DEVTOOLS_VALID_REPOS[@]}"; then
die "Invalid repository target: %s" "${REPO}"
@@ -442,11 +437,10 @@ pkgctl_build() {
stat_done
fi
# update checksums if any sources are declared
if (( UPDATE_CHECKSUMS )) && (( ${#source[@]} >= 1 )); then
if ! result=$(pkgbuild_update_checksums /dev/stderr); then
die "${result}"
fi
updpkgsums
fi
# re-source the PKGBUILD if it changed

View File

@@ -15,9 +15,6 @@ $DEVTOOLS_INCLUDE_COMMON_SH
# Avoid any encoding problems
export LANG=C.UTF-8
# Avoid systemd trying to color the terminal on systemd-nspawn
export SYSTEMD_TINT_BACKGROUND=no
# Set buildtool properties
export BUILDTOOL=devtools
export BUILDTOOLVER=@buildtoolver@
@@ -34,17 +31,6 @@ export PACKAGING_REPO_RELEASE_HOST=repos.archlinux.org
export PKGBASE_MAINTAINER_URL=https://archlinux.org/packages/pkgbase-maintainer
export AUR_URL_SSH=aur@aur.archlinux.org
export RSYNC_OPTS=(
--rsh=ssh
--checksum
--copy-links
--human-readable
--progress
--partial
--partial-dir=.partial
--delay-updates
)
# ensure TERM is set with a fallback to dumb
export TERM=${TERM:-dumb}
@@ -120,8 +106,6 @@ print_workdir_error() {
}
_setup_workdir=false
# Ensure that there is no outside value for WORKDIR leaking in
unset WORKDIR
setup_workdir() {
[[ -z ${WORKDIR:-} ]] && WORKDIR=$(mktemp -d --tmpdir "${0##*/}.XXXXXXXXXX")
_setup_workdir=true
@@ -358,17 +342,3 @@ is_debug_package() {
pkgdesc="$(getpkgdesc "${pkgfile}")"
[[ ${pkgdesc} == "Detached debugging symbols for "* && ${pkgbase}-debug = "${pkgname}" ]]
}
# Proxy function to check if a file exists. Using [[ -f ... ]] directly is not
# always wanted because we might want to expand bash globs first. This way we
# can pass unquoted globs to is_globfile() and have them expanded as function
# arguments before being checked.
is_globfile() {
[[ -f $1 ]]
}
join_by() {
local IFS="$1"
shift
echo "$*"
}

View File

@@ -8,12 +8,6 @@ DEVTOOLS_INCLUDE_DB_REMOVE_SH=1
_DEVTOOLS_LIBRARY_DIR=${_DEVTOOLS_LIBRARY_DIR:-@pkgdatadir@}
# shellcheck source=src/lib/common.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/common.sh
# shellcheck source=src/lib/util/pacman.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/util/pacman.sh
# shellcheck source=src/lib/util/term.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/util/term.sh
# shellcheck source=src/lib/valid-repos.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/valid-repos.sh
set -e
@@ -23,19 +17,10 @@ pkgctl_db_remove_usage() {
cat <<- _EOF_
Usage: ${COMMAND} [OPTIONS] [REPO] [PKGBASE]...
Remove packages from pacman repositories. By default passing a pkgbase removes
all split packages, debug packages as well as entries from the state repo for
all existing architectures.
Beware when using the --partial option, as it may most likely lead to
undesired effects by leaving debug packages behind as well as dangling entries
in the state repository.
Remove packages from binary repositories.
OPTIONS
-a, --arch Remove only one specific architecture (disables auto-detection)
--partial Remove only partial pkgnames from a split package. This leaves
debug packages behind and pkgbase entries in the state repo.
--noconfirm Bypass any confirmation messages, should only be used with caution
-a, --arch Override the architecture (disables auto-detection)
-h, --help Show this help text
EXAMPLES
@@ -46,13 +31,8 @@ _EOF_
pkgctl_db_remove() {
local REPO=""
local ARCH=any
local PKGBASES=()
local pkgnames=()
local partial=0
local confirm=1
local dbscripts_options=()
local lookup_repo=multilib
local pkgname
# option checking
while (( $# )); do
@@ -61,20 +41,11 @@ pkgctl_db_remove() {
pkgctl_db_remove_usage
exit 0
;;
--partial)
partial=1
dbscripts_options+=(--partial)
shift
;;
-a|--arch)
(( $# <= 1 )) && die "missing argument for %s" "$1"
dbscripts_options+=(--arch "$2")
ARCH=$2
shift 2
;;
--noconfirm)
confirm=0
shift
;;
-*)
die "invalid argument: %s" "$1"
;;
@@ -92,62 +63,7 @@ pkgctl_db_remove() {
REPO=$1
shift
PKGBASES+=("$@")
pkgnames=("${PKGBASES[@]}")
# check if the target repo is valid
if ! in_array "${REPO}" "${DEVTOOLS_VALID_REPOS[@]}"; then
die "Invalid repository target: %s" "${REPO}"
fi
# update pacman cache to query all pkgnames
if (( ! partial )); then
case ${REPO} in
*-unstable)
update_pacman_repo_cache unstable
;;
*-staging)
update_pacman_repo_cache multilib-staging
;;
*-testing)
update_pacman_repo_cache multilib-testing
;;
*)
update_pacman_repo_cache multilib
;;
esac
# fetch the pkgnames of all pkgbase as present in the repo
mapfile -t pkgnames < <(get_pkgnames_from_repo_pkgbase "${REPO}" "${PKGBASES[@]}")
echo
if (( ! ${#pkgnames[@]} )); then
error "Packages not found in %s" "${REPO}"
exit 1
fi
fi
# print list of packages
printf "%sRemoving packages from %s:%s\n" "${RED}" "${REPO}" "${ALL_OFF}"
for pkgname in "${pkgnames[@]}"; do
printf "• %s\n" "${pkgname}"
done
# print explenation about partial removal
if (( partial )); then
echo
msg_warn "${YELLOW}Removing only partial pkgnames from a split package.${ALL_OFF}"
msg_warn "${YELLOW}This leaves debug packages and pkgbase entries in the state repo!${ALL_OFF}"
fi
# ask for confirmation
if (( confirm )); then
echo
if ! prompt "${GREEN}${BOLD}?${ALL_OFF} Are you sure this is correct?"; then
exit 1
fi
fi
echo
# shellcheck disable=SC2029
ssh "${PACKAGING_REPO_RELEASE_HOST}" db-remove "${dbscripts_options[@]}" "${REPO}" "${PKGBASES[@]}"
ssh "${PACKAGING_REPO_RELEASE_HOST}" db-remove "${REPO}" "${ARCH}" "${PKGBASES[@]}"
}

234
src/lib/rebuild-todo.sh Normal file
View File

@@ -0,0 +1,234 @@
#!/hint/bash
#
# SPDX-License-Identifier: GPL-3.0-or-later
[[ -z ${DEVTOOLS_INCLUDE_REBUILD_TODO_SH:-} ]] || return 0
DEVTOOLS_INCLUDE_REBUILD_TODO_SH=1
_DEVTOOLS_LIBRARY_DIR=${_DEVTOOLS_LIBRARY_DIR:-@pkgdatadir@}
source /usr/share/makepkg/util/util.sh
# shellcheck source=src/lib/repo/clone.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/repo/clone.sh
# shellcheck source=src/lib/build/build.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/build/build.sh
# shellcheck source=src/lib/release.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/release.sh
set -e
pkgctl_rebuild_todo_usage() {
local -r COMMAND=${_DEVTOOLS_COMMAND:-${BASH_SOURCE[0]##*/}}
cat <<- _EOF_
Usage: ${COMMAND} [OPTIONS] URL
Rebuilds packages from a todo list.
OPTIONS
-h, --help Show this help text
-m, --message MSG Use the given <msg> as the commit message
-i, --ignore Give one or more pkgbases to ignore
-f, --maintainer Filter for one or more maintainers (orphan for orphan packages)
-o, --offload Build on a remote server and transfer artifacts afterwards
-e, --edit Edit PKGBUILD before building. Default when todo type is "Task"
-r, --repo REPO Specify a target repository (disables auto-detection)
-s, --staging Release to the staging counterpart of the auto-detected repo
-t, --testing Release to the testing counterpart of the auto-detected repo
-u, --db-update Automatically update the pacman database after uploading
--no-build Don't build PKGBUILD
--no-release Don't run commitpkg after building
EXAMPLES
TODO
_EOF_
}
pkgctl_rebuild_todo() {
if (( $# < 1 )); then
pkgctl_rebuild_todo_usage
exit 1
fi
local URL=""
local REPO=""
local MAINTAINERS=()
local IGNORE_PKGBASES=()
local FILTER_REPOSITORY=("extra")
local DRY_RUN=0
local MESSAGE_SET=0
local NO_RELEASE=0
local NO_BUILD=0
local RELEASE_OPTIONS=("--staging")
local BUILD_OPTIONS=("--staging" "--rebuild")
local packages
# option checking
while (( $# )); do
case $1 in
-h|--help)
pkgctl_rebuild_todo_usage
exit 0
;;
--dry-run)
DRY_RUN=1
shift 1
;;
-f|--maintainer)
(( $# <= 1 )) && die "missing argument for %s" "$1"
MAINTAINERS+=("$2")
shift 2
;;
-i|--ignore)
(( $# <= 1 )) && die "missing argument for %s" "$1"
IGNORE_PKGBASES+=("$2")
shift 2
;;
-o|--offload)
BUILD_OPTIONS+=("--offload")
shift
;;
-e|--edit)
BUILD_OPTIONS+=("--edit")
shift
;;
-m|--message)
(( $# <= 1 )) && die "missing argument for %s" "$1"
MESSAGE_SET=1
RELEASE_OPTIONS+=("--message" "$2")
shift 2
;;
-s|--staging)
RELEASE_OPTIONS+=("--staging")
shift
;;
-t|--testing)
RELEASE_OPTIONS+=("--testing")
shift
;;
--no-release)
NO_RELEASE=1
shift
;;
--no-build)
NO_BUILD=1
shift
;;
-*)
die "invalid option: %s" "$1"
;;
*)
if [[ ! "$1" == https* ]]; then
die "Missing url!"
fi
URL="$1"
if [[ ! "$URL" == */ ]]; then
URL+="/"
fi
if [[ ! "$URL" == *json ]]; then
URL+="json"
fi
break
;;
esac
done
# TODO: setup default values for options
while read -r json; do
readarray -t packages < <(jq --slurpfile repo <(printf '"%s" ' "${FILTER_REPOSITORY[@]}") \
--slurpfile maint <(printf '"%s" ' "${MAINTAINERS[@]}") \
-r '.created as $created
| .packages[]
| select(.status_str == "Incomplete" )
| select([.repo] | inside($repo))
| select(($maint[0] == "") or (($maint[0] == "orphan") and .maintainers == []) or (select(.maintainers | any([.] | inside($maint)))))
| "\(.pkgbase)"' \
- <<< "$json" | sort -u)
# This removes any elements we have ignored.... it's not pretty
readarray -t packages < <(comm -1 -3 <(printf "%s\n" "${IGNORE_PKGBASES[@]}" | sort) <(printf "%s\n" "${packages[@]}"| sort))
# Default to include the list name in the commit message
if (( ! MESSAGE_SET )); then
RELEASE_OPTIONS+=("--message" "$(jq -r '.name' - <<< "$json")")
fi
# If we are doing a Task we probably want to edit the PKGBUILD
if [[ "$(jq -r '.kind' - <<< "$json")" == "Task" ]]; then
BUILD_OPTIONS+=("--edit")
fi
done <<< "$(curl -s "$URL")"
if (( DRY_RUN )); then
msg "Would rebuild the following packages:"
msg2 '%s' "${packages[@]}"
msg "by running the following for each:"
if ! ((NO_BUILD)); then
msg2 "pkgctl build ${BUILD_OPTIONS[*]}"
fi
if ! ((NO_RELEASE)); then
msg2 "pkgctl release ${RELEASE_OPTIONS[*]}"
fi
exit 0
fi
if (( 0 == ${#packages[@]} )); then
die "No packages to rebuild!"
fi
msg "Rebuilding the following packages:"
msg2 '%s' "${packages[@]}"
msg "Press [Enter] to continue..."
read <&1
[[ -z ${WORKDIR:-} ]] && setup_workdir
pushd "$WORKDIR" &>/dev/null
# TODO set -j 1 to circumvent bug in repo clone
msg "Clone the pacakges"
if ! pkgctl_repo_clone -j 1 "${packages[@]}"; then
die "error while cloning packages"
fi
for pkg in "${packages[@]}"; do
pushd "$pkg" &>/dev/null
# This should help us figure out if the package is already built
readarray -t pkgs < <(makepkg --packagelist)
if [[ -f ${pkgs[0]} ]]; then
msg "${pkg[0]} has already been rebuilt!"
continue
fi
if ! ((NO_BUILD)); then
SKIP_BUILD=0
while true; do
# TODO: it seems like pkgctl build does not set the exit code correctly if (offload?) build fails
if pkgctl_build "${BUILD_OPTIONS[@]}"; then
break
fi
error "We failed to build! You are in a subshell to fix the build. Exit the shell to build again."
$SHELL || true
read -p "Skip build? [N/y] " -n 1 -r
if [[ $REPLY =~ ^[Yy]$ ]]; then
SKIP_BUILD=1
break
fi
done
if ((SKIP_BUILD)); then
popd &>/dev/null
continue
fi
fi
if ! ((NO_RELEASE)); then
pkgctl_release "${RELEASE_OPTIONS[@]}"
fi
popd &>/dev/null
done
}

View File

@@ -124,7 +124,7 @@ pkgctl_release() {
# Update pacman cache for auto-detection
if [[ -z ${REPO} ]]; then
update_pacman_repo_cache multilib
update_pacman_repo_cache
# Check valid repos if not resolved dynamically
elif ! in_array "${REPO}" "${DEVTOOLS_VALID_REPOS[@]}"; then
die "Invalid repository target: %s" "${REPO}"

View File

@@ -27,7 +27,6 @@ pkgctl_repo_usage() {
without SSH access using read-only HTTPS.
COMMANDS
clean Remove untracked files from the working tree
clone Clone a package repository
configure Configure a clone according to distro specs
create Create a new GitLab package repository
@@ -38,7 +37,6 @@ pkgctl_repo_usage() {
-h, --help Show this help text
EXAMPLES
$ ${COMMAND} clean --interactive *
$ ${COMMAND} clone libfoo linux libbar
$ ${COMMAND} clone --maintainer mynickname
$ ${COMMAND} configure *
@@ -61,14 +59,6 @@ pkgctl_repo() {
pkgctl_repo_usage
exit 0
;;
clean)
_DEVTOOLS_COMMAND+=" $1"
shift
# shellcheck source=src/lib/repo/clean.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/repo/clean.sh
pkgctl_repo_clean "$@"
exit 0
;;
clone)
_DEVTOOLS_COMMAND+=" $1"
shift

View File

@@ -1,114 +0,0 @@
#!/bin/bash
#
# SPDX-License-Identifier: GPL-3.0-or-later
[[ -z ${DEVTOOLS_INCLUDE_REPO_CLEAN_SH:-} ]] || return 0
DEVTOOLS_INCLUDE_REPO_CLEAN_SH=1
_DEVTOOLS_LIBRARY_DIR=${_DEVTOOLS_LIBRARY_DIR:-@pkgdatadir@}
# shellcheck source=src/lib/common.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/common.sh
source /usr/share/makepkg/util/message.sh
set -eo pipefail
pkgctl_repo_clean_usage() {
local -r COMMAND=${_DEVTOOLS_COMMAND:-${BASH_SOURCE[0]##*/}}
cat <<- _EOF_
Usage: ${COMMAND} [OPTION] [PATH]...
Cleans the working tree by recursively removing files that are not under
version control, starting from the current directory.
Files unknown to Git as well as ignored files are removed. This can, for
example, be useful to remove all build products.
OPTIONS
-i, --interactive Show what would be done and clean files interactively
-n, --dry-run Don't remove anything, just show what would be done
-h, --help Show this help text
EXAMPLES
$ ${COMMAND} libfoo linux libbar
$ ${COMMAND} --interactive libfoo linux libbar
$ ${COMMAND} --dry-run *
_EOF_
}
pkgctl_repo_clean() {
# options
local git_clean_options=()
local paths
local path pkgbase
while (( $# )); do
case $1 in
-i|--interactive)
git_clean_options+=("$1")
shift
;;
-n|--dry-run)
git_clean_options+=("$1")
shift
;;
-h|--help)
pkgctl_repo_clean_usage
exit 0
;;
--)
shift
break
;;
-*)
die "invalid argument: %s" "$1"
;;
*)
paths=("$@")
break
;;
esac
done
# check if invoked without any path from within a packaging repo
if (( ${#paths[@]} == 0 )); then
paths=(".")
fi
# print message about the work chunk
printf "🗑️ Removing untracked files from %s working trees\n" "${BOLD}${#paths[@]}${ALL_OFF}"
for path in "${paths[@]}"; do
# skip paths that are not directories
if [[ ! -d "${path}" ]]; then
continue
fi
if [[ ! -f "${path}/PKGBUILD" ]]; then
msg_error "Not a package repository: ${path}"
continue
fi
if [[ ! -d "${path}/.git" ]]; then
msg_error "Not a Git repository: ${path}"
continue
fi
pkgbase=$(basename "$(realpath "${path}")")
pkgbase=${pkgbase%.git}
# run dry mode to see if git would clean any files
if [[ ! $(git -C "${path}" clean -x -d --dry-run 2>&1) ]]; then
continue
fi
# git clean untracked files
msg_success "Cleaning ${BOLD}${pkgbase}${ALL_OFF}"
if ! git -C "${path}" clean -x -d --force "${git_clean_options[@]}"; then
msg_error "Failed to remove untracked files"
fi
echo
done
}

View File

@@ -271,7 +271,6 @@ pkgctl_repo_configure() {
if [[ -n $GPGKEY ]]; then
git config commit.gpgsign true
git config user.signingKey "${GPGKEY}"
git config gpg.format openpgp
fi
# set default git exclude

View File

@@ -22,11 +22,9 @@ makepkg_source_package() {
return
fi
(
# shellcheck disable=SC2030 disable=SC2031
export LIBMAKEPKG_LINT_PKGBUILD_SH=1
lint_pkgbuild() { :; }
# shellcheck disable=SC2030 disable=SC2031
export LIBMAKEPKG_SRCINFO_SH=1
write_srcinfo() { print_srcinfo; }
@@ -37,21 +35,3 @@ makepkg_source_package() {
source "$(command -v makepkg)"
)
}
makepkg_generate_integrity() {
if [[ -z ${DEVTOOLS_GENERATE_INTEGRITY} ]]; then
[[ -z ${WORKDIR:-} ]] && setup_workdir
export WORKDIR DEVTOOLS_INCLUDE_COMMON_SH
bash -$- -c "DEVTOOLS_GENERATE_INTEGRITY=1; source '${BASH_SOURCE[0]}' && ${FUNCNAME[0]}"
return
fi
(
# shellcheck disable=SC2030 disable=SC2031
export LIBMAKEPKG_LINT_PKGBUILD_SH=1
lint_pkgbuild() { :; }
set +e -- --geninteg
# shellcheck source=/usr/bin/makepkg
source "$(command -v makepkg)"
)
}

View File

@@ -18,12 +18,10 @@ readonly _DEVTOOLS_MAKEPKG_CONF_DIR=${_DEVTOOLS_LIBRARY_DIR}/makepkg.conf.d
update_pacman_repo_cache() {
local repo=${1:-multilib}
mkdir -p "${_DEVTOOLS_PACMAN_CACHE_DIR}"
msg "Updating pacman database cache"
lock 10 "${_DEVTOOLS_PACMAN_CACHE_DIR}.lock" "Locking pacman database cache"
fakeroot -- pacman --config "${_DEVTOOLS_PACMAN_CONF_DIR}/${repo}.conf" \
fakeroot -- pacman --config "${_DEVTOOLS_PACMAN_CONF_DIR}/multilib.conf" \
--dbpath "${_DEVTOOLS_PACMAN_CACHE_DIR}" \
-Sy
lock_close 10
@@ -31,7 +29,6 @@ update_pacman_repo_cache() {
get_pacman_repo_from_pkgbuild() {
local path=${1:-PKGBUILD}
local repo=${2:-multilib}
# shellcheck source=contrib/makepkg/PKGBUILD.proto
mapfile -t pkgnames < <(source "${path}"; printf "%s\n" "${pkgname[@]}")
@@ -43,12 +40,12 @@ get_pacman_repo_from_pkgbuild() {
# update the pacman repo cache if it doesn't exist yet
if [[ ! -d "${_DEVTOOLS_PACMAN_CACHE_DIR}" ]]; then
update_pacman_repo_cache "${repo}"
update_pacman_repo_cache
fi
slock 10 "${_DEVTOOLS_PACMAN_CACHE_DIR}.lock" "Locking pacman database cache"
# query repo of passed pkgname, specify --nodeps twice to skip all dependency checks
mapfile -t repos < <(pacman --config "${_DEVTOOLS_PACMAN_CONF_DIR}/${repo}.conf" \
mapfile -t repos < <(pacman --config "${_DEVTOOLS_PACMAN_CONF_DIR}/multilib.conf" \
--dbpath "${_DEVTOOLS_PACMAN_CACHE_DIR}" \
--sync \
--nodeps \
@@ -61,30 +58,3 @@ get_pacman_repo_from_pkgbuild() {
printf "%s" "${repos[0]}"
}
get_pkgnames_from_repo_pkgbase() {
local repo=$1
shift
local pkgbases=("$@")
# update the pacman repo cache if it doesn't exist yet
if [[ ! -d "${_DEVTOOLS_PACMAN_CACHE_DIR}" ]]; then
update_pacman_repo_cache universe
fi
slock 10 "${_DEVTOOLS_PACMAN_CACHE_DIR}.lock" "Locking pacman database cache"
# query pkgnames of passed pkgbase inside a repo
mapfile -t pkgnames < <(expac --config <(sed "s|#DBPath.*|DBPath = $(realpath "${_DEVTOOLS_PACMAN_CACHE_DIR}")|" < "${_DEVTOOLS_PACMAN_CONF_DIR}/universe.conf") \
--sync '%r %e %n' 2>/dev/null \
| sort | awk -v pkgbase="${pkgbases[*]}" \
'BEGIN { split(pkgbase, array); for (item in array) filter[array[item]]=1 } $1=="'"${repo}"'" && $2 in filter {print $3}'
)
lock_close 10
if (( ! ${#pkgnames[@]} )); then
return 1
fi
printf "%s\n" "${pkgnames[@]}"
return 0
}

View File

@@ -6,13 +6,10 @@
DEVTOOLS_INCLUDE_UTIL_PKGBUILD_SH=1
_DEVTOOLS_LIBRARY_DIR=${_DEVTOOLS_LIBRARY_DIR:-@pkgdatadir@}
# shellcheck source=src/lib/util/makepkg.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/util/makepkg.sh
source /usr/share/makepkg/util/message.sh
source /usr/share/makepkg/util/schema.sh
set -eo pipefail
set -e
# set the pkgver variable in a PKGBUILD
@@ -44,48 +41,3 @@ pkgbuild_set_pkgrel() {
sed --regexp-extended "s|^(pkgrel=)${pkgrel}$|\1${new_pkgrel}|g" --in-place PKGBUILD
}
pkgbuild_update_checksums() {
local status_file=$1
local builddir newbuildfile sumtypes newsums
[[ -z ${WORKDIR:-} ]] && setup_workdir
builddir=$(mktemp --tmpdir="${WORKDIR}" --directory update-checksums.XXXXXX)
newbuildfile="${builddir}/PKGBUILD"
# generate new integrity checksums
if ! newsums=$(BUILDDIR=${builddir} makepkg_generate_integrity 2>"${status_file}"); then
printf 'Failed to generate new checksums'
return 1
fi
# early exit if no integrity checksums are needed
if [[ -z ${newsums} ]]; then
return 0
fi
# replace the integrity sums and write it to a temporary file
sumtypes=$(IFS='|'; echo "${known_hash_algos[*]}")
if ! awk --assign=sumtypes="${sumtypes}" --assign=newsums="${newsums}" '
$0 ~"^[[:blank:]]*(" sumtypes ")sums(_[^=]+)?\\+?=", $0 ~ "\\)[[:blank:]]*(#.*)?$" {
if (!w) {
print newsums
w++
}
next
}
1
END { if (!w) print newsums }' PKGBUILD > "${newbuildfile}"; then
printf 'Failed to replace the generated checksums'
return 1
fi
# overwrite the original PKGBUILD while preserving permissions
if ! cat -- "${newbuildfile}" > PKGBUILD; then
printf "Failed to write to the PKGBUILD file"
return 1
fi
return 0
}

View File

@@ -180,19 +180,3 @@ term_spinner_stop() {
# show the cursor after stopping the spinner
term_cursor_show
}
prompt() {
local message=$1
local answer
read -r -p "${message} (y/N) " answer
case "${answer}" in
y|Y|yes|Yes|YES)
true
;;
*)
false
;;
esac
}

View File

@@ -3,14 +3,9 @@
# SPDX-License-Identifier: GPL-3.0-or-later
:
# shellcheck disable=2034
DEVTOOLS_VALID_BINARY_ARCHES=(
x86_64
)
# shellcheck disable=2034
DEVTOOLS_VALID_ARCHES=(
"${DEVTOOLS_VALID_BINARY_ARCHES[@]}"
x86_64
any
)

View File

@@ -19,7 +19,6 @@ pkgctl_version_usage() {
COMMANDS
check Compares local package versions against upstream
setup Automatically detect and setup a basic nvchecker config
upgrade Adjust the PKGBUILD to match the latest upstream version
OPTIONS
@@ -27,7 +26,6 @@ pkgctl_version_usage() {
EXAMPLES
$ ${COMMAND} check libfoo linux libbar
$ ${COMMAND} setup libfoo
_EOF_
}
@@ -59,14 +57,6 @@ pkgctl_version() {
pkgctl_version_upgrade "$@"
exit $?
;;
setup)
_DEVTOOLS_COMMAND+=" $1"
shift
# shellcheck source=src/lib/version/setup.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/version/setup.sh
pkgctl_version_setup "$@"
exit 0
;;
*)
die "invalid argument: %s" "$1"
;;

View File

@@ -114,6 +114,10 @@ pkgctl_version_check() {
fi
pushd "${path}" >/dev/null
if [[ ! -f "PKGBUILD" ]]; then
die "No PKGBUILD found for ${path}"
fi
# update the current terminal spinner status
(( ++current_item ))
pkgctl_version_check_spinner \
@@ -124,13 +128,6 @@ pkgctl_version_check() {
"${current_item}" \
"${#pkgbases[@]}"
if [[ ! -f "PKGBUILD" ]]; then
result="${BOLD}${path}${ALL_OFF}: no PKGBUILD found"
failure+=("${result}")
popd >/dev/null
continue
fi
# reset common PKGBUILD variables
unset pkgbase pkgname arch source pkgver pkgrel validpgpkeys
# shellcheck source=contrib/makepkg/PKGBUILD.proto
@@ -226,8 +223,8 @@ get_upstream_version() {
opts+=(--keyfile "${keyfile}")
fi
if ! output=$(GIT_TERMINAL_PROMPT=0 nvchecker --file "${config}" --logger json "${opts[@]}" 2>&1 | \
jq --raw-output 'select((.level != "debug") and (.event != "ignoring invalid version"))'); then
if ! output=$(nvchecker --file "${config}" --logger json "${opts[@]}" 2>&1 | \
jq --raw-output 'select(.level != "debug")'); then
printf "failed to run nvchecker: %s" "${output}"
return 1
fi
@@ -267,13 +264,13 @@ nvchecker_check_config() {
done
# check if the config contains a pkgbase section
if [[ -n ${pkgbase} ]] && ! grep --max-count=1 --extended-regexp --quiet "^\\[\"?${pkgbase//+/\\+}\"?\\]" < "${config}"; then
if [[ -n ${pkgbase} ]] && ! grep --max-count=1 --extended-regexp --quiet "^\\[\"?${pkgbase}\"?\\]" < "${config}"; then
printf "missing pkgbase section in %s: %s" "${config}" "${pkgbase}"
return 1
fi
# check if the config contains any section other than pkgbase
if [[ -n ${pkgbase} ]] && property=$(grep --max-count=1 --perl-regexp "^\\[(?!\"?${pkgbase//+/\\+}\"?\\]).+\\]" < "${config}"); then
if [[ -n ${pkgbase} ]] && property=$(grep --max-count=1 --perl-regexp "^\\[(?!\"?${pkgbase}\"?\\]).+\\]" < "${config}"); then
printf "non-pkgbase section not supported in %s: %s" "${config}" "${property}"
return 1
fi
@@ -284,7 +281,7 @@ nvchecker_check_error() {
local errors
if ! errors=$(jq --raw-output --exit-status \
'select((.level == "error") and (.error != null)) | "\(.event)" + if .error then ": \(.error)" else "" end' \
'select(.level == "error") | "\(.event)" + if .error then ": \(.error)" else "" end' \
<<< "${result}"); then
return 0
fi

View File

@@ -1,528 +0,0 @@
#!/bin/bash
#
# SPDX-License-Identifier: GPL-3.0-or-later
#
[[ -z ${DEVTOOLS_INCLUDE_VERSION_SETUP_SH:-} ]] || return 0
DEVTOOLS_INCLUDE_VERSION_SETUP_SH=1
_DEVTOOLS_LIBRARY_DIR=${_DEVTOOLS_LIBRARY_DIR:-@pkgdatadir@}
# shellcheck source=src/lib/common.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/common.sh
# shellcheck source=src/lib/version/check.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/version/check.sh
source /usr/share/makepkg/util/message.sh
source /usr/share/makepkg/util/source.sh
set -eo pipefail
pkgctl_version_setup_usage() {
local -r COMMAND=${_DEVTOOLS_COMMAND:-${BASH_SOURCE[0]##*/}}
cat <<- _EOF_
Usage: ${COMMAND} [OPTIONS] [PKGBASE]...
Automate the creation of a basic nvchecker configuration file by
analyzing the source array specified in the PKGBUILD file of a package.
If no PKGBASE is specified, the command defaults to using the current
working directory.
OPTIONS
-f, --force Overwrite existing nvchecker configuration
--prefer-platform-api Prefer platform specific GitHub/GitLab API for complex cases
--url URL Derive check target from URL instead of source array
--no-check Do not run version check after setup
-h, --help Show this help text
EXAMPLES
$ ${COMMAND} neovim vim
_EOF_
}
pkgctl_version_setup() {
local pkgbases=()
local override_url=
local run_check=1
local force=0
local prefer_platform_api=0
local path ret
local checks=()
while (( $# )); do
case $1 in
-h|--help)
pkgctl_version_setup_usage
exit 0
;;
-f|--force)
force=1
shift
;;
--prefer-platform-api)
prefer_platform_api=1
shift
;;
--url)
(( $# <= 1 )) && die "missing argument for %s" "$1"
override_url=$2
shift 2
;;
--no-check)
run_check=0
shift
;;
--)
shift
break
;;
-*)
die "invalid argument: %s" "$1"
;;
*)
pkgbases=("$@")
break
;;
esac
done
# Check if used without pkgbases in a packaging directory
if (( ${#pkgbases[@]} == 0 )); then
if [[ -f PKGBUILD ]]; then
pkgbases=(".")
else
pkgctl_version_setup_usage
exit 1
fi
fi
ret=0
for path in "${pkgbases[@]}"; do
# skip paths that are not directories
if [[ ! -d "${path}" ]]; then
continue
fi
pushd "${path}" >/dev/null
if nvchecker_setup "${path}" "${force}" "${prefer_platform_api}" "${override_url}"; then
checks+=("${path}")
else
ret=1
fi
popd >/dev/null
done
# run checks on the setup targets
if (( run_check )) && (( ${#checks[@]} >= 1 )); then
echo
pkgctl_version_check --verbose "${checks[@]}" || true
fi
return $ret
}
nvchecker_setup() {
local path=$1
local force=$2
local prefer_platform_api=$3
local override_url=$4
local pkgbase pkgname source source_url proto domain url_parts section body
if [[ ! -f PKGBUILD ]]; then
msg_error "${BOLD}${path}:${ALL_OFF} no PKGBUILD found"
return 1
fi
unset body pkgbase pkgname source url
# shellcheck source=contrib/makepkg/PKGBUILD.proto
if ! . ./PKGBUILD; then
msg_error "${BOLD}${path}:${ALL_OFF} failed to source PKGBUILD"
return 1
fi
pkgbase=${pkgbase:-$pkgname}
# try to guess from url as last try
if [[ -n ${url} ]]; then
source+=("${url}")
fi
# handle overwrite of existing config
if [[ -f .nvchecker.toml ]] && (( ! force )); then
msg_warn "${BOLD}${pkgbase}:${ALL_OFF} nvchecker already configured"
return 1
fi
# override the source array with a passed URL
if [[ -n ${override_url} ]]; then
source=("${override_url}")
fi
# skip empty source array
if (( ${#source[@]} == 0 )); then
msg_error "${BOLD}${pkgbase}:${ALL_OFF} PKGBUILD has no source array"
return 1
fi
for source_url in "${source[@]}"; do
# Strips out filename::http for example
source_url=$(get_url "${source_url}")
# discard query fragments
source_url=${source_url%\?*}
source_url=${source_url%#*}
# skip patches
if [[ ${source_url} == *.patch ]]; then
continue
fi
# skip signatures
if [[ ${source_url} == *.asc ]] || [[ ${source_url} == *.sig ]]; then
continue
fi
# skip local files
if [[ ${source_url} != *://* ]]; then
continue
fi
# split URL segments while avoiding empty element after protocol and newline at the end
mapfile -td / url_parts <<< "${source_url/:\/\//\/}/"
unset "url_parts[-1]"
# extract protocol and domain to select the configuration type
proto=${url_parts[0]}
domain=${url_parts[1]}
case "${domain}" in
gitlab.*)
if (( prefer_platform_api )); then
body=$(nvchecker_setup_gitlab "${url_parts[@]}")
else
body=$(nvchecker_setup_git "${url_parts[@]}")
fi
break
;;
github.com)
if (( prefer_platform_api )); then
body=$(nvchecker_setup_github "${url_parts[@]}")
else
body=$(nvchecker_setup_git "${url_parts[@]}")
fi
break
;;
codeberg.org)
body=$(nvchecker_setup_git "${url_parts[@]}")
break
;;
pypi.org|pypi.io|files.pythonhosted.org)
body=$(nvchecker_setup_pypi "${url_parts[@]}")
break
;;
hackage.haskell.org)
body=$(nvchecker_setup_hackage "${url_parts[@]}")
break
;;
registry.npmjs.org|npmjs.com|www.npmjs.com)
body=$(nvchecker_setup_npm "${url_parts[@]}")
break
;;
rubygems.org)
body=$(nvchecker_setup_rubygems "${url_parts[@]}")
break
;;
*.cpan.org|*.mcpan.org|*.metacpan.org)
body=$(nvchecker_setup_cpan "${url_parts[@]}")
break
;;
crates.io|*.crates.io)
body=$(nvchecker_setup_crates_io "${url_parts[@]}")
break
;;
*)
if [[ ${proto} == git ]] || [[ ${proto} == git+https ]]; then
body=$(nvchecker_setup_git "${url_parts[@]}")
fi
;;
esac
done
if [[ -z "${body}" ]]; then
msg_error "${BOLD}${pkgbase}:${ALL_OFF} unable to automatically setup nvchecker"
return 1
fi
# escape the section if it contains toml subsection chars
section="${pkgbase}"
if [[ ${section} == *.* ]] || [[ ${section} == *+* ]]; then
section="\"${section}\""
fi
msg_success "${BOLD}${pkgbase}:${ALL_OFF} successfully configured nvchecker"
cat > .nvchecker.toml << EOF
[${section}]
${body}
EOF
}
get_git_url_from_parts() {
local url_parts=("$@")
local proto=${url_parts[0]#*+}
local domain=${url_parts[1]}
local url
url="${proto}://$(join_by / "${url_parts[@]:1}")"
case "${domain}" in
gitlab.*)
url=${url%/-/*/*}
[[ ${url} != *.git ]] && url+=.git
;;
github.com|codeberg.org)
url="${proto}://$(join_by / "${url_parts[@]:1:3}")"
[[ ${url} != *.git ]] && url+=.git
;;
esac
printf '%s' "${url}"
}
# PyPI
#
# As Arch python packages don't necessarily match the pypi name, when the
# provided source url comes from pypi.io or pypi.org try to extract the package
# name from the (predictable) tarball download url for example:
#
# https://pypi.io/packages/source/p/pyflakes/pyflakes-3.1.0.tar.gz
# https://pypi.io/packages/source/p/pyflakes
# https://pypi.org/packages/source/b/bleach
# https://files.pythonhosted.org/packages/source/p/pyflakes
# https://pypi.org/project/SQLAlchemy/
nvchecker_setup_pypi() {
local url_parts=("$@")
local pypi
if [[ ${url_parts[2]} == packages ]]; then
pypi=${url_parts[5]}
elif [[ ${url_parts[2]} == project ]]; then
pypi=${url_parts[3]}
else
return 1
fi
cat << EOF
source = "pypi"
pypi = "${pypi}"
EOF
}
# Git
#
# Set up a generic Git source, while removing the proto specific part from makepkg
#
# git+https://github.com/prometheus/prometheus.git
# https://git.foobar.com/some/path/group/project.git
# https://gitlab.com/sub/group/project/-/archive/8.0.0/packages-8.0.0.tar.gz
nvchecker_setup_git() {
local url_parts=("$@")
local url
url=$(get_git_url_from_parts "${url_parts[@]}")
cat << EOF
source = "git"
git = "${url}"
EOF
# best effort check if the tags are prefixed with v
if git_tags_have_version_prefix "${url}"; then
echo 'prefix = "v"'
fi
}
git_tags_have_version_prefix() {
local url=$1
# best effort check if the tags are prefixed with v
if ! grep --max-count=1 --quiet --extended-regex 'refs/tags/v[0-9]+[\.0-9]*$' \
<(GIT_TERMINAL_PROMPT=0 git ls-remote --quiet --tags "${url}" 2>/dev/null); then
return 1
fi
return 0
}
# Github
#
# We want to know the $org/$project name from the url
#
# https://github.com/prometheus/prometheus/archive/v2.49.1.tar.gz
nvchecker_setup_github() {
local url_parts=("$@")
local url project
if ! url=$(get_git_url_from_parts "${url_parts[@]}"); then
return 1
fi
project=${url#*://*/}
project=${project%.git}
cat << EOF
source = "github"
github = "${project}"
use_max_tag = true
EOF
# best effort check if the tags are prefixed with v
if git_tags_have_version_prefix "${url}"; then
echo 'prefix = "v"'
fi
}
# GitLab
#
# We want to know the $org/$project name from the url
#
# git+https://gitlab.com/inkscape/inkscape.git#tag=091e20ef0f204eb40ecde54436e1ef934a03d894
nvchecker_setup_gitlab() {
local url_parts=("$@")
local url project host
if ! url=$(get_git_url_from_parts "${url_parts[@]}"); then
return 1
fi
project=${url#*://*/}
project=${project%.git}
cat << EOF
source = "gitlab"
gitlab = "${project}"
EOF
host=${url#*://}
host=${host%%/*}
if [[ ${host} != gitlab.com ]]; then
echo "host = \"${host}\""
fi
echo "use_max_tag = true"
# best effort check if the tags are prefixed with v
if git_tags_have_version_prefix "${url}"; then
echo 'prefix = "v"'
fi
}
# Hackage
#
# We want to know the project name
#
# https://hackage.haskell.org/package/xmonad
# https://hackage.haskell.org/package/xmonad-0.18.0/xmonad-0.18.0.tar.gz
# https://hackage.haskell.org/packages/archive/digits/0.3.1/digits-0.3.1.tar.gz
nvchecker_setup_hackage() {
local url_parts=("$@")
local hackage
if [[ ${url_parts[2]} == packages ]]; then
hackage=${url_parts[4]}
elif [[ ${url_parts[2]} == package ]] && (( ${#url_parts[@]} == 4 )); then
hackage=${url_parts[3]}
elif [[ ${url_parts[2]} == package ]] && (( ${#url_parts[@]} >= 5 )); then
hackage=${url_parts[3]%-*}
else
return 1
fi
cat << EOF
source = "hackage"
hackage = "${hackage}"
EOF
}
# NPM
#
# We want to know the project name
#
# https://registry.npmjs.org/eslint_d/-/eslint_d-12.1.0.tgz
# https://www.npmjs.com/package/node-gyp
nvchecker_setup_npm() {
local url_parts=("$@")
local npm
if [[ ${url_parts[1]} == registry.npmjs.org ]]; then
npm=${url_parts[2]}
elif [[ ${url_parts[2]} == package ]] && (( ${#url_parts[@]} == 4 )); then
npm=${url_parts[3]}
else
return 1
fi
cat << EOF
source = "npm"
npm = "${npm}"
EOF
}
# RubyGems
#
# We want to know the project name
#
# https://rubygems.org/downloads/polyglot-0.3.5.gem
# https://rubygems.org/gems/diff-lcs
nvchecker_setup_rubygems() {
local url_parts=("$@")
local gem
if [[ ${url_parts[2]} == downloads ]]; then
gem=${url_parts[-1]%-*}
elif [[ ${url_parts[2]} == gems ]]; then
gem=${url_parts[3]}
else
return 1
fi
cat << EOF
source = "gems"
gems = "${gem}"
EOF
}
# CPAN
#
# We want to know the project name
#
# source = https://search.cpan.org/CPAN/authors/id/C/CO/COSIMO/Locale-PO-1.2.3.tar.gz
nvchecker_setup_cpan() {
local url_parts=("$@")
local cpan=${url_parts[-1]}
cpan=${cpan%-*}
cat << EOF
source = "cpan"
cpan = "${cpan}"
EOF
}
# crates.io
#
# We want to know the crate name
#
# https://crates.io/api/v1/crates/${pkgname}/${pkgver}/download
# https://static.crates.io/crates/${pkgname}/$pkgname-$pkgver.crate
# https://crates.io/crates/git-smash
nvchecker_setup_crates_io() {
local url_parts=("$@")
local crate
if [[ ${url_parts[2]} == crates ]]; then
crate=${url_parts[3]}
elif [[ ${url_parts[4]} == crates ]]; then
crate=${url_parts[5]}
else
return 1
fi
for i in "${!url_parts[@]}"; do
if [[ ${url_parts[i]} == crates ]]; then
crate=${url_parts[(( i + 1 ))]}
fi
done
cat << EOF
source = "cratesio"
cratesio = "${crate}"
EOF
}

View File

@@ -30,15 +30,14 @@ pkgctl_version_upgrade_usage() {
Upon execution, it automatically adjusts the PKGBUILD file, ensuring that the
pkgver field is set to match the latest version available from the upstream
source. In addition to updating the pkgver, this command also resets the pkgrel
to 1 and updates checksums.
to 1.
Outputs a summary of upgraded packages, up-to-date packages, and any check
failures.
OPTIONS
--no-update-checksums Disable computation and update of the checksums
-v, --verbose Display results including up-to-date versions
-h, --help Show this help text
-v, --verbose Display results including up-to-date versions
-h, --help Show this help text
EXAMPLES
$ ${COMMAND} neovim vim
@@ -51,7 +50,6 @@ pkgctl_version_upgrade() {
local verbose=0
local exit_code=0
local current_item=0
local update_checksums=1
while (( $# )); do
case $1 in
@@ -59,10 +57,6 @@ pkgctl_version_upgrade() {
pkgctl_version_upgrade_usage
exit 0
;;
--no-update-checksums)
update_checksums=0
shift
;;
-v|--verbose)
verbose=1
shift
@@ -111,31 +105,25 @@ pkgctl_version_upgrade() {
fi
pushd "${path}" >/dev/null
(( ++current_item ))
if [[ ! -f "PKGBUILD" ]]; then
result="${BOLD}${path}${ALL_OFF}: no PKGBUILD found"
failure+=("${result}")
popd >/dev/null
continue
die "No PKGBUILD found for ${path}"
fi
# reset common PKGBUILD variables
unset pkgbase pkgname arch source pkgver pkgrel validpgpkeys
# shellcheck source=contrib/makepkg/PKGBUILD.proto
. ./PKGBUILD
pkgbase=${pkgbase:-$pkgname}
# update the current terminal spinner status
(( ++current_item ))
pkgctl_version_upgrade_spinner \
"${status_dir}" \
"${#up_to_date[@]}" \
"${#out_of_date[@]}" \
"${#failure[@]}" \
"${current_item}" \
"${#pkgbases[@]}" \
"${pkgbase}" \
"query latest version"
"${#pkgbases[@]}"
# reset common PKGBUILD variables
unset pkgbase pkgname arch source pkgver pkgrel validpgpkeys
# shellcheck source=contrib/makepkg/PKGBUILD.proto
. ./PKGBUILD
pkgbase=${pkgbase:-$pkgname}
if ! result=$(get_upstream_version); then
result="${BOLD}${pkgbase}${ALL_OFF}: ${result}"
@@ -165,24 +153,6 @@ pkgctl_version_upgrade() {
# change the PKGBUILD
pkgbuild_set_pkgver "${upstream_version}"
pkgbuild_set_pkgrel 1
# download sources and update the checksums
if (( update_checksums )); then
pkgctl_version_upgrade_spinner \
"${status_dir}" \
"${#up_to_date[@]}" \
"${#out_of_date[@]}" \
"${#failure[@]}" \
"${current_item}" \
"${#pkgbases[@]}" \
"${pkgbase}" \
"updating checksums"
if ! result=$(pkgbuild_update_checksums /dev/null); then
result="${BOLD}${pkgbase}${ALL_OFF}: failed to update checksums for version ${DARK_GREEN}${upstream_version}${ALL_OFF}"
failure+=("${result}")
fi
fi
fi
popd >/dev/null
@@ -261,8 +231,6 @@ pkgctl_version_upgrade_spinner() {
local failure_count=$4
local current=$5
local total=$6
local pkgbase=$7
local message=$8
local percentage=$(( 100 * current / total ))
local tmp_file="${status_dir}/tmp"
@@ -275,10 +243,8 @@ pkgctl_version_upgrade_spinner() {
"${failure_count}" > "${tmp_file}"
# print the progress status
printf "📡 %s: %s\n" \
"${pkgbase}" "${BOLD}${message}${ALL_OFF}" >> "${tmp_file}"
printf "⌛ Upgrading: %s/%s [%s] %%spinner%%" \
"${BOLD}${current}" "${total}" "${percentage}%${ALL_OFF}" \
printf "📡 Upgrading: %s/%s [%s] %%spinner%%" \
"${BOLD}${current}" "${total}" "${percentage}%${ALL_OFF}" \
>> "${tmp_file}"
# swap the status file

View File

@@ -38,9 +38,6 @@ inspect=never
bindmounts_ro=()
bindmounts_rw=()
bindmounts_tmpfs=()
offline_options=()
copy=$USER
[[ -n ${SUDO_USER:-} ]] && copy=$SUDO_USER
@@ -68,25 +65,23 @@ usage() {
echo "Default makepkg args: ${default_makepkg_args[*]}"
echo ''
echo 'Flags:'
echo '-h This help'
echo '-c Clean the chroot before building'
echo '-d <dir> Bind directory into build chroot as read-write'
echo '-D <dir> Bind directory into build chroot as read-only'
echo '-t <dir[:opts]> Mount a tmpfs at directory'
echo '-u Update the working copy of the chroot before building'
echo ' This is useful for rebuilds without dirtying the pristine'
echo ' chroot'
echo '-r <dir> The chroot dir to use'
echo '-I <pkg> Install a package into the working copy of the chroot'
echo '-l <copy> The directory to use as the working copy of the chroot'
echo ' Useful for maintaining multiple copies'
echo " Default: $copy"
echo '-n Run namcap on the package'
echo '-o Run given step offline'
echo '-C Run checkpkg on the package'
echo '-T Build in a temporary directory'
echo '-U Run makepkg as a specified user'
echo '-x <when> Inspect chroot after build (never, always, failure)'
echo '-h This help'
echo '-c Clean the chroot before building'
echo '-d <dir> Bind directory into build chroot as read-write'
echo '-D <dir> Bind directory into build chroot as read-only'
echo '-u Update the working copy of the chroot before building'
echo ' This is useful for rebuilds without dirtying the pristine'
echo ' chroot'
echo '-r <dir> The chroot dir to use'
echo '-I <pkg> Install a package into the working copy of the chroot'
echo '-l <copy> The directory to use as the working copy of the chroot'
echo ' Useful for maintaining multiple copies'
echo " Default: $copy"
echo '-n Run namcap on the package'
echo '-C Run checkpkg on the package'
echo '-T Build in a temporary directory'
echo '-U Run makepkg as a specified user'
echo '-x <when> Inspect chroot after build (never, always, failure)'
exit 1
}
@@ -108,7 +103,7 @@ sync_chroot() {
"Locking clean chroot [%s]" "$chrootdir/root"
stat_busy "Synchronizing chroot copy [%s] -> [%s]" "$chrootdir/root" "$copy"
if is_btrfs "$chrootdir" && is_subvolume "$chrootdir/root" && ! mountpoint -q "$copydir"; then
if is_btrfs "$chrootdir" && ! mountpoint -q "$copydir"; then
subvolume_delete_recursive "$copydir" ||
die "Unable to delete subvolume %s" "$copydir"
btrfs subvolume snapshot "$chrootdir/root" "$copydir" >/dev/null ||
@@ -153,8 +148,8 @@ install_packages() {
pkgnames=("${install_pkgs[@]##*/}")
cp -- "${install_pkgs[@]}" "$copydir/root/"
arch-nspawn "$copydir" "${bindmounts_ro[@]}" "${bindmounts_rw[@]}" "${bindmounts_tmpfs[@]}" \
pacman -U --noconfirm --ask=4 -- "${pkgnames[@]/#//root/}"
arch-nspawn "$copydir" "${bindmounts_ro[@]}" "${bindmounts_rw[@]}" \
bash -c 'yes y | pacman -U -- "$@"' -bash "${pkgnames[@]/#//root/}"
ret=$?
rm -- "${pkgnames[@]/#/$copydir/root/}"
@@ -193,11 +188,6 @@ builduser ALL = NOPASSWD: /usr/bin/pacman
EOF
chmod 440 "$copydir/etc/sudoers.d/builduser-pacman"
cat > "$copydir/etc/gitconfig" <<EOF
[safe]
directory = *
EOF
# This is a little gross, but this way the script is recreated every time in the
# working copy
{
@@ -206,7 +196,6 @@ EOF
declare -p SOURCE_DATE_EPOCH 2>/dev/null || true
declare -p BUILDTOOL 2>/dev/null
declare -p BUILDTOOLVER 2>/dev/null
declare -p offline_options
printf '_chrootbuild "$@" || exit\n'
if (( run_namcap )); then
@@ -226,52 +215,14 @@ _chrootbuild() {
# shellcheck source=/dev/null
. /etc/profile
# for in_array
. /usr/share/makepkg/util.sh
# Beware, there are some stupid arbitrary rules on how you can
# use "$" in arguments to commands with "sudo -i". ${foo} or
# ${1} is OK, but $foo or $1 isn't.
# https://bugzilla.sudo.ws/show_bug.cgi?id=765
# Run prepare
sudo --preserve-env=SOURCE_DATE_EPOCH \
--preserve-env=BUILDTOOL \
--preserve-env=BUILDTOOLVER \
-iu builduser bash -c 'cd /startdir; makepkg --nobuild "$@"' -bash "$@"
if in_array "build" "${offline_options[@]}"; then
msg "building offline"
# Build offline
unshare -n -- sudo --preserve-env=SOURCE_DATE_EPOCH \
--preserve-env=BUILDTOOL \
--preserve-env=BUILDTOOLVER \
-iu builduser \
bash -c 'cd /startdir; makepkg --noprepare --noextract --nocheck "$@"' -bash "$@"
else
sudo --preserve-env=SOURCE_DATE_EPOCH \
--preserve-env=BUILDTOOL \
--preserve-env=BUILDTOOLVER \
-iu builduser \
bash -c 'cd /startdir; makepkg --noprepare --noextract --nocheck "$@"' -bash "$@"
fi
if in_array "check" "${offline_options[@]}"; then
msg "check offline"
# Run tests online
unshare -n -- sudo --preserve-env=SOURCE_DATE_EPOCH \
--preserve-env=BUILDTOOL \
--preserve-env=BUILDTOOLVER \
-iu builduser \
bash -c 'cd /startdir; makepkg --noprepare --noextract --nobuild "$@"' -bash "$@"
else
sudo --preserve-env=SOURCE_DATE_EPOCH \
--preserve-env=BUILDTOOL \
--preserve-env=BUILDTOOLVER \
-iu builduser \
bash -c 'cd /startdir; makepkg --noprepare --noextract --nobuild "$@"' -bash "$@"
fi
-iu builduser bash -c 'cd /startdir; makepkg "$@"' -bash "$@"
ret=$?
case $ret in
0|14)
@@ -335,18 +286,16 @@ move_products() {
}
# }}}
while getopts 'hcur:I:l:nCTD:o:d:U:x:t:' arg; do
while getopts 'hcur:I:l:nCTD:d:U:x:' arg; do
case "$arg" in
c) clean_first=1 ;;
D) bindmounts_ro+=("--bind-ro=$OPTARG") ;;
d) bindmounts_rw+=("--bind=$OPTARG") ;;
t) bindmounts_tmpfs+=("--tmpfs=$OPTARG") ;;
u) update_first=1 ;;
r) passeddir="$OPTARG" ;;
I) install_pkgs+=("$OPTARG") ;;
l) copy="$OPTARG" ;;
n) run_namcap=1; makepkg_args+=(--install) ;;
o) offline_options+=("$OPTARG") ;;
C) run_checkpkg=1 ;;
T) temp_chroot=1; copy+="-$$" ;;
U) makepkg_user="$OPTARG" ;;
@@ -411,7 +360,7 @@ if [[ ! -d $copydir ]] || (( clean_first )); then
fi
(( update_first )) && arch-nspawn "$copydir" \
"${bindmounts_ro[@]}" "${bindmounts_rw[@]}" "${bindmounts_tmpfs[@]}" \
"${bindmounts_ro[@]}" "${bindmounts_rw[@]}" \
pacman -Syuu --noconfirm
if [[ -n ${install_pkgs[*]:-} ]]; then
@@ -436,7 +385,6 @@ nspawn_build_args=(
--tmpfs="/tmp:${tmp_opts}"
"${bindmounts_ro[@]}"
"${bindmounts_rw[@]}"
"${bindmounts_tmpfs[@]}"
)
if arch-nspawn "$copydir" \

View File

@@ -22,14 +22,13 @@ nspawn_args=()
usage() {
echo "Usage: ${0##*/} [options] working-dir package-list..."
echo ' options:'
echo ' -U Use pacman -U to install packages'
echo ' -C <file> Location of a pacman config file'
echo ' -M <file> Location of a makepkg config file'
echo ' -c <dir> Set pacman cache'
echo ' -f <src>[:<dst>] Copy src file from the host to the chroot.'
echo ' If dst file is not provided, it defaults to src'
echo ' -s Do not run setarch'
echo ' -h This message'
echo ' -U Use pacman -U to install packages'
echo ' -C <file> Location of a pacman config file'
echo ' -M <file> Location of a makepkg config file'
echo ' -c <dir> Set pacman cache'
echo ' -f <file> Copy file from the host to the chroot'
echo ' -s Do not run setarch'
echo ' -h This message'
exit 1
}
@@ -85,10 +84,8 @@ if is_btrfs "$working_dir"; then
fi
for file in "${files[@]}"; do
src="${file%%:*}"
dst="${file#*:}"
mkdir -p "$(dirname "$working_dir$dst")"
cp "$src" "$working_dir$dst"
mkdir -p "$(dirname "$working_dir$file")"
cp "$file" "$working_dir$file"
done
unshare --mount pacstrap -${umode}Mc ${pac_conf:+-C "$pac_conf"} "$working_dir" \

View File

@@ -23,7 +23,7 @@ fi
repo=extra
arch=x86_64
server=build.archlinux.org
rsyncopts=("${RSYNC_OPTS[@]}")
rsyncopts=(-e ssh -c -h -L --progress --partial -y)
usage() {
cat <<- _EOF_
@@ -107,7 +107,6 @@ mapfile -t files < <(
cd "$temp" &&
{
bsdtar --strip-components 1 -xvf - &&
export LOGDEST="" &&
script -qefc "'"${archbuild_cmd[@]@Q}"'" /dev/null &&
printf "%s\n" "" "-> build complete" &&
printf "\t%s\n" "$temp"/*
@@ -121,25 +120,14 @@ mapfile -t files < <(
[[ -f "${file}" ]] && printf "%s\n" "${file}" ||:
done < <(makepkg --config <(cat "${makepkg_user_config}" "${makepkg_config}" 2>/dev/null) --packagelist) &&
printf "%s\n" "${temp}/PKGBUILD"
find "${temp}" -name "*.log"
')
if (( ${#files[@]} )); then
msg 'Downloading files...'
printf '%s\n' '' '-> copying files...'
rsync "${rsyncopts[@]}" "${files[@]/#/$server:}" "${TEMPDIR}/" || die
if is_globfile "${TEMPDIR}"/*.log; then
mv "${TEMPDIR}"/*.log "${LOGDEST:-${PWD}}/"
fi
# missing PKGBUILD download means the build failed
if [[ ! -f "${TEMPDIR}/PKGBUILD" ]]; then
error "Build failed, check logs in ${LOGDEST:-${PWD}}"
exit 1
fi
mv "${TEMPDIR}/PKGBUILD" "${PWD}/"
mv "${TEMPDIR}"/*.pkg.tar* "${PKGDEST:-${PWD}}/"
mv "${TEMPDIR}/PKGBUILD" "${PWD}/"
else
exit 1
fi

View File

@@ -19,15 +19,16 @@ usage() {
Unified command-line frontend for devtools.
COMMANDS
aur Interact with the Arch User Repository
auth Authenticate with services like GitLab
build Build packages inside a clean chroot
db Pacman database modification for package update, move etc
diff Compare package files using different modes
release Release step to commit, tag and upload build artifacts
repo Manage Git packaging repositories and their configuration
search Search for an expression across the GitLab packaging group
version Check and manage package versions against upstream
aur Interact with the Arch User Repository
auth Authenticate with services like GitLab
build Build packages inside a clean chroot
db Pacman database modification for package update, move etc
diff Compare package files using different modes
release Release step to commit, tag and upload build artifacts
repo Manage Git packaging repositories and their configuration
search Search for an expression across the GitLab packaging group
rebuild-todo Rebuilds packages from a todo list.
version Check and manage package versions against upstream
OPTIONS
-h, --help Show this help text
@@ -112,6 +113,14 @@ while (( $# )); do
pkgctl_release "$@"
exit 0
;;
rebuild-todo)
_DEVTOOLS_COMMAND+=" $1"
shift
# shellcheck source=src/lib/rebuild-todo.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/rebuild-todo.sh
pkgctl_rebuild_todo "$@"
exit 0
;;
search)
_DEVTOOLS_COMMAND+=" $1"
shift

View File

@@ -1,127 +0,0 @@
bats_require_minimum_version 1.5.0
export _DEVTOOLS_LIBRARY_DIR="${PWD}/src"
_pkgctl_version_setup() {
source ${_DEVTOOLS_LIBRARY_DIR}/lib/version/setup.sh
pkgctl_version_setup "$@"
}
setup_and_check_config() {
pushd "test/fixture/version/setup/$1"
shift
_pkgctl_version_setup --force --no-check "$@"
diff .nvchecker.toml nvchecker.assert.toml
popd
}
@test "opt-no-force" {
pushd test/fixture/version/setup/opt-no-force
touch .nvchecker.toml
run ! _pkgctl_version_setup --no-check "$@"
popd
}
@test "opt-url" {
pushd test/fixture/version/setup/opt-url
_pkgctl_version_setup --no-check --force --url \
"https://crates.io/api/v1/crates/shotgun/1.0/download" "$@"
diff .nvchecker.toml nvchecker.assert.toml
popd
}
@test "codeberg-tarball" {
setup_and_check_config codeberg-tarball
}
@test "files.pythonhosted.org" {
setup_and_check_config files.pythonhosted.org
}
@test "github-git" {
setup_and_check_config github-git
}
@test "github-git-as-platform" {
setup_and_check_config github-git-as-platform --prefer-platform-api
}
@test "github-git-v-prefix" {
setup_and_check_config github-git-v-prefix
}
@test "github-git-v-prefix-as-platform" {
setup_and_check_config github-git-v-prefix-as-platform --prefer-platform-api
}
@test "github-tarball" {
setup_and_check_config github-tarball
}
@test "github-tarball-as-platform" {
setup_and_check_config github-tarball-as-platform --prefer-platform-api
}
@test "gitlab-archlinux-tarball" {
setup_and_check_config gitlab-archlinux-tarball
}
@test "gitlab-archlinux-tarball-as-platform" {
setup_and_check_config gitlab-archlinux-tarball-as-platform --prefer-platform-api
}
@test "gitlab-git-multi-group" {
setup_and_check_config gitlab-git-multi-group
}
@test "gitlab-git-multi-group-as-platform" {
setup_and_check_config gitlab-git-multi-group-as-platform --prefer-platform-api
}
@test "gitlab-tarball-multi-group" {
setup_and_check_config gitlab-tarball-multi-group
}
@test "gitlab-tarball-multi-group-as-platform" {
setup_and_check_config gitlab-tarball-multi-group-as-platform --prefer-platform-api
}
@test "hackage-tarball" {
setup_and_check_config hackage-tarball
}
@test "pkgbase-with-dot" {
setup_and_check_config pkgbase-with-dot
}
@test "pypi.io" {
setup_and_check_config pypi.io
}
@test "pypi.org" {
setup_and_check_config pypi.org
}
@test "registry.npmjs.org" {
setup_and_check_config registry.npmjs.org
}
@test "git-custom" {
setup_and_check_config git-custom
}
@test "rubygems.org" {
setup_and_check_config rubygems.org
}
@test "cpan.org" {
setup_and_check_config cpan.org
}
@test "crates.io" {
setup_and_check_config crates.io
}
@test "static.crates.io" {
setup_and_check_config static.crates.io
}

View File

@@ -1 +0,0 @@
*/.nvchecker.toml

View File

@@ -1,18 +0,0 @@
pkgname=xmobar
pkgver=1.0
pkgrel=1
pkgdesc=''
url='https://codeberg.org/xmobar/xmobar'
arch=(any)
source=(
dynamic-compilation.patch
${pkgname}-${pkgver}.tar.gz::https://codeberg.org/xmobar/xmobar/archive/${pkgver}.tar.gz
)
sha512sums=('319f3a77d500c505826ab487e4011bb1a22b8cae70c17b964574a09a6488a864a1aaabb6a298468d121110dd485f179bc712a5106e49eb8ae638e02b5115190a'
'15db3e27d1ff957e26e706e4c67cec6e43d89f5a39cd6d81ddb5ae8426e32d938494fbba39fa322461d992a95d2e522c10b186a1ca2c5c3e996f944b6e6ef7c4')
package() {
:
}
# vim: ts=2 sw=2 et:

View File

@@ -1,3 +0,0 @@
[xmobar]
source = "git"
git = "https://codeberg.org/xmobar/xmobar.git"

View File

@@ -1,14 +0,0 @@
pkgname=perl-locale-po
pkgver=0.3.5
pkgrel=1
pkgdesc=''
arch=(any)
url='http://polyglot.rubyforge.org/'
source=("https://search.cpan.org/CPAN/authors/id/C/CO/COSIMO/Locale-PO-$pkgver.tar.gz")
sha256sums=('59d66ef5e3c166431c39cb8b7c1d02af419051352f27912f6a43981b3def16af')
package() {
:
}
# vim: ts=2 sw=2 et:

View File

@@ -1,3 +0,0 @@
[perl-locale-po]
source = "cpan"
cpan = "Locale-PO"

View File

@@ -1,17 +0,0 @@
pkgname=shotgun
pkgver=0.3.5
pkgrel=1
pkgdesc='Minimal X screenshot utility'
arch=('any')
url='https://github.com/neXromancers/shotgun'
license=('MIT')
depends=('cargo')
options=('!emptydirs')
source=("https://crates.io/api/v1/crates/${pkgname}/${pkgver}/download")
sha256sums=('59d66ef5e3c166431c39cb8b7c1d02af419051352f27912f6a43981b3def16af')
package() {
:
}
# vim: ts=2 sw=2 et:

View File

@@ -1,3 +0,0 @@
[shotgun]
source = "cratesio"
cratesio = "shotgun"

View File

@@ -1,15 +0,0 @@
_pyname=ipyparallel
pkgname=python-$_pyname
pkgver=8.6.1
pkgrel=1
pkgdesc='Interactive Parallel Computing in Python'
url='https://pypi.org/project/ipyparallel/'
arch=(any)
license=(BSD)
source=(https://files.pythonhosted.org/packages/source/${_pyname::1}/$_pyname/$_pyname-$pkgver.tar.gz)
depends=(python)
sha256sums=('a39aa5ef9560170bf0e9afedca9ff045e1b9c1832c49303377edcc91cea9fb77')
package() {
:
}

View File

@@ -1,3 +0,0 @@
[python-ipyparallel]
source = "pypi"
pypi = "ipyparallel"

View File

@@ -1,14 +0,0 @@
pkgname=libfakekey
pkgver=0.3
pkgrel=1
pkgdesc='X virtual keyboard library.'
arch=('x86_64')
url='https://www.yoctoproject.org/tools-resources/projects/matchbox'
license=('GPL')
depends=('libxtst')
source=("git://git.yoctoproject.org/libfakekey")
sha256sums=('d282fa6481a5b85f71e36e8bad4cfa938cc8eaac4c42ffa27f9203ac634813f4')
package() {
:
}

View File

@@ -1,3 +0,0 @@
[libfakekey]
source = "git"
git = "git://git.yoctoproject.org/libfakekey"

View File

@@ -1,17 +0,0 @@
pkgname=minisign
pkgver=0.11
pkgrel=1
pkgdesc="A dead-simple tool to sign files and verify digital signatures"
arch=('x86_64')
url="https://github.com/jedisct1/minisign"
license=('custom:ISC')
depends=('libsodium')
makedepends=('cmake' 'git')
_commit=feefda7af87f64342bd07bf446ceb0467cbd0fb4 # git rev-parse $pkgver
source=("git+https://github.com/jedisct1/minisign.git?signed#tag=$_commit")
sha512sums=('SKIP')
validpgpkeys=(54A2B8892CC3D6A597B92B6C210627AABA709FE1) # Frank Denis
package() {
:
}

View File

@@ -1,4 +0,0 @@
[minisign]
source = "github"
github = "jedisct1/minisign"
use_max_tag = true

View File

@@ -1,17 +0,0 @@
pkgname=vim
pkgver=9.1.0131
pkgrel=1
pkgdesc="A dead-simple tool to sign files and verify digital signatures"
arch=('x86_64')
url="https://github.com/jedisct1/minisign"
license=('custom:ISC')
depends=('libsodium')
makedepends=('cmake' 'git')
_commit=feefda7af87f64342bd07bf446ceb0467cbd0fb4 # git rev-parse $pkgver
source=("git+https://github.com/vim/vim.git?signed#tag=v${pkgver}")
sha512sums=('SKIP')
validpgpkeys=(54A2B8892CC3D6A597B92B6C210627AABA709FE1) # Frank Denis
package() {
:
}

View File

@@ -1,5 +0,0 @@
[vim]
source = "github"
github = "vim/vim"
use_max_tag = true
prefix = "v"

View File

@@ -1,17 +0,0 @@
pkgname=vim
pkgver=9.1.0131
pkgrel=1
pkgdesc="A dead-simple tool to sign files and verify digital signatures"
arch=('x86_64')
url="https://github.com/jedisct1/minisign"
license=('custom:ISC')
depends=('libsodium')
makedepends=('cmake' 'git')
_commit=feefda7af87f64342bd07bf446ceb0467cbd0fb4 # git rev-parse $pkgver
source=("git+https://github.com/vim/vim.git?signed#tag=v${pkgver}")
sha512sums=('SKIP')
validpgpkeys=(54A2B8892CC3D6A597B92B6C210627AABA709FE1) # Frank Denis
package() {
:
}

View File

@@ -1,4 +0,0 @@
[vim]
source = "git"
git = "https://github.com/vim/vim.git"
prefix = "v"

View File

@@ -1,17 +0,0 @@
pkgname=minisign
pkgver=0.11
pkgrel=1
pkgdesc="A dead-simple tool to sign files and verify digital signatures"
arch=('x86_64')
url="https://github.com/jedisct1/minisign"
license=('custom:ISC')
depends=('libsodium')
makedepends=('cmake' 'git')
_commit=feefda7af87f64342bd07bf446ceb0467cbd0fb4 # git rev-parse $pkgver
source=("git+https://github.com/jedisct1/minisign.git?signed#tag=$_commit")
sha512sums=('SKIP')
validpgpkeys=(54A2B8892CC3D6A597B92B6C210627AABA709FE1) # Frank Denis
package() {
:
}

View File

@@ -1,3 +0,0 @@
[minisign]
source = "git"
git = "https://github.com/jedisct1/minisign.git"

View File

@@ -1,29 +0,0 @@
pkgname=git-smash
pkgver=0.1.0
pkgrel=1
pkgdesc='Smash staged changes into previous commits to support your Git workflow'
url='https://github.com/anthraxx/git-smash'
arch=('x86_64')
license=('MIT')
depends=('glibc' 'gcc-libs' 'git')
makedepends=('cargo' 'scdoc')
optdepends=(
'skim: selection menu alternative'
'fzf: selection menu alternative'
)
source=(${url}/archive/${pkgver}/${pkgname}-${pkgver}.tar.gz
${url}/releases/download/${pkgver}/${pkgname}-${pkgver}.tar.gz.sig)
options=('!makeflags')
sha512sums=('64a8b6e2afa7007966245a4888e51251e8c35f0b82421f3cee634a3e7b82256a24459cba2941800a6e50a047766a0f8de20b435904d17df3fd456b6c09ac4c5f'
'SKIP')
b2sums=('acc46b7a87135380fe36c378e9055b8b7c9b88a818c955f04677161f50d5ccd5699ac05f0a858dd11ca7b42b3505c0ac037f50efcd690f9e5a76be395d5d6590'
'SKIP')
validpgpkeys=(
'E240B57E2C4630BA768E2F26FC1B547C8D8172C8' # Levente Polyak
)
package() {
:
}
# vim: ts=2 sw=2 et:

View File

@@ -1,5 +0,0 @@
[git-smash]
source = "github"
github = "anthraxx/git-smash"
use_max_tag = true
prefix = "v"

View File

@@ -1,25 +0,0 @@
pkgname=git-smash
pkgver=0.1.0
pkgrel=1
pkgdesc='Smash staged changes into previous commits to support your Git workflow'
url='https://github.com/anthraxx/git-smash'
arch=('x86_64')
license=('MIT')
depends=('glibc' 'gcc-libs' 'git')
makedepends=('cargo' 'scdoc')
source=(${url}/archive/${pkgver}/${pkgname}-${pkgver}.tar.gz
${url}/releases/download/${pkgver}/${pkgname}-${pkgver}.tar.gz.sig)
options=('!makeflags')
sha512sums=('64a8b6e2afa7007966245a4888e51251e8c35f0b82421f3cee634a3e7b82256a24459cba2941800a6e50a047766a0f8de20b435904d17df3fd456b6c09ac4c5f'
'SKIP')
b2sums=('acc46b7a87135380fe36c378e9055b8b7c9b88a818c955f04677161f50d5ccd5699ac05f0a858dd11ca7b42b3505c0ac037f50efcd690f9e5a76be395d5d6590'
'SKIP')
validpgpkeys=(
'E240B57E2C4630BA768E2F26FC1B547C8D8172C8' # Levente Polyak
)
package() {
:
}
# vim: ts=2 sw=2 et:

View File

@@ -1,4 +0,0 @@
[git-smash]
source = "git"
git = "https://github.com/anthraxx/git-smash.git"
prefix = "v"

View File

@@ -1,57 +0,0 @@
pkgname=devtools
epoch=1
pkgver=1.1.1
pkgrel=1
pkgdesc='Tools for Arch Linux package maintainers'
arch=('any')
license=('GPL-3.0-or-later')
url='https://gitlab.archlinux.org/archlinux/devtools'
depends=(
arch-install-scripts
awk
bash
binutils
coreutils
curl
diffutils
fakeroot
findutils
grep
jq
openssh
parallel
rsync
sed
util-linux
breezy
git
mercurial
subversion
)
makedepends=(
asciidoc
shellcheck
)
optdepends=(
'btrfs-progs: btrfs support'
'bat: pretty printing for pkgctl search'
'nvchecker: pkgctl version subcommand'
'pacman-contrib: support for the --update-checksums option'
)
replaces=(devtools-git-poc)
source=(https://gitlab.archlinux.org/archlinux/devtools/-/releases/v${pkgver}/downloads/devtools-${pkgver}.tar.gz{,.sig})
validpgpkeys=(
'E240B57E2C4630BA768E2F26FC1B547C8D8172C8' # Levente Polyak <anthraxx@archlinux.org>
'F00B96D15228013FFC9C9D0393B11DAA4C197E3D' # Christian Heusel (gromit packager key) <gromit@archlinux.org>
)
sha256sums=('b2a12bb8b4b568110b055ccec903c9a0b0b979ab44f0cba574c026d243d5ce36'
'SKIP')
b2sums=('be9601a4fcbb576b9a8637abdaec70f8ec730cf5752793c2f8fdce20e489b74555f624d0a0b5f8bb58c0914413a29d51698c8474430010502ab80d6c18c4332e'
'SKIP')
package() {
:
}
# vim: ts=2 sw=2 et:

View File

@@ -1,6 +0,0 @@
[devtools]
source = "gitlab"
gitlab = "archlinux/devtools"
host = "gitlab.archlinux.org"
use_max_tag = true
prefix = "v"

View File

@@ -1,57 +0,0 @@
pkgname=devtools
epoch=1
pkgver=1.1.1
pkgrel=1
pkgdesc='Tools for Arch Linux package maintainers'
arch=('any')
license=('GPL-3.0-or-later')
url='https://gitlab.archlinux.org/archlinux/devtools'
depends=(
arch-install-scripts
awk
bash
binutils
coreutils
curl
diffutils
fakeroot
findutils
grep
jq
openssh
parallel
rsync
sed
util-linux
breezy
git
mercurial
subversion
)
makedepends=(
asciidoc
shellcheck
)
optdepends=(
'btrfs-progs: btrfs support'
'bat: pretty printing for pkgctl search'
'nvchecker: pkgctl version subcommand'
'pacman-contrib: support for the --update-checksums option'
)
replaces=(devtools-git-poc)
source=(https://gitlab.archlinux.org/archlinux/devtools/-/releases/v${pkgver}/downloads/devtools-${pkgver}.tar.gz{,.sig})
validpgpkeys=(
'E240B57E2C4630BA768E2F26FC1B547C8D8172C8' # Levente Polyak <anthraxx@archlinux.org>
'F00B96D15228013FFC9C9D0393B11DAA4C197E3D' # Christian Heusel (gromit packager key) <gromit@archlinux.org>
)
sha256sums=('b2a12bb8b4b568110b055ccec903c9a0b0b979ab44f0cba574c026d243d5ce36'
'SKIP')
b2sums=('be9601a4fcbb576b9a8637abdaec70f8ec730cf5752793c2f8fdce20e489b74555f624d0a0b5f8bb58c0914413a29d51698c8474430010502ab80d6c18c4332e'
'SKIP')
package() {
:
}
# vim: ts=2 sw=2 et:

View File

@@ -1,4 +0,0 @@
[devtools]
source = "git"
git = "https://gitlab.archlinux.org/archlinux/devtools.git"
prefix = "v"

View File

@@ -1,30 +0,0 @@
pkgbase=kicad-library
pkgname=($pkgbase{,-3d})
pkgver=7.0.10
pkgrel=1
pkgdesc='Assorted libraries for KiCad'
arch=('any')
url='http://kicad.org/'
license=('GPL')
makedepends=('git' 'cmake')
options=('!strip')
source=(
'git+https://gitlab.com/kicad/libraries/kicad-packages3D.git#commit=f1af95360976e66472b13897a1f3f5c2a77c0461'
'git+https://gitlab.com/kicad/libraries/kicad-symbols.git#commit=5efa35abf67b4734a8e04cf83e31514be3329ce4'
'git+https://gitlab.com/kicad/libraries/kicad-templates.git#commit=ff6e3193e6ff6029f65e7cce8ab39fafeafecdd6'
'git+https://gitlab.com/kicad/libraries/kicad-footprints.git#commit=9fb460d078b55f2bb08c459cddd184833a853167'
)
sha512sums=('SKIP'
'SKIP'
'SKIP'
'SKIP')
package_kicad-library() {
:
}
package_kicad-library-3d() {
:
}
# vim:set ts=2 sw=2 et:

View File

@@ -1,4 +0,0 @@
[kicad-library]
source = "gitlab"
gitlab = "kicad/libraries/kicad-packages3D"
use_max_tag = true

View File

@@ -1,30 +0,0 @@
pkgbase=kicad-library
pkgname=($pkgbase{,-3d})
pkgver=7.0.10
pkgrel=1
pkgdesc='Assorted libraries for KiCad'
arch=('any')
url='http://kicad.org/'
license=('GPL')
makedepends=('git' 'cmake')
options=('!strip')
source=(
'git+https://gitlab.com/kicad/libraries/kicad-packages3D.git#commit=f1af95360976e66472b13897a1f3f5c2a77c0461'
'git+https://gitlab.com/kicad/libraries/kicad-symbols.git#commit=5efa35abf67b4734a8e04cf83e31514be3329ce4'
'git+https://gitlab.com/kicad/libraries/kicad-templates.git#commit=ff6e3193e6ff6029f65e7cce8ab39fafeafecdd6'
'git+https://gitlab.com/kicad/libraries/kicad-footprints.git#commit=9fb460d078b55f2bb08c459cddd184833a853167'
)
sha512sums=('SKIP'
'SKIP'
'SKIP'
'SKIP')
package_kicad-library() {
:
}
package_kicad-library-3d() {
:
}
# vim:set ts=2 sw=2 et:

View File

@@ -1,3 +0,0 @@
[kicad-library]
source = "git"
git = "https://gitlab.com/kicad/libraries/kicad-packages3D.git"

View File

@@ -1,24 +0,0 @@
pkgbase=kicad-library
pkgname=($pkgbase{,-3d})
pkgver=7.0.10
pkgrel=1
pkgdesc='Assorted libraries for KiCad'
arch=('any')
url='http://kicad.org/'
license=('GPL')
makedepends=('git' 'cmake')
options=('!strip')
source=(
https://gitlab.com/kicad/libraries/kicad-packages3D/-/archive/8.0.0/kicad-packages3D-8.0.0.tar.gz
)
sha512sums=('SKIP')
package_kicad-library() {
:
}
package_kicad-library-3d() {
:
}
# vim:set ts=2 sw=2 et:

View File

@@ -1,4 +0,0 @@
[kicad-library]
source = "gitlab"
gitlab = "kicad/libraries/kicad-packages3D"
use_max_tag = true

View File

@@ -1,24 +0,0 @@
pkgbase=kicad-library
pkgname=($pkgbase{,-3d})
pkgver=7.0.10
pkgrel=1
pkgdesc='Assorted libraries for KiCad'
arch=('any')
url='http://kicad.org/'
license=('GPL')
makedepends=('git' 'cmake')
options=('!strip')
source=(
https://gitlab.com/kicad/libraries/kicad-packages3D/-/archive/8.0.0/kicad-packages3D-8.0.0.tar.gz
)
sha512sums=('SKIP')
package_kicad-library() {
:
}
package_kicad-library-3d() {
:
}
# vim:set ts=2 sw=2 et:

View File

@@ -1,3 +0,0 @@
[kicad-library]
source = "git"
git = "https://gitlab.com/kicad/libraries/kicad-packages3D.git"

View File

@@ -1,16 +0,0 @@
_hkgname=implicit-hie
pkgname=haskell-implicit-hie
pkgver=0.1.2.7
pkgrel=114
pkgdesc="Auto generate hie-bios cradles & hie.yaml"
url="https://github.com/Avi-D-coder/implicit-hie#readme"
license=("custom:BSD3")
arch=('x86_64')
depends=('ghc-libs' 'haskell-attoparsec' 'haskell-filepattern' 'haskell-yaml')
makedepends=('ghc' 'haskell-hspec' 'haskell-hspec-attoparsec')
source=("https://hackage.haskell.org/packages/archive/$_hkgname/$pkgver/$_hkgname-$pkgver.tar.gz")
sha512sums=('b0746867352b29dd2d4c4535ce6f4d61c3cc61ed31f3f18d49e3f657b12d470a9a53a7ef8a785a9e19b8ff12fb8d8b1cfa80c5c22c90af65bf4b39ab62bbd768')
package() {
:
}

View File

@@ -1,3 +0,0 @@
[haskell-implicit-hie]
source = "hackage"
hackage = "implicit-hie"

View File

@@ -1,57 +0,0 @@
pkgname=devtools
epoch=1
pkgver=1.1.1
pkgrel=1
pkgdesc='Tools for Arch Linux package maintainers'
arch=('any')
license=('GPL-3.0-or-later')
url='https://gitlab.archlinux.org/archlinux/devtools'
depends=(
arch-install-scripts
awk
bash
binutils
coreutils
curl
diffutils
fakeroot
findutils
grep
jq
openssh
parallel
rsync
sed
util-linux
breezy
git
mercurial
subversion
)
makedepends=(
asciidoc
shellcheck
)
optdepends=(
'btrfs-progs: btrfs support'
'bat: pretty printing for pkgctl search'
'nvchecker: pkgctl version subcommand'
'pacman-contrib: support for the --update-checksums option'
)
replaces=(devtools-git-poc)
source=(https://gitlab.archlinux.org/archlinux/devtools/-/releases/v${pkgver}/downloads/devtools-${pkgver}.tar.gz{,.sig})
validpgpkeys=(
'E240B57E2C4630BA768E2F26FC1B547C8D8172C8' # Levente Polyak <anthraxx@archlinux.org>
'F00B96D15228013FFC9C9D0393B11DAA4C197E3D' # Christian Heusel (gromit packager key) <gromit@archlinux.org>
)
sha256sums=('b2a12bb8b4b568110b055ccec903c9a0b0b979ab44f0cba574c026d243d5ce36'
'SKIP')
b2sums=('be9601a4fcbb576b9a8637abdaec70f8ec730cf5752793c2f8fdce20e489b74555f624d0a0b5f8bb58c0914413a29d51698c8474430010502ab80d6c18c4332e'
'SKIP')
package() {
:
}
# vim: ts=2 sw=2 et:

View File

@@ -1,25 +0,0 @@
pkgname=git-smash
pkgver=0.1.0
pkgrel=1
pkgdesc='Smash staged changes into previous commits to support your Git workflow'
url='https://github.com/anthraxx/git-smash'
arch=('x86_64')
license=('MIT')
depends=('glibc' 'gcc-libs' 'git')
makedepends=('cargo' 'scdoc')
source=(${url}/archive/${pkgver}/${pkgname}-${pkgver}.tar.gz
${url}/releases/download/${pkgver}/${pkgname}-${pkgver}.tar.gz.sig)
options=('!makeflags')
sha512sums=('64a8b6e2afa7007966245a4888e51251e8c35f0b82421f3cee634a3e7b82256a24459cba2941800a6e50a047766a0f8de20b435904d17df3fd456b6c09ac4c5f'
'SKIP')
b2sums=('acc46b7a87135380fe36c378e9055b8b7c9b88a818c955f04677161f50d5ccd5699ac05f0a858dd11ca7b42b3505c0ac037f50efcd690f9e5a76be395d5d6590'
'SKIP')
validpgpkeys=(
'E240B57E2C4630BA768E2F26FC1B547C8D8172C8' # Levente Polyak
)
package() {
:
}
# vim: ts=2 sw=2 et:

View File

@@ -1,3 +0,0 @@
[git-smash]
source = "cratesio"
cratesio = "shotgun"

View File

@@ -1,27 +0,0 @@
pkgname=git.smash
pkgver=0.1.0
pkgrel=1
pkgdesc='Smash staged changes into previous commits to support your Git workflow'
url='https://github.com/anthraxx/git-smash'
arch=('x86_64')
license=('MIT')
depends=('glibc' 'gcc-libs' 'git')
makedepends=('cargo' 'scdoc')
optdepends=(
'skim: selection menu alternative'
'fzf: selection menu alternative'
)
source=(${url}/archive/${pkgver}/${pkgname}-${pkgver}.tar.gz
${url}/releases/download/${pkgver}/${pkgname}-${pkgver}.tar.gz.sig)
options=('!makeflags')
sha512sums=('64a8b6e2afa7007966245a4888e51251e8c35f0b82421f3cee634a3e7b82256a24459cba2941800a6e50a047766a0f8de20b435904d17df3fd456b6c09ac4c5f'
'SKIP')
b2sums=('acc46b7a87135380fe36c378e9055b8b7c9b88a818c955f04677161f50d5ccd5699ac05f0a858dd11ca7b42b3505c0ac037f50efcd690f9e5a76be395d5d6590'
'SKIP')
validpgpkeys=(
'E240B57E2C4630BA768E2F26FC1B547C8D8172C8' # Levente Polyak
)
package() {
:
}

View File

@@ -1,4 +0,0 @@
["git.smash"]
source = "git"
git = "https://github.com/anthraxx/git-smash.git"
prefix = "v"

View File

@@ -1,17 +0,0 @@
pkgname=python-pyaml
pkgver=23.9.0
pkgrel=1
pkgdesc="PyYAML-based module to produce pretty and readable YAML-serialized data"
url="https://pypi.python.org/pypi/pyaml"
license=('BSD')
arch=('any')
depends=('python-yaml')
makedepends=('python-setuptools')
checkdepends=('python-unidecode')
optdepends=('python-unidecode: Needed if same-id objects or recursion is used within serialized data')
source=("https://pypi.io/packages/source/p/pyaml/pyaml-$pkgver.tar.gz")
sha512sums=('1ff23e07e45d6530b6666a26947362a6bb2125b731dd03501aafe9096766a38fec7906a36666c7974e49cedf9a91f5af0973827151c746933e7b969aeec56ab8')
package() {
:
}

View File

@@ -1,3 +0,0 @@
[python-pyaml]
source = "pypi"
pypi = "pyaml"

View File

@@ -1,23 +0,0 @@
pkgname=python-bleach
pkgver=6.1.0
pkgrel=1
pkgdesc="An easy whitelist-based HTML-sanitizing tool"
url="https://pypi.org/project/bleach/"
arch=('any')
license=('Apache')
depends=('python-packaging'
'python-six'
'python-webencodings')
makedepends=('python'
'python-setuptools')
checkdepends=('python-pytest')
optdepends=('python-tinycss2: for CSS sanitisation')
source=(https://pypi.org/packages/source/b/bleach/bleach-$pkgver.tar.gz)
sha256sums=('0a31f1837963c41d46bbf1331b8778e1308ea0791db03cc4e7357b97cf42a8fe')
package() {
:
}

View File

@@ -1,3 +0,0 @@
[python-bleach]
source = "pypi"
pypi = "bleach"

View File

@@ -1,16 +0,0 @@
pkgname=node-gyp
pkgver=10.0.1
pkgrel=1
pkgdesc='Node.js native addon build tool'
arch=('any')
url='https://github.com/nodejs/node-gyp'
license=('MIT')
depends=('nodejs' 'nodejs-nopt' 'python' 'semver')
makedepends=('npm')
source=("https://registry.npmjs.org/$pkgname/-/$pkgname-$pkgver.tgz")
noextract=("$pkgname-$pkgver.tgz")
sha512sums=('820dff6c77a141f662bd055fa88cb2f304dd4b2985f724f23f808989f2bbde29b234c53c008190136a546bb74d59f98c786f5c0d517679e86244cbf42c2d6202')
package() {
:
}

View File

@@ -1,3 +0,0 @@
[node-gyp]
source = "npm"
npm = "node-gyp"

View File

@@ -1,16 +0,0 @@
pkgname=ruby-diff-lcs
pkgver=0.3.5
pkgrel=8
pkgdesc='Allows custom language loaders to be hooked into require'
arch=('any')
url='http://polyglot.rubyforge.org/'
license=('MIT')
depends=('ruby')
options=('!emptydirs')
source=("https://rubygems.org/downloads/${pkgname#*-}-${pkgver}.gem")
noextract=("${pkgname#*-}-${pkgver}.gem")
sha256sums=('59d66ef5e3c166431c39cb8b7c1d02af419051352f27912f6a43981b3def16af')
package() {
:
}

View File

@@ -1,3 +0,0 @@
[ruby-diff-lcs]
source = "gems"
gems = "diff-lcs"

View File

@@ -1,16 +0,0 @@
pkgname=shotgun
pkgver=0.3.5
pkgrel=8
pkgdesc='Allows custom language loaders to be hooked into require'
arch=('any')
url='http://polyglot.rubyforge.org/'
license=('MIT')
depends=('ruby')
options=('!emptydirs')
source=("https://static.crates.io/crates/shotgun/shotgun-$pkgver.crate")
noextract=("${pkgname#*-}-${pkgver}.gem")
sha256sums=('59d66ef5e3c166431c39cb8b7c1d02af419051352f27912f6a43981b3def16af')
package() {
:
}

View File

@@ -1,3 +0,0 @@
[shotgun]
source = "cratesio"
cratesio = "shotgun"