Simon Tournier
1eb3133355
scripts: edit: Fix relative file-name with 'load-path' option.
...
* guix/scripts/edit.scm (search-path*): Return 'file' if exists when
'search-path' fails.
Change-Id: I891d63d0d28577a7d1732fc59435828ecc0a5c5a
2023-11-05 16:11:17 +01:00
Ludovic Courtès
6eb147dc31
environment: Fix typo in error messages.
...
* guix/scripts/environment.scm (guix-environment*): Fix typo in error
messages.
Change-Id: I0b8669cb43267d0456a70f3b157514a6bcc725e8
2023-10-28 01:23:41 +02:00
Ludovic Courtès
661672a7f8
environment: Parameterize ‘%graft?’ early on.
...
Previously, ‘%graft?’ would be parameterized after ‘package-derivation’
had been called for ‘%guile-for-build’, which is too late.
* guix/scripts/environment.scm (guix-environment*)[with-store/maybe]:
Parameterize ‘%graft?’.
Remove ‘%graft?’ parameterization from body.
Change-Id: I65ef4a8c5f27e19a49196005871e5f7057fabaec
2023-10-28 01:21:56 +02:00
Ludovic Courtès
b3ec2a0d37
environment: Honor ‘-s’ for guile-for-build.
...
Partly fixes <https://issues.guix.gnu.org/65225 >.
* guix/scripts/environment.scm (guix-environment*): Pass SYSTEM to
‘package-derivation’ when defining ‘%guile-for-build’.
Reported-by: Simon Tournier <zimon.toutoune@gmail.com>
Change-Id: I9d883f1e61fac72754fdc9dee9b7c8a3dea32add
2023-10-28 00:17:24 +02:00
Ludovic Courtès
d0fed2f4df
locate: Do not return the system database when it is too old.
...
Fixes a bug whereby ‘guix locate’ would pick the system database, then
decide it’s too old, try to update it, and fail because it’s not
writable by unprivileged users.
Fixes <https://issues.guix.gnu.org/66612 >.
* guix/scripts/locate.scm (file-age): New procedure.
(suitable-database): Add ‘age-update-threshold’ parameter and honor it.
(guix-locate): Remove ‘file-age’. Pass ‘age-update-threshold’ to the
‘database’ option.
Reported-by: Matt Wette <matt.wette@gmail.com>
2023-10-18 18:21:04 +02:00
Simon Tournier
daaebc6457
scripts: weather: Handle EPIPE errors when displaying help.
...
* guix/scripts/weather.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:52:06 +02:00
Simon Tournier
16e53f1687
scripts: upgrade: Handle EPIPE errors when displaying help.
...
* guix/scripts/upgrade.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:52:06 +02:00
Simon Tournier
a293b1cfa7
scripts: time-machine: Handle EPIPE errors when displaying help.
...
* guix/scripts/time-machine.scm (%options): Handle EPIPE errors when
displaying help.
2023-10-17 14:52:05 +02:00
Simon Tournier
c4aa37fde9
scripts: substitute: Handle EPIPE errors when displaying help.
...
* guix/scripts/substitute.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:52:05 +02:00
Simon Tournier
6c5516ab83
scripts: system: Handle EPIPE errors when displaying help.
...
* guix/scripts/system.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:52:05 +02:00
Simon Tournier
08b16ebcb3
scripts: style: Handle EPIPE errors when displaying help.
...
* guix/scripts/style.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:52:04 +02:00
Simon Tournier
426f52826b
scripts: size: Handle EPIPE errors when displaying help.
...
* guix/scripts/size.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:52:04 +02:00
Simon Tournier
d56940eb81
scripts: show: Handle EPIPE errors when displaying help.
...
* guix/scripts/show.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:52:04 +02:00
Simon Tournier
acdbb798d0
scripts: shell: Handle EPIPE errors when displaying help.
...
* guix/scripts/shell.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:52:03 +02:00
Simon Tournier
94e0496aa8
scripts: search: Handle EPIPE errors when displaying help.
...
* guix/scripts/search.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:52:03 +02:00
Simon Tournier
c5a5ccfa54
scripts: repl: Handle EPIPE errors when displaying help.
...
* guix/scripts/repl.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:52:03 +02:00
Simon Tournier
028de130d2
scripts: remove: Handle EPIPE errors when displaying help.
...
* guix/scripts/remove.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:52:02 +02:00
Simon Tournier
ac9b2939d6
scripts: refresh: Handle EPIPE errors when displaying help.
...
* guix/scripts/refresh.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:52:02 +02:00
Simon Tournier
0c0bcbdd83
scripts: pull: Handle EPIPE errors when displaying help.
...
Reported by Mathieu Othacehe <othacehe@gnu.org>.
* guix/scripts/pull.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:52:02 +02:00
Simon Tournier
3a665d789f
scripts: publish: Handle EPIPE errors when displaying help.
...
* guix/scripts/publish.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:52:01 +02:00
Simon Tournier
bfc6c54131
scripts: processes: Handle EPIPE errors when displaying help.
...
* guix/scripts/processes.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:52:01 +02:00
Simon Tournier
4451982ac4
scripts: package: Handle EPIPE errors when displaying help.
...
Reported by Mathieu Othacehe <othacehe@gnu.org>.
* guix/scripts/package.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:52:01 +02:00
Simon Tournier
61a7e16d8d
scripts: pack: Handle EPIPE errors when displaying help.
...
* guix/scripts/pack.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:52:00 +02:00
Simon Tournier
ef8a615861
scripts: offload: Handle EPIPE errors when displaying help.
...
* guix/scripts/offload.scm (guix-offload): Handle EPIPE errors when displaying
help.
2023-10-17 14:52:00 +02:00
Simon Tournier
55c3776023
scripts: locate: Handle EPIPE errors when displaying help.
...
* guix/scripts/locate.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:51:59 +02:00
Simon Tournier
078107289a
scripts: lint: Handle EPIPE errors when displaying help.
...
* guix/scripts/lint.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:51:59 +02:00
Simon Tournier
a5d9042663
scripts: install: Handle EPIPE errors when displaying help.
...
* guix/scripts/install.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:51:59 +02:00
Simon Tournier
79b6eef750
scripts: import: Handle EPIPE errors when displaying help.
...
* guix/scripts/import.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:51:58 +02:00
Simon Tournier
f7c274c403
scripts: home: Handle EPIPE errors when displaying help.
...
* guix/scripts/home.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:51:58 +02:00
Simon Tournier
7d36333145
scripts: hash: Handle EPIPE errors when displaying help.
...
* guix/scripts/hash.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:51:58 +02:00
Simon Tournier
ba8a43f220
scripts: graph: Handle EPIPE errors when displaying help.
...
* guix/scripts/graph.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:51:57 +02:00
Simon Tournier
cba0fa6f4f
scripts: git: Handle EPIPE errors when displaying help.
...
* guix/scripts/git.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:51:57 +02:00
Simon Tournier
330540b638
scripts: gc: Handle EPIPE errors when displaying help.
...
* guix/scripts/gc.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:51:57 +02:00
Simon Tournier
8ed377978e
scripts: edit: Handle EPIPE errors when displaying help.
...
* guix/scripts/edit.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:51:56 +02:00
Simon Tournier
25331ae62b
scripts: download: Handle EPIPE errors when displaying help.
...
* guix/scripts/download.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:51:56 +02:00
Simon Tournier
6c6071faf9
scripts: discover: Handle EPIPE errors when displaying help.
...
* guix/scripts/discover.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:51:56 +02:00
Simon Tournier
a53e5fb121
scripts: describe: Handle EPIPE errors when displaying help.
...
* guix/scripts/describe.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:51:55 +02:00
Simon Tournier
c150267648
scripts: deploy: Handle EPIPE errors when displaying help.
...
* guix/scripts/deploy.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:51:55 +02:00
Simon Tournier
fb231e09cb
scripts: copy: Handle EPIPE errors when displaying help.
...
* guix/scripts/copy.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:51:55 +02:00
Simon Tournier
f814d33cbd
scripts: container: Handle EPIPE errors when displaying help.
...
* guix/scripts/container.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:51:54 +02:00
Simon Tournier
2ac8e95dba
scripts: challenge: Handle EPIPE errors when displaying help.
...
* guix/scripts/challenge.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:51:54 +02:00
Simon Tournier
de63efc802
scripts: build: Handle EPIPE errors when displaying help.
...
* guix/scripts/build.scm (%options): Handle EPIPE errors when displaying help.
2023-10-17 14:51:54 +02:00
Simon Tournier
b53742def3
scripts: archive: Handle EPIPE errors when displaying help.
...
* guix/scripts/archive.scm (%options): Handle EPIPE errors when displaying
help.
2023-10-17 14:51:53 +02:00
Sören Tempel
435090fa3f
pack: Allow setting a custom image tag for Docker images
...
Previously, the image repository name was automatically computed from
the packages in the manifest without allowing the user to set a custom
one. As such, changing the packages in the manifest would result in a
new image name. Thereby requiring updating documentation et cetera when
using `docker load` directory on the resulting image.
Inspired by `docker build -t`, this commit adds a new Docker-specific
option to `guix pack` which allows setting a custom repository name for
the resulting image. If this option is not specified, pack falls back
to computing the name from the manifest. Therefore, this change is
entirely backwards compatible.
Documentation has been added with: 373ec2cf8c
.
* guix/scripts/pack.scm (guix-pack): Add --image-tag option.
(%docker-format-options): New constant.
(show-docker-format-options): New procedure.
(show-docker-format-options/detailed): New procedure.
(docker-image): Allow setting a custom
repository name for the created docker image via extra-options.
Signed-off-by: Sören Tempel <soeren@soeren-tempel.net>
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
2023-10-16 09:08:13 +02:00
Ludovic Courtès
75bdf8e06a
shell: Take grafting into account when caching.
...
Fixes <https://issues.guix.gnu.org/64856 >.
* guix/scripts/shell.scm (profile-file-cache-key)
(profile-spec-cache-key): Take (%graft?) into account.
Reported-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
2023-10-12 18:53:07 +02:00
Ludovic Courtès
762fdbdef5
perform-download: Set PATH before invoking ‘git’.
...
Fixes <https://issues.guix.gnu.org/66305 >.
Reported by Guillaume Le Vaillant <glv@posteo.net>.
* guix/scripts/perform-download.scm (perform-git-download): Add call to
‘setenv’.
2023-10-05 23:14:53 +02:00
Ricardo Wurmus
3fba8cd274
refresh: Fix sorting of updates by file and line number.
...
* guix/scripts/refresh.scm (guix-refresh): Add cascade-sort procedure and use
it to sort specs by package location.
2023-10-05 15:16:26 +02:00
Nikolaos Chatzikonstantinou
c6eed13c87
archive: Fix ‘--version’ typo.
...
* guix/scripts/archive.scm (%options): Replace 'build' by 'archive'.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2023-09-28 11:44:09 +02:00
Ludovic Courtès
c4a1d69a69
perform-download: Use the ‘git’ command captured at configure time.
...
* guix/scripts/perform-download.scm (perform-git-download): Pass #:git-command
to ‘git-fetch-with-fallback’.
2023-09-26 17:36:58 +02:00
Ludovic Courtès
95f2123135
daemon: Add “git-download” built-in builder.
...
The new builder makes it possible to break cycles that occurs when the
fixed-output derivation for the source of a dependency of ‘git’ would
itself depend on ‘git’.
* guix/scripts/perform-download.scm (perform-git-download): New
procedure.
(perform-download): Move fixed-output derivation check to…
(guix-perform-download): … here. Invoke ‘perform-download’ or
‘perform-git-download’ depending on what ‘derivation-builder’ returns.
* nix/libstore/builtins.cc (builtins): Add “git-download”.
* tests/derivations.scm ("built-in-builders"): Update.
("'git-download' built-in builder")
("'git-download' built-in builder, invalid hash")
("'git-download' built-in builder, invalid commit")
("'git-download' built-in builder, not found"): New tests.
2023-09-26 17:36:58 +02:00