Package Details: git-subrepo 0.4.9-1

Git Clone URL: https://aur.archlinux.org/git-subrepo.git (read-only, click to copy)
Package Base: git-subrepo
Description: Git submodule alternative
Upstream URL: https://github.com/ingydotnet/git-subrepo
Licenses: MIT
Submitter: bricewge
Maintainer: alerque
Last Packager: alerque
Votes: 11
Popularity: 0.000027
First Submitted: 2015-08-28 13:55 (UTC)
Last Updated: 2024-08-14 19:50 (UTC)

Latest Comments

1 2 Next › Last »

drew33 commented on 2024-09-17 11:57 (UTC) (edited on 2024-09-17 12:01 (UTC) by drew33)

Hi @alerque & @nickray,

[Many thanks for maintaining this package & the bug report]

I managed to fix it with this patch:

diff --git a/PKGBUILD b/PKGBUILD
index bc80d76..5282cce 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -27,9 +27,24 @@ prepare() {
 }

 check() {
+  git config user.email "you@example.com";
+  git config user.name "Your Name";
+
+  CUR_DEF_BRANCH=$(git config --global init.defaultBranch)
+  if [[ "$CUR_DEF_BRANCH" != "master" ]]; then
+    printf "\nWARNING: Changing git global config init.defaultBranch from '${CUR_DEF_BRANCH}' to 'master' (temporarily)\n\n";
+    git config --global init.defaultBranch "master";
+  fi
+
+  git config --add safe.directory "$PWD";
+  git config --add safe.directory "$PWD.git";
        export EMAIL="nobody@nowhere.xyz"
-        export GIT_AUTHOR_NAME="nobody"
-        make -C $pkgname test
+  export GIT_AUTHOR_NAME="nobody"
+  make -C $pkgname test
+  if [[ "$CUR_DEF_BRANCH" != "master" ]]; then
+    git config --global init.defaultBranch "$CUR_DEF_BRANCH";
+    printf "\ngit global config init.defaultBranch reverted back to '${CUR_DEF_BRANCH}'\n\n";
+  fi
 }

 package() {

Taken from here: https://github.com/ingydotnet/git-subrepo/blob/master/.github/workflows/test.yml#L21C1-L25C61

Reading this: https://git-scm.com/book/en/v2/Git-Internals-Environment-Variables it might be better to override $HOME to so a temporary system wide git config file can be used instead. Let me know if you'd like me to test (super busy at the moment sadly though)

nickray commented on 2024-08-18 10:52 (UTC)

Doesn't build:

==> Starting check()...
(...)
test/config.t ...................... 1/? #   Failed test '.gitrepo branch is correct'
#   at test/setup line 164.
#     got: 'main'
#   expected: 'master'
#   Failed test '.gitrepo branch is correct'
#   at test/setup line 164.
#     got: 'main'
#   expected: 'master'
test/config.t ...................... Failed 2/15 subtests 
test/encode.t ...................... 23/? grep: warning: stray \ before a
grep: warning: stray \ before a
test/encode.t ...................... 28/? grep: warning: stray \ before a
test/encode.t ...................... 75/? grep: warning: stray \ before n
grep: warning: stray \ before n
grep: warning: stray \ before n
(...)
test/init.t ........................ 1/? #   Failed test '.gitrepo branch is correct'
#   at test/setup line 164.
#     got: 'main'
#   expected: 'master'
test/init.t ........................ Failed 1/20 subtests 
(...)
test/push-after-init.t ............. 1/? #   Failed test 'Command output is correct'
#   at test/push-after-init.t line 28.
#     got: 'Subrepo 'doc' pushed to '../upstream' (main).'
#   expected: 'Subrepo 'doc' pushed to '../upstream' (master).'
#   Failed test '.gitrepo branch is correct'
#   at test/setup line 164.
#     got: 'main'
#   expected: 'master'
test/push-after-init.t ............. Failed 2/5 subtests 
(...)

Test Summary Report
-------------------
test/config.t                    (Wstat: 0 Tests: 15 Failed: 2)
  Failed tests:  2, 9
test/init.t                      (Wstat: 0 Tests: 20 Failed: 1)
  Failed test:  10
test/push-after-init.t           (Wstat: 0 Tests: 5 Failed: 2)
  Failed tests:  1, 3
Files=35, Tests=320, 67 wallclock secs ( 0.16 usr  0.06 sys + 38.25 cusr 32.58 csys = 71.05 CPU)
Result: FAIL
(...)

Techcable commented on 2024-03-30 22:57 (UTC)

I get an error with a missing help-functions.bash script:

/usr/bin/git-subrepo: line 1941: /git-subrepo.d/help-functions.bash: No such file or directory

Also tests fail when commit.gpgsign or tag.gpgsign are set to true.

This can be disabled by setting environment variables: GIT_CONFIG_COUNT=2 GIT_CONFIG_KEY_0=commit.gpgsign GIT_CONFIG_VALUE_0=false GIT_CONFIG_KEY_1=tag.gpgsign GIT_CONFIG_VALUE_1=false makepkg

However, It would be best if the script did this automatically before running the tests ;)

eclairevoyant commented on 2023-10-25 21:16 (UTC)

Tests pass on my end. Make sure you use a clean chroot.

abody commented on 2023-10-25 13:37 (UTC) (edited on 2023-10-25 13:39 (UTC) by abody)

Packaging fails due to test failures:

Test Summary Report
-------------------
test/issue96.t                   (Wstat: 0 Tests: 2 Failed: 1)
  Failed test:  2
test/pull-merge.t                (Wstat: 0 Tests: 8 Failed: 0)
  Parse errors: No plan found in TAP output
test/pull-ours.t                 (Wstat: 0 Tests: 4 Failed: 0)
  Parse errors: No plan found in TAP output
test/pull-theirs.t               (Wstat: 0 Tests: 3 Failed: 0)
  Parse errors: No plan found in TAP output
test/push.t                      (Wstat: 0 Tests: 0 Failed: 0)
  Parse errors: No plan found in TAP output
Files=36, Tests=293, 100 wallclock secs ( 0.11 usr  0.06 sys + 39.61 cusr 33.65 csys = 73.43 CPU)
Result: FAIL
make: *** [Makefile:49: test] Error 1
make: Leaving directory '/home/abody/.cache/yay/git-subrepo/src/git-subrepo'
==> ERROR: A failure occurred in check().
    Aborting...
 -> error making: git-subrepo-exit status 4
 -> Failed to install the following packages. Manual intervention is required:
git-subrepo - exit status 4

eclairevoyant commented on 2023-05-16 14:58 (UTC)

The names of everyone who maintained the package in the past are in the git history.

I'm happy to give credit to anyone who submits patches/PRs, but no one else contributed here. This entire PKGBUILD was written from scratch (see git blame/log).

gromit commented on 2023-05-16 08:53 (UTC)

Please do not remove the old "Maintainer: ..." line but instead add them as Contributor :)

https://aur.archlinux.org/cgit/aur.git/commit/?h=git-subrepo&id=77ac48ff56514832ebee4fb045abd059edede820

eclairevoyant commented on 2023-05-16 06:46 (UTC)

This PKGBUILD should now address all of the applicable issues, and splits off the helper library bashplus into its own dependency.

eclairevoyant commented on 2023-05-12 12:52 (UTC)

I fixed some of the issues (missing backup entry, broken .SRCINFO) in the comments; regarding FHS conformance I thought it would be quite simple at first, but upstream's scripts are frankly absurd and use arbitrary environment variables to declare imports of other scripts. Not to mention upstream bundles two other projects with this one (via git-subrepo) that need to be extricated into their own packages. Upstream's Makefile is broken as well and doesn't install most of the necessary files either.

I've looked at the other PKGBUILD but I don't think it addresses the issue of brittle dependencies, and actually fixing this seems to require extensive patching. Which I'm fine doing, I was just curious if someone had already done so.

alerque commented on 2023-05-12 12:27 (UTC)

I submitted an orphan request in part because I was willing to fix this. Why did you adopt it if the issues already expressed in comments were not something you were ready to fix? Also there is a complete alternate PKGBUILD in comments that doesn't use /opt. It has other issues but maybe get some ideas from there.