[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Fwd: SSH in git-fetch

From: Lo Peter
Subject: Fwd: SSH in git-fetch
Date: Wed, 14 Jul 2021 00:07:18 +0800

---------- Forwarded message ---------
From: Lo Peter <>
Date: Tue, Jul 13, 2021 at 10:38 PM
Subject: SSH in git-fetch
To: <>

Dear all,

I am experimenting with writing a package definition for an example R
package ( in a PRIVATE channel,
where the R source is also at a PRIVATE github repository.
While the private channel works with proper setup of SSH key (that
needs to be in PEM format due to a bug in libssh2), I am having
trouble with the private git repository for package source.

Is it that git-fetch does not support fetching over SSH?

The package definition I have is:

(define-module (my-packages r-pkgs)
  #:use-module ((guix licenses) #:prefix license:)
  #:use-module (guix packages)
  #:use-module (guix download)
  #:use-module (guix git-download)
  #:use-module (guix utils)
  #:use-module (guix build-system r)
  #:use-module (gnu packages)
  #:use-module (gnu packages statistics))

(define-public r-foofactors
  (let ((commit "ef71e8d2e82fa80e0cfc249fd42f50c01924326d")
        (revision "1"))
      (name "r-foofactors")
      (version (git-version "" revision commit))
         (method git-fetch)
         (uri (git-reference
               (url "")
               (commit commit)))
         (file-name (git-file-name name version))
      (build-system r-build-system)
       `(("r-forcats" ,r-forcats)))
      (home-page "";)
      (synopsis "A R package to make factors less aggravating.")
       "Factors have driven people to extreme measures, like ordering
custom conference ribbons and laptop stickers to express how HELLNO we
feel about stringsAsFactors. And yet, sometimes you need them. Can they
be made less maddening? Let's find out.")
      (license license:expat))))

Note that I have cloned the original public repository to my private
repository (for testing purpose). I have added the package definition
to my local ~/to_keep/projects/my-guix-pkgs/my-packages/r-pkgs.scm

Then I test building it locally with

$ guix build -L ~/to_keep/projects/my-guix-pkgs/ r-foofactors
The following derivations will be built:
guile: warning: failed to install locale
environment variable `PATH' set to
hint: Using 'master' as the name for the initial branch. This default
branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:   git config --global init.defaultBranch <name>
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint:   git branch -m <name>
Initialized empty Git repository in
error: cannot run ssh: No such file or directory
fatal: unable to fork
Failed to do a shallow fetch; retrying a full fetch...
error: cannot run ssh: No such file or directory
fatal: unable to fork
fetch origin' failed with exit code 128
Trying content-addressed mirror at
Trying content-addressed mirror at
Trying to download from Software Heritage...
builder for 
failed to produce output path `/gnu/store/7i9py1b47lsg2d2wqjk68ha04r
build of 
View build log at
cannot build derivation
1 dependencies couldn't be built
guix build: error: build of

Why is there an error of "cannot run ssh"? Is it that git-fetch does
not support fetching over SSH?

I would like to prompt the use of Guix for per-project management in
my small team of data scientists, so we would need a private channel
for a few internal R packages. The above problem is a real blocker.
Any help is greatly appreciated.

Peter Lo

reply via email to

[Prev in Thread] Current Thread [Next in Thread]